• 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: NSMenu doc bug?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSMenu doc bug?


  • Subject: Re: NSMenu doc bug?
  • From: Fritz Anderson <email@hidden>
  • Date: Sun, 6 Jan 2002 23:44:47 -0600

On Sunday, January 6, 2002, at 10:39 PM, Isaac Sherman wrote:
...
- (void)addItem:(id <NSMenuItem>)newItem
...
- (id <NSMenuItem>)addItemWithTitle:(NSString *)aString
action:(SEL)aSelector keyEquivalent:(NSString *)keyEquiv
...
Why the difference between the two items? Why would two very similar
functions be so different from each other (void/id <NSMenuItem>)? Is this
correct?

It is correct.

The idea is to add an NSMenuItem to an NSMenu. The first method adds an item that you have created yourself; the second creates one for you, and gives you back the item it created.

-- F


References: 
 >NSMenu doc bug? (From: Isaac Sherman <email@hidden>)

  • Prev by Date: Re: Lazy binding
  • Next by Date: Re:CurrencyConverterTutorial.pdf (Thanks:-)
  • Previous by thread: NSMenu doc bug?
  • Next by thread: Re: PB Q
  • Index(es):
    • Date
    • Thread