Disable (grey out) main menu when displaying modal window?
Disable (grey out) main menu when displaying modal window?
- Subject: Disable (grey out) main menu when displaying modal window?
- From: Darren Wheatley <email@hidden>
- Date: Tue, 25 Jan 2011 08:45:47 +0000
- Thread-topic: Disable (grey out) main menu when displaying modal window?
Hi,
I load a custom file import window in my Cocoa app using:
[NSApp runModalForWindow:window];
The window displays just fine, and is modal.
However, the application main menu is still active (e.g. File menu and
items), which is making the modal display redundant.
I've googled this and searched the docs, but can't find a way to turn the
menu off.
Someone suggested using this:
NSModalSession session = [NSApp beginModalSessionForWindow:window];
[NSApp runModalSession];
- but that doesn't seem to work either. Again, the window displays but the
main menu is still active.
Can anyone suggest how I turn the main menu off (grey out all menu items)
when displaying a modal window please?
Thanks
Darren.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden