Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » MenuManager ID to locationURI mapping
MenuManager ID to locationURI mapping [message #235977] Thu, 16 July 2009 11:07
Peter Saunders is currently offline Peter SaundersFriend
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
Previous Topic:Debugger: Visualise array (draw graph or similar)
Next Topic:Build variable for directory of "selected resource"?
Goto Forum:
  


Current Time: Tue Sep 24 11:28:28 GMT 2024

Powered by FUDForum. Page generated in 0.03644 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top