Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorggurfinke2007-05-13 14:57:11 +0000
committerggurfinke2007-05-13 14:57:11 +0000
commite78c4ade0349d163a21cbd0786f1a02bfcb36caf (patch)
tree1dc8eb2bcd49d49a74430de90160321a2cd4a627
parentab5bf5da567238201e79013e156b0f8a628d597e (diff)
downloadorg.eclipse.pdt-e78c4ade0349d163a21cbd0786f1a02bfcb36caf.tar.gz
org.eclipse.pdt-e78c4ade0349d163a21cbd0786f1a02bfcb36caf.tar.xz
org.eclipse.pdt-e78c4ade0349d163a21cbd0786f1a02bfcb36caf.zip
the project outline should refresh the content providers registered as extensionsv20070514
-rw-r--r--plugins/org.eclipse.php.ui/src/org/eclipse/php/internal/ui/StandardPHPElementContentProvider.java2
-rw-r--r--plugins/org.eclipse.php.ui/src/org/eclipse/php/internal/ui/projectOutline/ProjectOutlineContentProvider.java23
2 files changed, 24 insertions, 1 deletions
diff --git a/plugins/org.eclipse.php.ui/src/org/eclipse/php/internal/ui/StandardPHPElementContentProvider.java b/plugins/org.eclipse.php.ui/src/org/eclipse/php/internal/ui/StandardPHPElementContentProvider.java
index 9689b25d5..d3a6814f2 100644
--- a/plugins/org.eclipse.php.ui/src/org/eclipse/php/internal/ui/StandardPHPElementContentProvider.java
+++ b/plugins/org.eclipse.php.ui/src/org/eclipse/php/internal/ui/StandardPHPElementContentProvider.java
@@ -38,7 +38,7 @@ public class StandardPHPElementContentProvider implements ITreeContentProvider {
protected static final Object[] NO_CHILDREN = new Object[0];
protected boolean fProvideMembers;
- IPHPTreeContentProvider[] treeProviders;
+ protected IPHPTreeContentProvider[] treeProviders;
public StandardPHPElementContentProvider() {
this(false);
diff --git a/plugins/org.eclipse.php.ui/src/org/eclipse/php/internal/ui/projectOutline/ProjectOutlineContentProvider.java b/plugins/org.eclipse.php.ui/src/org/eclipse/php/internal/ui/projectOutline/ProjectOutlineContentProvider.java
index fd83c5bbb..ac0edd5f1 100644
--- a/plugins/org.eclipse.php.ui/src/org/eclipse/php/internal/ui/projectOutline/ProjectOutlineContentProvider.java
+++ b/plugins/org.eclipse.php.ui/src/org/eclipse/php/internal/ui/projectOutline/ProjectOutlineContentProvider.java
@@ -24,6 +24,8 @@ import org.eclipse.php.internal.core.phpModel.parser.PHPWorkspaceModelManager;
import org.eclipse.php.internal.core.phpModel.phpElementData.*;
import org.eclipse.php.internal.ui.StandardPHPElementContentProvider;
import org.eclipse.php.internal.ui.explorer.PHPTreeViewer;
+import org.eclipse.php.internal.ui.treecontent.TreeProvider;
+import org.eclipse.php.ui.treecontent.IPHPTreeContentProvider;
import org.eclipse.swt.widgets.Control;
public class ProjectOutlineContentProvider extends StandardPHPElementContentProvider implements ModelListener, IWorkspaceModelListener {
@@ -193,6 +195,13 @@ public class ProjectOutlineContentProvider extends StandardPHPElementContentProv
toUpdate = outlineNode.addChildren(fileData);
fViewer.add(outlineNode, toUpdate);
}
+ for (int i = 0; i < treeProviders.length; i++) {
+ IPHPTreeContentProvider provider = treeProviders[i];
+ Object[] children = provider.getChildren(fStoredProject);
+ for (int j = 0; j < children.length; j++) {
+ fViewer.refresh(children[j],true);
+ }
+ }
}
};
fViewer.getControl().getDisplay().asyncExec(runnable);
@@ -228,6 +237,13 @@ public class ProjectOutlineContentProvider extends StandardPHPElementContentProv
toUpdate = outlineNode.removeChildren(fileData);
fViewer.remove(outlineNode, toUpdate);
}
+ for (int i = 0; i < treeProviders.length; i++) {
+ IPHPTreeContentProvider provider = treeProviders[i];
+ Object[] children = provider.getChildren(fStoredProject);
+ for (int j = 0; j < children.length; j++) {
+ fViewer.refresh(children[j],true);
+ }
+ }
}
};
fViewer.getControl().getDisplay().asyncExec(runnable);
@@ -262,6 +278,13 @@ public class ProjectOutlineContentProvider extends StandardPHPElementContentProv
outlineNode.loadChildren();
fViewer.refresh(outlineNode, true);
}
+ for (int i = 0; i < treeProviders.length; i++) {
+ IPHPTreeContentProvider provider = treeProviders[i];
+ Object[] children = provider.getChildren(fStoredProject);
+ for (int j = 0; j < children.length; j++) {
+ fViewer.refresh(children[j],true);
+ }
+ }
ISelection currentSelection = fViewer.getSelection();
if (currentSelection.isEmpty()) {
fViewer.setSelection(fViewer.getStoredSelection(), false);

Back to the top