Skip to main content



      Home
Home » Eclipse Projects » Plugin Development Environment (PDE) » How to change the name of Custom Menu Item on selecting the parent menu(Plugin Development)
icon5.gif  How to change the name of Custom Menu Item on selecting the parent menu [message #647290] Wed, 05 January 2011 10:18 Go to next message
Eclipse UserFriend
Hi,

I wan to change the name of my Custom Menu item on clicking the parent Menu.

For that I am using following code:

IWorkbench workbench = Activator.getDefault().getWorkbench(); //PlatformUI.getWorkbench();
Menu menubar = workbench.getActiveWorkbenchWindow().getShell().getMenuBar() ;

menubar.addMenuListener(new MenuListener() {

@Override
public void menuShown(MenuEvent arg0) {
}

@Override
public void menuHidden(MenuEvent arg0) { }
});

but it never calls the public void menuShown(MenuEvent arg0) {} method while the menuHidden method is working fine.

What should I do? Any work around?
Thanks in advance.
Re: How to change the name of Custom Menu Item on selecting the parent menu [message #647359 is a reply to message #647290] Wed, 05 January 2011 13:44 Go to previous messageGo to next message
Eclipse UserFriend
You want org.eclipse.platform
PW

--
Paul Webster
http://wiki.eclipse.org/Platform_Command_Framework
http://wiki.eclipse.org/Command_Core_Expressions
http://wiki.eclipse.org/Platform_Expression_Framework
http://wiki.eclipse.org/Menu_Contributions
http://wiki.eclipse.org/Menus_Extension_Mapping
http://help.eclipse.org/galileo/index.jsp?topic=/org.eclipse .platform.doc.isv/guide/workbench.htm
Re: How to change the name of Custom Menu Item on selecting the parent menu [message #647360 is a reply to message #647290] Wed, 05 January 2011 13:44 Go to previous messageGo to next message
Eclipse UserFriend
Sorry, you want eclipse.platform

PW

--
Paul Webster
http://wiki.eclipse.org/Platform_Command_Framework
http://wiki.eclipse.org/Command_Core_Expressions
http://wiki.eclipse.org/Platform_Expression_Framework
http://wiki.eclipse.org/Menu_Contributions
http://wiki.eclipse.org/Menus_Extension_Mapping
http://help.eclipse.org/galileo/index.jsp?topic=/org.eclipse .platform.doc.isv/guide/workbench.htm
Re: How to change the name of Custom Menu Item on selecting the parent menu [message #647414 is a reply to message #647360] Thu, 06 January 2011 02:15 Go to previous messageGo to next message
Eclipse UserFriend
Hi Paul,

You mean I need to add eclipse.platform as dependencies and then it will work?

If it is so then I tried the same but it is still not working.

Thanks,
Dharmang
Re: How to change the name of Custom Menu Item on selecting the parent menu [message #647445 is a reply to message #647414] Thu, 06 January 2011 07:29 Go to previous message
Eclipse UserFriend
On 01/06/2011 02:15 AM, Dharmang wrote:
> If it is so then I tried the same but it is still not working.

Sorry, I should have been more clear. Menus are a contribution
controlled by the platform, so you should ask your question in the
eclipse.platform newsgroup.

PW


--
Paul Webster
http://wiki.eclipse.org/Platform_Command_Framework
http://wiki.eclipse.org/Command_Core_Expressions
http://wiki.eclipse.org/Platform_Expression_Framework
http://wiki.eclipse.org/Menu_Contributions
http://wiki.eclipse.org/Menus_Extension_Mapping
http://help.eclipse.org/galileo/index.jsp?topic=/org.eclipse .platform.doc.isv/guide/workbench.htm
Previous Topic:Dynamic target platform
Next Topic:Synchronize product definition to plugin.xml in headless build?
Goto Forum:
  


Current Time: Fri Jul 04 17:52:58 EDT 2025

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

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

Back to the top