• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: _openRecentDocument undocumented?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: _openRecentDocument undocumented?


  • Subject: Re: _openRecentDocument undocumented?
  • From: Fritz Anderson <email@hidden>
  • Date: Tue, 26 Jul 2005 12:22:14 -0500

On 25 Jul 2005, at 2:55 PM, Theodore H. Smith wrote:

My validateMenuItem worked something like this:


SEL s = [MyMenuItem action]; if (s == @selector(sel1:) and [self Test1]) { return true; } else if (s == @selector(sel2:) and [self Test2) { return true; } else if (s = @selector(aMenuThatShouldAlwaysBeEnabled) { return true; } return false;

Now, I "fixed" that by checking for the selector "_openRecentDocument:", but that doesn't quite seem right to me :o) So perhaps I'm using the wrong fix.

_openRecentDocument: is a method of your superclass, isn't it? Then it makes sense that your superclass recognizes and validates that item.


Don't turn off every menu item you don't know about. Return [super validateMenuItem: aMenuItem].

    -- F

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: _openRecentDocument undocumented?
      • From: "Theodore H. Smith" <email@hidden>
References: 
 >_openRecentDocument undocumented? (From: "Theodore H. Smith" <email@hidden>)

  • Prev by Date: Re: Updating an NSMovieView in a busy loop
  • Next by Date: Re: Using @count set operator with CoreData relationships raises exception?
  • Previous by thread: _openRecentDocument undocumented?
  • Next by thread: Re: _openRecentDocument undocumented?
  • Index(es):
    • Date
    • Thread