Try setting the NSMenuDelegate
on your header file (the .h file), like this:
#import <Cocoa/Cocoa.h>
@interface AppDelegate : NSObject <NSApplicationDelegate,NSMenuDelegate>{
}
(or in the header file of the class that you need the selector to be called)