Problem with submenus
Problem with submenus
- Subject: Problem with submenus
- From: Jesus De Meyer <email@hidden>
- Date: Thu, 11 Apr 2002 21:11:00 +0200
I'm creating an app uses NSPopUpButtons with Submenus. Those submenus
are created programmatically. The problem I'm having is that the items
on the submenu are not made active even if explecitly tell them to be
active.
Here 's a piece of my code of one submenu:
NSMenu *fMenu = [[NSMenu alloc] initWithTitle:@"test"];
[fMenu addItemWithTitle:@"Hey! Same team!" action:nil keyEquivalent:@""];
[fMenu addItemWithTitle:@"On your team" action:nil keyEquivalent:@""];
[[speechMenu menu] setSubmenu:fMenu forItem:[speechMenu itemAtIndex:1]];
for (i=0; i < [fMenu numberOfItems]; i++) {
[[fMenu itemAtIndex:i] setEnabled:YES];
}
//speechMenu is an NSPopUpButton created in IB
Thanks in advance
______________________________
Jesus De Meyer
CEO @ E dot software
http://homepage.mac.com/edotsoftware
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.