Re: Why are my menu items gray?
Re: Why are my menu items gray?
- Subject: Re: Why are my menu items gray?
- From: "Peter Karlsson" <email@hidden>
- Date: Wed, 23 Apr 2003 15:41:01 +0000
The deviceAction method is already implemented like this:
- (IBAction)deviceAction:(id)sender
{
NSLog(@"deviceAction");
}
Can it be my wiring in IB? menuOutlet is the Outlet connected to the whole
menu. deviceOutlet is the Outlet connected to just my device menu. Is that
right or wrong?
Peter
From: Phil Larson <email@hidden>
To: Peter Karlsson <email@hidden>
CC: email@hidden
Subject: Re: Why are my menu items gray?
Date: Wed, 23 Apr 2003 08:15:31 -0700
Make sure that you have a deviceAction: method already. If the menu
does't find its action then the items will be grey.
Phil
On Wednesday, April 23, 2003, at 07:48AM, Peter Karlsson
<email@hidden> wrote:
>Dear list!
>
>Can someone please tell me why my menu items are gray'ed out? It builds
10
>menu items, all with the title 'Cocoa', as expected, but they are all
gray
>and can't be clicked.
>
>int menuNum;
>NSMenuItem *menuItem;
>for(menuNum=0; menuNum <10; menuNum ++)
>{
>menuItem = [[NSMenuItem alloc] initWithTitle:@"Cocoa"
>action:@selector(deviceAction:)keyEquivalent:@""];
>[menuItem setTarget:menuOutlet];
>[deviceOutlet addItem:menuItem];
>}
>
>Peter
>
>
>
>
>
>
>_________________________________________________________________
>Add photos to your messages with MSN 8. Get 2 months FREE*.
>http://join.msn.com/?page=features/featuredemail
>_______________________________________________
>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.
_______________________________________________
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.
_________________________________________________________________
The new MSN 8: advanced junk mail protection and 2 months FREE*
http://join.msn.com/?page=features/junkmail
_______________________________________________
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.