Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--jpa/plugins/org.eclipse.jpt.ui/src/org/eclipse/jpt/ui/internal/views/JpaStructureView.java9
1 files changed, 9 insertions, 0 deletions
diff --git a/jpa/plugins/org.eclipse.jpt.ui/src/org/eclipse/jpt/ui/internal/views/JpaStructureView.java b/jpa/plugins/org.eclipse.jpt.ui/src/org/eclipse/jpt/ui/internal/views/JpaStructureView.java
index 9119a606da..0dd7da45f3 100644
--- a/jpa/plugins/org.eclipse.jpt.ui/src/org/eclipse/jpt/ui/internal/views/JpaStructureView.java
+++ b/jpa/plugins/org.eclipse.jpt.ui/src/org/eclipse/jpt/ui/internal/views/JpaStructureView.java
@@ -61,6 +61,9 @@ public class JpaStructureView extends AbstractJpaView
setLinkedWithEditor(i != null && i.intValue() == 1);
}
+ else {
+ setLinkedWithEditor(true);
+ }
super.init(site, memento);
}
@@ -104,6 +107,12 @@ public class JpaStructureView extends AbstractJpaView
@Override
public void select(Selection newSelection) {
+ if (!isLinkedWithEditor()) {
+ //The only selection we are concerned with is the editor, so we can select
+ //nothing if the user has set linkedWithEditor to false. If we ever depend
+ //on selection from any other views, this assumption will no longer work
+ return;
+ }
Selection currentSelection = getSelection();
if (newSelection.equals(currentSelection)) {

Back to the top