aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOleg Besedin2012-10-23 10:31:39 (EDT)
committerOleg Besedin2012-10-23 10:32:14 (EDT)
commit80e45e434c97a1cb41957270603b7f79f479ac8c (patch)
tree9c1235df0ff84a43e4a2b3a27586217694293706
parent984f78cf9b5b8636206631a19ae19e1f745c4848 (diff)
downloadeclipse.platform.ui-80e45e434c97a1cb41957270603b7f79f479ac8c.zip
eclipse.platform.ui-80e45e434c97a1cb41957270603b7f79f479ac8c.tar.gz
eclipse.platform.ui-80e45e434c97a1cb41957270603b7f79f479ac8c.tar.bz2
Bug 389863 - EventHandlers are not called on part after closing otherv20121023-143214
part
-rw-r--r--bundles/org.eclipse.e4.ui.workbench.swt/src/org/eclipse/e4/ui/internal/workbench/swt/E4Application.java4
-rw-r--r--tests/org.eclipse.e4.ui.tests/src/org/eclipse/e4/ui/tests/workbench/InjectionEventTest.java1
2 files changed, 5 insertions, 0 deletions
diff --git a/bundles/org.eclipse.e4.ui.workbench.swt/src/org/eclipse/e4/ui/internal/workbench/swt/E4Application.java b/bundles/org.eclipse.e4.ui.workbench.swt/src/org/eclipse/e4/ui/internal/workbench/swt/E4Application.java
index c4f1f59..c344cc7 100644
--- a/bundles/org.eclipse.e4.ui.workbench.swt/src/org/eclipse/e4/ui/internal/workbench/swt/E4Application.java
+++ b/bundles/org.eclipse.e4.ui.workbench.swt/src/org/eclipse/e4/ui/internal/workbench/swt/E4Application.java
@@ -236,6 +236,10 @@ public class E4Application implements IApplication {
// Set the app's context after adding itself
appContext.set(MApplication.class.getName(), appModel);
+ // This context will be used by the injector for its
+ // extended data suppliers
+ ContextInjectionFactory.setDefault(appContext);
+
// adds basic services to the contexts
initializeServices(appModel);
diff --git a/tests/org.eclipse.e4.ui.tests/src/org/eclipse/e4/ui/tests/workbench/InjectionEventTest.java b/tests/org.eclipse.e4.ui.tests/src/org/eclipse/e4/ui/tests/workbench/InjectionEventTest.java
index 879ad95..a2dd63b 100644
--- a/tests/org.eclipse.e4.ui.tests/src/org/eclipse/e4/ui/tests/workbench/InjectionEventTest.java
+++ b/tests/org.eclipse.e4.ui.tests/src/org/eclipse/e4/ui/tests/workbench/InjectionEventTest.java
@@ -145,6 +145,7 @@ public class InjectionEventTest extends TestCase {
d.asyncExec(runnable);
}
});
+ ContextInjectionFactory.setDefault(context);
InjectTarget target = ContextInjectionFactory.make(InjectTarget.class,
context);