|
| Re: Menu contribution to a submenu? [message #827479 is a reply to message #827090] |
Fri, 23 March 2012 07:43   |
Paul Webster Messages: 6813 Registered: July 2009 Location: Ottawa |
Senior Member |
|
|
No, the constant in the locationURI is the parent menu id. To target a specific view context menu, you would use its id: popup:org.eclipse.ui.views.ProblemsView. To target any view context menu, that's where popup:org.eclipse.ui.popup.any comes in, but it only works at the root level.
If your root context menu was x.id, in your second context menu you could add a submenu that was x.id with the appropriate group marker in it. Then the same popup:x.id contribution would apply to the root menu in one and the submenu in the other.
The other thing you could try adding the root level menu to popup:your.context.menu.id and then creating a second menuContribution to popup:the.second.context.menu.id and actually add something like:
<menu some.random.id>
... the menu contents.
</menu>
Later,
PW
Paul Webster
http://wiki.eclipse.org/Platform_Command_Framework
http://wiki.eclipse.org/Command_Core_Expressions
http://wiki.eclipse.org/Menu_Contributions
|
|
|
|
Powered by
FUDForum. Page generated in 0.01543 seconds