Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bundles/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/TextMergeViewer.java11
-rw-r--r--bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/TextMergeViewer.java11
2 files changed, 16 insertions, 6 deletions
diff --git a/bundles/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/TextMergeViewer.java b/bundles/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/TextMergeViewer.java
index f19349392..017e2e3fd 100644
--- a/bundles/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/TextMergeViewer.java
+++ b/bundles/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/TextMergeViewer.java
@@ -1091,10 +1091,15 @@ public class TextMergeViewer extends ContentMergeViewer {
if (actionBars != null) {
for (int i= 0; i < GLOBAL_ACTIONS.length; i++) {
IAction action= null;
- if (part != null)
+ if (part != null) {
action= part.getAction(TEXT_ACTIONS[i]);
- if (i == 7)
- i= 7;
+ if (action == null && TEXT_ACTIONS[i].equals(MergeSourceViewer.SAVE_ID)) {
+ if (part == fLeft)
+ action= fLeftSaveAction;
+ else
+ action= fRightSaveAction;
+ }
+ }
actionBars.setGlobalActionHandler(GLOBAL_ACTIONS[i], action);
}
actionBars.updateActionBars();
diff --git a/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/TextMergeViewer.java b/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/TextMergeViewer.java
index f19349392..017e2e3fd 100644
--- a/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/TextMergeViewer.java
+++ b/bundles/org.eclipse.compare/plugins/org.eclipse.compare/compare/org/eclipse/compare/contentmergeviewer/TextMergeViewer.java
@@ -1091,10 +1091,15 @@ public class TextMergeViewer extends ContentMergeViewer {
if (actionBars != null) {
for (int i= 0; i < GLOBAL_ACTIONS.length; i++) {
IAction action= null;
- if (part != null)
+ if (part != null) {
action= part.getAction(TEXT_ACTIONS[i]);
- if (i == 7)
- i= 7;
+ if (action == null && TEXT_ACTIONS[i].equals(MergeSourceViewer.SAVE_ID)) {
+ if (part == fLeft)
+ action= fLeftSaveAction;
+ else
+ action= fRightSaveAction;
+ }
+ }
actionBars.setGlobalActionHandler(GLOBAL_ACTIONS[i], action);
}
actionBars.updateActionBars();

Back to the top