Bug 406206 - Window menu does not work due to exception in HandlerProxy
Summary: Window menu does not work due to exception in HandlerProxy
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.3   Edit
Hardware: PC Windows 7
: P5 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform UI Triaged CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords: helpwanted
Depends on:
Blocks:
 
Reported: 2013-04-22 06:00 EDT by Nobody - feel free to take it CLA
Modified: 2020-05-05 14:49 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nobody - feel free to take it CLA 2013-04-22 06:00:41 EDT
We programmatically copy extensions to "org.eclipse.ui.menus" into the E4 application model to display window menu items using the this code:

>> our code
------
WorkbenchPlugin.getDefault().initializeContext(eclipseContext);
new MenuPersistence(application, context).reRead();
context.set(IEvaluationService.class, new EvaluationService(context));
new LegacyHandlerService(context).readRegistry();
------

This did work in the earlier 4.3 milestones.
After some changes made to HandlerProxy, specially to isOkToLoad(), the window menu items do not work. They show normally, but when an item is clicked nothing happens on the UI.

The reason for this behavior is this code:

>> org.eclipse.ui.internal.handlers.HandlerProxy.isOkToLoad()
------
if (PlatformUI.getWorkbench().isClosing())
	return handler != null;
...
------

PlatformUI.getWorkbench() throws a runtime exception in the pure E4 world of our application.
Comment 1 Nobody - feel free to take it CLA 2013-04-22 06:08:58 EDT
Related to the fix of bug 385953
Comment 2 Nobody - feel free to take it CLA 2013-04-22 11:53:17 EDT
This did _NOT_ work in the earlier 4.3 milestones.
It worked longer time ago...
Comment 3 Eclipse Genie CLA 2020-05-05 14:49:25 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.