View previous topic :: View next topic |
Author |
Message |
maxter
Joined: 17 May 2006 Posts: 34
|
Posted: Fri Sep 28, 2007 12:52 pm Post subject: Enabled menu items are shown grayed |
|
|
Code: |
override void onLoad(EventArgs ea)
{
menu = new MainMenu;
auto mi = new MenuItem;
menu.menuItems.add(mi);
mi.text = "Test";
//Workaround:
//if (mi.enabled)
// mi.enabled = true;
super.onLoad(ea);
}
|
Works fine if text is set before the menu item is added to the menu's collection |
|
Back to top |
|
|
Chris Miller
Joined: 27 Mar 2004 Posts: 514 Location: The Internet
|
Posted: Fri Sep 28, 2007 10:32 pm Post subject: Re: Enabled menu items are shown grayed |
|
|
It looks like Windows might be disabling menu items automatically if they're added with no text. I just put up a snapshot that re-enables as necessary. |
|
Back to top |
|
|
maxter
Joined: 17 May 2006 Posts: 34
|
Posted: Sat Sep 29, 2007 3:57 am Post subject: |
|
|
Thsnks |
|
Back to top |
|
|
|