Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndre Weinand2002-06-01 10:00:00 +0000
committerAndre Weinand2002-06-01 10:00:00 +0000
commitf7189665485f7483e21d634f1f8b92c8def2680c (patch)
tree21a391cf972c4d370813357047ddb8580a06eec6
parent78603d1ec3036c5e0e8a4f5c1cc242c87db7cf32 (diff)
downloadeclipse.platform.team-f7189665485f7483e21d634f1f8b92c8def2680c.tar.gz
eclipse.platform.team-f7189665485f7483e21d634f1f8b92c8def2680c.tar.xz
eclipse.platform.team-f7189665485f7483e21d634f1f8b92c8def2680c.zip
#12643: Expand all does not disable when there is no selection
-rw-r--r--bundles/org.eclipse.compare/buildnotes_compare.html3
-rw-r--r--bundles/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/DiffTreeViewer.java4
-rw-r--r--bundles/org.eclipse.compare/plugins/org.eclipse.compare/buildnotes_compare.html3
-rw-r--r--bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/DiffTreeViewer.java4
4 files changed, 14 insertions, 0 deletions
diff --git a/bundles/org.eclipse.compare/buildnotes_compare.html b/bundles/org.eclipse.compare/buildnotes_compare.html
index 025fc8537..ac4d2235c 100644
--- a/bundles/org.eclipse.compare/buildnotes_compare.html
+++ b/bundles/org.eclipse.compare/buildnotes_compare.html
@@ -40,6 +40,9 @@ Problem reports fixed</h2>
<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=18148">#18148</a>: Using combinations of No and Next file button break wrapping<br>
<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=18151">#18151</a>: Next File button does not ding when on last file<br>
<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=16570">#16570</a>: Compare refuses to show further differences if not ignoring whitespaces<br>
+<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=10790">#10790</a>: Patch does not apply if file not found locally<br>
+<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=12643">#12643</a>: Expand all does not disable when there is no selection<br>
+
<h2>
diff --git a/bundles/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/DiffTreeViewer.java b/bundles/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/DiffTreeViewer.java
index b212a504f..918f5eff6 100644
--- a/bundles/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/DiffTreeViewer.java
+++ b/bundles/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/DiffTreeViewer.java
@@ -429,6 +429,8 @@ public class DiffTreeViewer extends TreeViewer {
};
Utilities.initAction(fExpandAllAction, fBundle, "action.ExpandAll."); //$NON-NLS-1$
}
+ ISelection selection= getSelection();
+ fExpandAllAction.setEnabled(selection != null && !selection.isEmpty());
manager.add(fExpandAllAction);
if (fCopyLeftToRightAction != null)
@@ -694,6 +696,8 @@ public class DiffTreeViewer extends TreeViewer {
break;
}
}
+ if (fExpandAllAction != null)
+ fExpandAllAction.setEnabled(selection.isEmpty());
}
if (fCopyLeftToRightAction != null)
fCopyLeftToRightAction.setEnabled(leftToRight > 0);
diff --git a/bundles/org.eclipse.compare/plugins/org.eclipse.compare/buildnotes_compare.html b/bundles/org.eclipse.compare/plugins/org.eclipse.compare/buildnotes_compare.html
index 025fc8537..ac4d2235c 100644
--- a/bundles/org.eclipse.compare/plugins/org.eclipse.compare/buildnotes_compare.html
+++ b/bundles/org.eclipse.compare/plugins/org.eclipse.compare/buildnotes_compare.html
@@ -40,6 +40,9 @@ Problem reports fixed</h2>
<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=18148">#18148</a>: Using combinations of No and Next file button break wrapping<br>
<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=18151">#18151</a>: Next File button does not ding when on last file<br>
<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=16570">#16570</a>: Compare refuses to show further differences if not ignoring whitespaces<br>
+<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=10790">#10790</a>: Patch does not apply if file not found locally<br>
+<a href="http://dev.eclipse.org/bugs/show_bug.cgi?id=12643">#12643</a>: Expand all does not disable when there is no selection<br>
+
<h2>
diff --git a/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/DiffTreeViewer.java b/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/DiffTreeViewer.java
index b212a504f..918f5eff6 100644
--- a/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/DiffTreeViewer.java
+++ b/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/DiffTreeViewer.java
@@ -429,6 +429,8 @@ public class DiffTreeViewer extends TreeViewer {
};
Utilities.initAction(fExpandAllAction, fBundle, "action.ExpandAll."); //$NON-NLS-1$
}
+ ISelection selection= getSelection();
+ fExpandAllAction.setEnabled(selection != null && !selection.isEmpty());
manager.add(fExpandAllAction);
if (fCopyLeftToRightAction != null)
@@ -694,6 +696,8 @@ public class DiffTreeViewer extends TreeViewer {
break;
}
}
+ if (fExpandAllAction != null)
+ fExpandAllAction.setEnabled(selection.isEmpty());
}
if (fCopyLeftToRightAction != null)
fCopyLeftToRightAction.setEnabled(leftToRight > 0);

Back to the top