• 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: Design question, which controller class to use
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Design question, which controller class to use


  • Subject: Re: Design question, which controller class to use
  • From: Jens Alfke <email@hidden>
  • Date: Sun, 20 Jul 2008 20:24:25 -0700


On 20 Jul '08, at 8:05 PM, James W. Walker wrote:

Since there is a window (which has a title that depends on the data) I thought I should use a subclass of NSWindowController. On the other hand, there is an array being displayed in a table, and I gather that's easier to set up using bindings if I use an NSArrayController. Any suggestions or references?

Those are two very different types of controllers, and you should probably use both.
An NSWindowController helps manage a window. It's a good idea to use these for all non-document windows. This will be the "file's owner" in your nib.
An NSArrayController manages an NSArray and lets you bind GUI controls to it. So you'd probably put one of those in your nib as well, to help run your table.


—Jens

Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Design question, which controller class to use
      • From: Ken Thomases <email@hidden>
References: 
 >Design question, which controller class to use (From: "James W. Walker" <email@hidden>)

  • Prev by Date: Design question, which controller class to use
  • Next by Date: RE: setting image for person in address book
  • Previous by thread: Design question, which controller class to use
  • Next by thread: Re: Design question, which controller class to use
  • Index(es):
    • Date
    • Thread