Re: Disable a menu (item)
Re: Disable a menu (item)
- Subject: Re: Disable a menu (item)
- From: Markus Hitter <email@hidden>
- Date: Mon, 10 Dec 2001 23:56:53 +0100
Am Montag den, 10. Dezember 2001, um 21:20, schrieb Matt Neuburg:
I'd like to disable the File menu. I see how to disable all its
menu items by disabling the File menu item of the main menubar.
What I don't see is how to make the word "File" itself be
grayed out.
Two ways:
1) remove the action method and the corresponding item will be
grayed automatically. You might want to store a pointer to the
method to add it again later.
2) disable the automatic disable detection, then disable it manually
( [... setEnabled:NO] ).
Details for both see NSMenu and NSMenuItem.
Have fun,
Markus
- - - - - - - - - - - - - - - - - - -
Dipl. Ing. Markus Hitter
http://www.jump-ing.de/