Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » SubMenu in PopUp Menu
SubMenu in PopUp Menu [message #47254] Sat, 24 May 2003 23:07
MorPheus is currently offline MorPheusFriend
Messages: 57
Registered: July 2009
Member
Hi,

I want to have submenu in a PopUp Menu.I have created the SWT menu using
the menu class(org.eclipse.swt.widgets.Menu).I tried creating sub menu by
giving parent menu as argument but it doesn't show up.I also tried by giving
menu item as argument still I am not able to get it.I also tried setting
Menu.setVisible(true) but in vain.

How to do solve this problem.

Here is the snippet

//snippet

public RateManagerPocD220503V01PopUp(final Composite parent, final
RateManagerPocD220503V01Book editorBook) {


menu = new Menu(parent.getShell(),SWT.POP_UP);



cut = new MenuItem (menu, SWT.CASCADE);

clearContents = new MenuItem(menu,SWT.CASCADE);

subMenu = new Menu(clearContents);

subMenuItem = new MenuItem(subMenu,SWT.PUSH);


cut.setText("&Cut");

copy.setText("Copy");

clearContents.setText("Clear Contents");

parent.setMenu(menu);



}

//End of Snippet

MorPheus
Previous Topic:Synchronized views
Next Topic:First version of my plugin is out there
Goto Forum:
  


Current Time: Sat Dec 21 12:07:26 GMT 2024

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

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

Back to the top