On 15/10/2010, at 3:13 AM, Andreas Höschler wrote:

> The validateMenuItem: method is not implemented or always returns YES: The 
> delegate of the window is my document controller class. This really should 
> work and it does on MacOSX 10.2, but on MacOSX 10.5 the menu items are all 
> greyed out. What am I doing wrong?


I suspect that NSTextView implements the more modern version of 
-validateMenuItem:, which is -validateUserInterfaceItem: this is stealing the 
processing that would have gone to -validateMenuItem: under the older OS.

Your text view subclass should override -validateUserInterfaceItem: and 
validate the menu items, passing anything else to super. Note that the delegate 
is not necessarily automatically involved if the view implements the validation 
itself. 

I could be wrong on this, but it's got to be worth a try. I've certainly 
experienced similar symptoms because of this.

--Graham


_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to