validating menu items
validating menu items
- Subject: validating menu items
- From: April Gendill <email@hidden>
- Date: Tue, 14 Oct 2003 20:39:32 -0700
I'm trying to validate menu items as follows
- (BOOL)validateMenuItem:(id <NSMenuItem>)theItem
{
SEL theAction = [theItem action];
* items to validate here *
it works just fine when [theItem action] points to something with in
the main controller class.
but if I try to point to something outside the class it does not work.
I'm using:
if(([theItem target] ==pointerToClassInQuestion) && someCondition){
return NO;
}
In interface builder I've connected the classes to one another and
calling any information passed back and forth works just fine. Only the
validateMenuItem function fails.
Any ideas?
April
_______________________________________________
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.