Community
Participate
Working Groups
Build Identifier: Eclipse 3.6 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) { } }); I tried the above code and it never calls the "public void menuShown(MenuEvent arg0)" method. Reproducible: Always
(In reply to comment #0) > I tried the above code and it never calls the "public void menuShown(MenuEvent > arg0)" method. Menu bars are only ever shown once.
(In reply to comment #1) > (In reply to comment #0) > > I tried the above code and it never calls the "public void menuShown(MenuEvent > > arg0)" method. > Menu bars are only ever shown once. Then what is the perpose of adding the method in Listner..? I want to change the name of My Menu Item on selecting the parent menu. What should I do?
(In reply to comment #2) > Then what is the perpose of adding the method in Listner..? Other menus can be shown repeatedly (think "dropdown" and popup menus). > I want to change the name of My Menu Item on selecting the parent menu. What > should I do? Please ask your question on the forums. http://www.eclipse.org/forums/
This is not a bug. Please ask questions on the forum/newsgroup. Closing as INVALID.