• 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
Custom Cell Bindings
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Custom Cell Bindings


  • Subject: Custom Cell Bindings
  • From: Seth Willits <email@hidden>
  • Date: Fri, 02 Sep 2011 17:12:30 -0700

Say I have a custom NSCell subclass (or maybe NSActionCell) which implements some custom UI for manipulating some immutable value type which I can't use any of the standard cell subclasses for. If this cell is the data cell in a table column, binding the column's content to an array controller gets the values to the custom cell and they're displayed correctly. Easy peasy.

What I can't figure out for the life of me is how to change the value in the cell and get that change back into the original array. If the object is mutable and you're changing some property of it, that's straightforward, but how do you change the entire value if it's immutable? NSCell has a "value" binding, which I thought maybe would be bound to something, but it's not.

As far as I can tell, there's no way to change the object value of the cell and reflect the change in the array controller's content. I've been looking in the documentation, headers, and Googling for clues for an hour now and I really can't find an answer. Surely someone has to have done this. :\


--
Seth Willits

_______________________________________________

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: Custom Cell Bindings
      • From: Quincey Morris <email@hidden>
    • Re: Custom Cell Bindings
      • From: Quincey Morris <email@hidden>
  • Prev by Date: Re: Possible causes of "attempted layout while textStorage is editing"?
  • Next by Date: KVO on objects in NSArrayController
  • Previous by thread: Re: NSOutlineView - Items only displays when user scrolls in outline view
  • Next by thread: Re: Custom Cell Bindings
  • Index(es):
    • Date
    • Thread