• 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
NSOutlineView multi cell type binding query
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSOutlineView multi cell type binding query


  • Subject: NSOutlineView multi cell type binding query
  • From: "email@hidden" <email@hidden>
  • Date: Tue, 5 Oct 2010 11:53:05 +0100

Morning

My NSOutlineView binds its NSTableColumn instances to NSTextFieldCells using NSValueBinding.

Some cells are required to contain NSPopUpButtonCell instances so the cell type is manipulated in - outlineView:dataCellForTableColumn:item:

NSPopUpButtonCell doesn't support value binding so the normal target->action approach is adopted to update the model.

However it appears that the binding machinery causes the NSPopUpButtonCell selection to be reset after the user has interacted with the control.

I therefore have to resync the NSPopUpButtonCell selection to the model in - outlineView:willDisplayCell:forTableColumn:item:

Is this expected behaviour using multiple NSCell subclasses or is it bug like?
Or should I try and directly bind the NSPopUpButtonCell instance in  - outlineView:dataCellForTableColumn:item:?

Presumable if a cell doesn't support a particular binding its state should remain unaltered.

Regards

Jonathan Mitchell

Developer
Mugginsoft LLP
http://www.mugginsoft.com







_______________________________________________

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: NSOutlineView multi cell type binding query
      • From: Quincey Morris <email@hidden>
  • Prev by Date: Partially opaque window with opaque views
  • Next by Date: Re: Partially opaque window with opaque views
  • Previous by thread: Re: Partially opaque window with opaque views
  • Next by thread: Re: NSOutlineView multi cell type binding query
  • Index(es):
    • Date
    • Thread