Bug 440033 - InjectionException: java.lang.StackOverflowError in
org.eclipse.e4.ui.workbench.renderers.swt
Change-Id: Idae8f17e88a994f7ab8c1089796128f6a73c35b4
Signed-off-by: Anton Leherbauer <anton.leherbauer@windriver.com>
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/actions/DebugCommandHandler.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/actions/DebugCommandHandler.java
index 9cc8c4c..561e64e 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/actions/DebugCommandHandler.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/actions/DebugCommandHandler.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2006, 2013 Wind River Systems and others.
+ * Copyright (c) 2006, 2015 Wind River Systems 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
@@ -73,10 +73,13 @@
EnabledTarget(IWorkbenchWindow window) {
fWindow = window;
+ }
+
+ void init() {
DebugCommandService.getService(fWindow).updateCommand(getCommandType(), this);
getContextService(fWindow).addDebugContextListener(this);
- }
-
+ }
+
@Override
public void setEnabled(boolean enabled) {
boolean oldEnabled = fEnabled;
@@ -188,7 +191,8 @@
EnabledTarget target = fEnabledTargetsMap.get(window);
if (target == null) {
target = new EnabledTarget(window);
- fEnabledTargetsMap.put(window, target);
+ fEnabledTargetsMap.put(window, target);
+ target.init();
}
return target;
}