Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
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