• 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: Delegates -- WHAT is delegated?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Delegates -- WHAT is delegated?


  • Subject: Re: Delegates -- WHAT is delegated?
  • From: glenn andreas <email@hidden>
  • Date: Tue, 19 Dec 2006 21:46:19 -0600


On Dec 19, 2006, at 9:33 PM, Sam Colombo wrote:

I got the latter from the Apple Reference Library:
<http://developer.apple.com/documentation/Cocoa/Conceptual/ CocoaFundamentals
/CommunicatingWithObjects/chapter_6_section_4.html#//apple_ref/doc/ uid/TP400
02974-CH7-SW22>


"Delegation and the Application Kit

The delegating object in an application is often an NSApplication, NSWindow,
or NSView object. The delegate object itself is typically, but not
necessarily, an object, often a custom object, that controls some part of
the application (that is, a coordinating controller object)."

This does not imply that all views have delegate, or even NSView specifically - rather things which are NSViews (i.e., subclasses of NSView) have delegates.



But how can you tell (or specify) what methods of a class are delegatable?

Open up the documentation window in XCode.

Type "setDelegate:" (without the quotes) into the search field - it will display those classes that have delegates - there's about 50 of them or so (plus their subclasses).

Pick any class that has a setDelegate method. Scroll down through the documentation - near the bottom will be the "Delegate Methods by Task" (and "Delegate Methods" which are in alphabetic order). Lists everything a delegate can implement to alter the behavior of the object.



Glenn Andreas email@hidden
<http://www.gandreas.com/> wicked fun!
quadrium2 | build, mutate, evolve, animate | images, textures, fractals, art



_______________________________________________

Cocoa-dev mailing list (email@hidden)

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


References: 
 >Re: Delegates -- WHAT is delegated? (From: Sam Colombo <email@hidden>)

  • Prev by Date: Re: Delegates -- WHAT is delegated?
  • Next by Date: Re: Delegates -- WHAT is delegated?
  • Previous by thread: Re: Delegates -- WHAT is delegated?
  • Next by thread: Re: Delegates -- WHAT is delegated?
  • Index(es):
    • Date
    • Thread