diff options
author | Remy Suen | 2010-08-12 16:23:03 +0000 |
---|---|---|
committer | Remy Suen | 2010-08-12 16:23:03 +0000 |
commit | c602d2c29123ca424f545f8aa7eb40966c34fb5f (patch) | |
tree | c759b6b959f5a73c0e7429dd9d0432d21f8e9aa2 /bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/Workbench.java | |
parent | bfb273e3d6db0fe6ab63990f058b8179c24982af (diff) | |
download | eclipse.platform.ui-c602d2c29123ca424f545f8aa7eb40966c34fb5f.tar.gz eclipse.platform.ui-c602d2c29123ca424f545f8aa7eb40966c34fb5f.tar.xz eclipse.platform.ui-c602d2c29123ca424f545f8aa7eb40966c34fb5f.zip |
Bug 322013 [Compatibility] Failure to open workbench windows or workbench pages should cause the throwing of WorkbenchExceptions
Diffstat (limited to 'bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/Workbench.java')
-rw-r--r-- | bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/Workbench.java | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/Workbench.java b/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/Workbench.java index ced61a85397..b12421d6641 100644 --- a/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/Workbench.java +++ b/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/Workbench.java @@ -69,6 +69,7 @@ import org.eclipse.core.runtime.jobs.Job; import org.eclipse.e4.core.contexts.ContextFunction; import org.eclipse.e4.core.contexts.ContextInjectionFactory; import org.eclipse.e4.core.contexts.IEclipseContext; +import org.eclipse.e4.core.di.InjectionException; import org.eclipse.e4.core.services.events.IEventBroker; import org.eclipse.e4.ui.internal.workbench.E4CommandProcessor; import org.eclipse.e4.ui.internal.workbench.E4Workbench; @@ -2201,8 +2202,12 @@ public final class Workbench extends EventManager implements IWorkbench { WorkbenchMessages.WorkbenchPage_ErrorCreatingPerspective, perspectiveId)); } - MWindow window = BasicFactoryImpl.eINSTANCE.createTrimmedWindow(); - return openWorkbenchWindow(input, descriptor, window, true); + try { + MWindow window = BasicFactoryImpl.eINSTANCE.createTrimmedWindow(); + return openWorkbenchWindow(input, descriptor, window, true); + } catch (InjectionException e) { + throw new WorkbenchException(e.getMessage(), e); + } } public WorkbenchWindow openWorkbenchWindow(IAdaptable input, IPerspectiveDescriptor descriptor, |