• 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: Data Source object for NSTableView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Data Source object for NSTableView


  • Subject: Re: Data Source object for NSTableView
  • From: mmalcolm crawford <email@hidden>
  • Date: Sat, 21 Feb 2004 10:50:53 -0800

On Feb 21, 2004, at 9:39 AM, Ryan Bates wrote:

On Feb 19, 2004, at 10:38 PM, Jerry Krinock wrote:
I'm thinking of wiping out my Data Source object, and incorporating all its
methods and data into the File Owner, my subclassed NSWindowController. Is
that the correct way to do it? If not, what object type should it be a
subclass of?

I find if I throw everything at the window controller then it starts to get very complicated and unorganized. Now I try to keep most of my UI handling in several smaller controller classes and the window controller ties these classes all together. One example is a TableViewController which acts as both the data source and the delegate. [...]

This is, of course, the pattern that the new NSController classes follow...

It is a little bit tricky keeping the two arrays in sync when some of the data changes, but for me it is well worth it for a cleaner design.

with the advantage that they keep data in sync for you.

mmalc
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Data Source object for NSTableView
      • From: Scott Anguish <email@hidden>
    • Re: Data Source object for NSTableView
      • From: Finlay Dobbie <email@hidden>
References: 
 >Data Source object for NSTableView (From: Jerry Krinock <email@hidden>)
 >Re: Data Source object for NSTableView (From: Ryan Bates <email@hidden>)

  • Prev by Date: Re: Removing the title bar from a window (i.e. a splash screen...)
  • Next by Date: Re: NSStepperCell help
  • Previous by thread: Re: Data Source object for NSTableView
  • Next by thread: Re: Data Source object for NSTableView
  • Index(es):
    • Date
    • Thread