Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEike Stepper2012-09-06 11:42:41 +0000
committerEike Stepper2012-09-06 11:42:41 +0000
commit3224388d98796036d49cc879878e418aef6e6d5d (patch)
tree2856784539f25c924f5f7c123ff9e8030a2e29f9 /plugins
parentc2b708501c20a4e89bfbc0ffd32f1134abe4254e (diff)
downloadcdo-3224388d98796036d49cc879878e418aef6e6d5d.tar.gz
cdo-3224388d98796036d49cc879878e418aef6e6d5d.tar.xz
cdo-3224388d98796036d49cc879878e418aef6e6d5d.zip
Fix UIUtil.preserveViewerState()
Diffstat (limited to 'plugins')
-rw-r--r--plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/UIUtil.java22
1 files changed, 10 insertions, 12 deletions
diff --git a/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/UIUtil.java b/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/UIUtil.java
index 07c7d33860..2797d608f4 100644
--- a/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/UIUtil.java
+++ b/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/UIUtil.java
@@ -19,8 +19,6 @@ import org.eclipse.jface.fieldassist.FieldDecorationRegistry;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.jface.viewers.StructuredViewer;
-import org.eclipse.jface.viewers.TreePath;
-import org.eclipse.jface.viewers.TreeViewer;
import org.eclipse.jface.viewers.Viewer;
import org.eclipse.swt.SWT;
import org.eclipse.swt.dnd.Clipboard;
@@ -407,12 +405,12 @@ public final class UIUtil
{
ISelection selection = viewer.getSelection();
- TreePath[] paths = null;
- if (viewer instanceof TreeViewer)
- {
- TreeViewer treeViewer = (TreeViewer)viewer;
- paths = treeViewer.getExpandedTreePaths();
- }
+ // TreePath[] paths = null;
+ // if (viewer instanceof TreeViewer)
+ // {
+ // TreeViewer treeViewer = (TreeViewer)viewer;
+ // paths = treeViewer.getExpandedTreePaths();
+ // }
try
{
@@ -424,10 +422,10 @@ public final class UIUtil
}
finally
{
- if (paths != null)
- {
- ((TreeViewer)viewer).setExpandedElements(paths);
- }
+ // if (paths != null)
+ // {
+ // ((TreeViewer)viewer).setExpandedElements(paths);
+ // }
viewer.setSelection(selection);
}

Back to the top