Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Valenta2002-05-13 16:59:21 -0400
committerMichael Valenta2002-05-13 16:59:21 -0400
commit5856fea34e0a3af4e30fc68ba917bedc9a762061 (patch)
treeff560050bc0fb7d5f695ac960cd3dac932ecb3ca /bundles/org.eclipse.team.cvs.ui
parent6ee4d576b064d34af5f2251eb15a7689451c6c06 (diff)
downloadeclipse.platform.team-5856fea34e0a3af4e30fc68ba917bedc9a762061.tar.gz
eclipse.platform.team-5856fea34e0a3af4e30fc68ba917bedc9a762061.tar.xz
eclipse.platform.team-5856fea34e0a3af4e30fc68ba917bedc9a762061.zip
15815: Prompt for save changes active window...I20020514
Diffstat (limited to 'bundles/org.eclipse.team.cvs.ui')
-rw-r--r--bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/actions/CVSAction.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/actions/CVSAction.java b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/actions/CVSAction.java
index 9b575fb5e..46adb7536 100644
--- a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/actions/CVSAction.java
+++ b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/actions/CVSAction.java
@@ -367,9 +367,10 @@ abstract public class CVSAction extends TeamAction {
private boolean saveAllEditors() {
final int option = CVSUIPlugin.getPlugin().getPreferenceStore().getInt(ICVSUIConstants.PREF_SAVE_DIRTY_EDITORS);
final boolean[] okToContinue = new boolean[] {true};
- if(option != ICVSUIConstants.OPTION_NEVER) {
+ if (option != ICVSUIConstants.OPTION_NEVER) {
Display.getDefault().syncExec(new Runnable() {
public void run() {
+ IWorkbenchPage oldPage = CVSUIPlugin.getActivePage();
boolean confirm = option == ICVSUIConstants.OPTION_PROMPT;
IWorkbenchWindow[] windows = PlatformUI.getWorkbench().getWorkbenchWindows();
for (int i = 0; i < windows.length; i++) {
@@ -378,6 +379,9 @@ abstract public class CVSAction extends TeamAction {
okToContinue[0] = pages[j].saveAllEditors(confirm);
}
}
+ if (oldPage != null) {
+ oldPage.getWorkbenchWindow().getShell().setFocus();
+ }
}
});
}

Back to the top