Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjames2002-06-10 18:08:12 +0000
committerjames2002-06-10 18:08:12 +0000
commited5b8d00aa2642141d341d9977e2ada49b0dcd69 (patch)
treeb56bde1189ee715a1ee6bf527d4edc46999fdc42 /bundles
parenta29d0ee97fdbbc5046945a1eed94f48de06afefd (diff)
downloadeclipse.platform.team-ed5b8d00aa2642141d341d9977e2ada49b0dcd69.tar.gz
eclipse.platform.team-ed5b8d00aa2642141d341d9977e2ada49b0dcd69.tar.xz
eclipse.platform.team-ed5b8d00aa2642141d341d9977e2ada49b0dcd69.zip
19473: No way to move to next file with changes in Synchronize editor
Diffstat (limited to 'bundles')
-rw-r--r--bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/sync/CatchupReleaseViewer.java16
-rw-r--r--bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/sync/SyncView.java14
2 files changed, 16 insertions, 14 deletions
diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/sync/CatchupReleaseViewer.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/sync/CatchupReleaseViewer.java
index 814b584e7..93bb21abb 100644
--- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/sync/CatchupReleaseViewer.java
+++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/sync/CatchupReleaseViewer.java
@@ -10,8 +10,10 @@ import java.util.Iterator;
import org.eclipse.compare.BufferedContent;
import org.eclipse.compare.CompareConfiguration;
+import org.eclipse.compare.CompareEditorInput;
import org.eclipse.compare.IEditableContent;
import org.eclipse.compare.ITypedElement;
+import org.eclipse.compare.NavigationAction;
import org.eclipse.compare.internal.CompareUIPlugin;
import org.eclipse.compare.structuremergeviewer.DiffContainer;
import org.eclipse.compare.structuremergeviewer.DiffElement;
@@ -149,6 +151,7 @@ public abstract class CatchupReleaseViewer extends DiffTreeViewer implements ISe
return property.equals(PROP_KIND);
}
}
+
class FilterAction extends Action {
/**
* Must subclass constructor to make it accessible to container class
@@ -218,6 +221,9 @@ public abstract class CatchupReleaseViewer extends DiffTreeViewer implements ISe
private Action ignoreWhiteSpace;
private Action toggleGranularity;
+ private NavigationAction showPrevious;
+ private NavigationAction showNext;
+
// Property constant for diff mode kind
static final String PROP_KIND = "team.ui.PropKind"; //$NON-NLS-1$
@@ -243,6 +249,10 @@ public abstract class CatchupReleaseViewer extends DiffTreeViewer implements ISe
toolBar.add(new Separator());
toolBar.add(showOnlyConflicts);
+ toolBar.add(new Separator());
+ toolBar.add(showNext);
+ toolBar.add(showPrevious);
+
// Drop down menu
IMenuManager menu = actionBars.getMenuManager();
if (syncMode == SyncView.SYNC_BOTH) {
@@ -403,6 +413,12 @@ public abstract class CatchupReleaseViewer extends DiffTreeViewer implements ISe
boolean ignore = CompareUIPlugin.getDefault().getPreferenceStore().getBoolean(CompareConfiguration.IGNORE_WHITESPACE);
ignoreWhiteSpace.setChecked(ignore);
+ // Show next and previous change
+ showNext = new NavigationAction(true);
+ showPrevious = new NavigationAction(false);
+ showNext.setCompareEditorInput(diffModel);
+ showPrevious.setCompareEditorInput(diffModel);
+
// Add a selection listener to set the left label
addSelectionChangedListener(this);
diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/sync/SyncView.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/sync/SyncView.java
index 2f76067fe..8d5823973 100644
--- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/sync/SyncView.java
+++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/sync/SyncView.java
@@ -90,8 +90,6 @@ public class SyncView extends ViewPart {
private SyncModeAction incomingMode;
private SyncModeAction outgoingMode;
private SyncModeAction freeMode;
- private NavigationAction next;
- private NavigationAction previous;
private class PartListener implements IPartListener {
public void partActivated(IWorkbenchPart part) {
@@ -195,16 +193,6 @@ public class SyncView extends ViewPart {
SYNC_BOTH);
freeMode.setToolTipText(Policy.bind("SyncView.freeModeToolTip")); //$NON-NLS-1$
freeMode.setChecked(false);
-
- // Set up global actions for next and previous
- next = new NavigationAction(true);
- previous = new NavigationAction(false);
- IActionBars actionBars = getViewSite().getActionBars();
- if (actionBars != null) {
- actionBars.setGlobalActionHandler(IWorkbenchActionConstants.NEXT, next);
- actionBars.setGlobalActionHandler(IWorkbenchActionConstants.PREVIOUS, previous);
- actionBars.updateActionBars();
- }
}
private boolean isEmpty(DiffNode node) {
@@ -308,8 +296,6 @@ public class SyncView extends ViewPart {
* Shows synchronization information for the given resources in the sync view.
*/
public void showSync(SyncCompareInput input) {
- next.setCompareEditorInput(input);
- previous.setCompareEditorInput(input);
IActionBars actionBars = getViewSite().getActionBars();
actionBars.updateActionBars();

Back to the top