Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDarin Wright2009-01-16 21:42:34 +0000
committerDarin Wright2009-01-16 21:42:34 +0000
commit3a44ff5c9cb5aa1d9de1e5b5619e88b377b3f13c (patch)
treebdbc60a7b3c718a2be5f479a247eab9f49f54e8f /org.eclipse.ui.console
parent701df7713eca0bb4fbab972fc3a5e013ea792839 (diff)
downloadeclipse.platform.debug-3a44ff5c9cb5aa1d9de1e5b5619e88b377b3f13c.tar.gz
eclipse.platform.debug-3a44ff5c9cb5aa1d9de1e5b5619e88b377b3f13c.tar.xz
eclipse.platform.debug-3a44ff5c9cb5aa1d9de1e5b5619e88b377b3f13c.zip
Bug 261214 - Console view: Opening drop-down of console switcher button already switches consoles
Diffstat (limited to 'org.eclipse.ui.console')
-rw-r--r--org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsoleView.java16
1 files changed, 10 insertions, 6 deletions
diff --git a/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsoleView.java b/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsoleView.java
index 0c543dc64..3289a1b61 100644
--- a/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsoleView.java
+++ b/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/ConsoleView.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2000, 2008 IBM Corporation and others.
+ * Copyright (c) 2000, 2009 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -28,6 +28,7 @@ import org.eclipse.swt.widgets.ToolBar;
import org.eclipse.swt.widgets.ToolItem;
import org.eclipse.jface.action.ActionContributionItem;
+import org.eclipse.jface.action.IAction;
import org.eclipse.jface.action.IToolBarManager;
import org.eclipse.jface.action.Separator;
import org.eclipse.jface.action.ToolBarManager;
@@ -480,11 +481,14 @@ public class ConsoleView extends PageBookView implements IConsoleView, IConsoleL
ToolItem ti= tb.getItem(new Point(e.x, e.y));
if (ti.getData() instanceof ActionContributionItem) {
ActionContributionItem actionContributionItem= (ActionContributionItem) ti.getData();
- Event event= new Event();
- event.widget= ti;
- event.x= e.x;
- event.y= e.y;
- actionContributionItem.getAction().runWithEvent(event);
+ IAction action= actionContributionItem.getAction();
+ if (action == fOpenConsoleAction) {
+ Event event= new Event();
+ event.widget= ti;
+ event.x= e.x;
+ event.y= e.y;
+ action.runWithEvent(event);
+ }
}
}
});

Back to the top