• 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: Problems subclassing NSTableView and NSOutlineView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Problems subclassing NSTableView and NSOutlineView


  • Subject: Re: Problems subclassing NSTableView and NSOutlineView
  • From: Scott Anguish <email@hidden>
  • Date: Thu, 7 Jul 2005 02:14:54 -0400


On Jul 7, 2005, at 1:14 AM, Todd Blanchard wrote:

Do I need to add ivars to hang onto the controller, value transformer, etc as in the example code in the joystick view in "How bindings work" or is this just meant to illustrate what is going on? That seems like an awful lot of boilerplate for each binding - why does the controller not manage all of this - or does it?

No, the controller doesn't manage it. NSBinder isn't public, so you have to implement it yourself. You can do that as the example does (put it all in the one place) or you could create a class that encapsulates a binding, the value transformer, etc...).


that example is largely for illustrative purposes as you've guessed.

If you're only subclassing to add a new binding, and you can deal with being Tiger only, then you don't need cache values provided in other bindings that you might need... you can use -infoForBinding: to get the settings of a specific binding on the superclass.



Its also not clear how I get IB to provide UI for setting up the bindings.
Am I supposed to write a pallet for my NSOutlineView subclass or what?

Yes. That's the only way to get IB to see it. IB will ask the class for it's exposedBindings, but beyond that you're limited. You can do it programmatically without building a palette.



I have submitted my feedback regarding the docs - they're awful.

thanks for the feedback


_______________________________________________
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
References: 
 >Problems subclassing NSTableView and NSOutlineView (From: Todd Blanchard <email@hidden>)
 >Re: Problems subclassing NSTableView and NSOutlineView (From: mmalcolm crawford <email@hidden>)
 >Re: Problems subclassing NSTableView and NSOutlineView (From: Scott Anguish <email@hidden>)
 >Re: Problems subclassing NSTableView and NSOutlineView (From: Todd Blanchard <email@hidden>)

  • Prev by Date: Re: NSToolbar & autosave...
  • Next by Date: Re: Problems subclassing NSTableView and NSOutlineView
  • Previous by thread: Re: Problems subclassing NSTableView and NSOutlineView
  • Next by thread: Re: Problems subclassing NSTableView and NSOutlineView
  • Index(es):
    • Date
    • Thread