MenuManager ID to locationURI mapping [message #235977] |
Thu, 16 July 2009 11:07 |
Peter Saunders Messages: 30 Registered: July 2009 |
Member |
|
|
Hi
I'm attempting to add a context menu to a new editor plug-in. I have
created
and registered the Menu as follows:
MenuManager mgr = new MenuManager("MyMenuManagerText",
"#MyMenuManagerID");
Menu contextMenu = mgr.createContextMenu(myEditorControl);
getSite().registerContextMenu(mgr, myEditorControl);
My new context menu item is specified in my editor's plugin.xml as follows:
<extension point="org.eclipse.ui.menus">
<menuContribution locationURI="popup:#MyMenuManagerID">
<command> ... </command>
</menuContribution>
</extension>
My new context menu item does not appear in my context menu, but when I use
locationURI="popup:org.eclipse.ui.popup.any?after=additions " it does
appear.
Presumably, I am not specifying the URI for my own context menu correctly.
What is the correct mapping between the MenuManager ID and the locationURI?
Thanks
Peter Saunders
|
|
|
Powered by
FUDForum. Page generated in 0.03644 seconds