How may I get the NSMenu for the application menu (the one in the menu bar next to the apple menu).
This doesn't work on my old carbon app, mainMenu returns nil.
NSMenu *mainMenu = [[NSApplication sharedApplication] mainMenu];
NSMenu *appMenu = [[mainMenu itemAtIndex:0] submenu];
for (NSMenuItem *item in [appMenu itemArray]) {
NSLog(@"%@", [item title]);
}