In the example for NSCollectionView, they show binding text labels to the 
collection view item's represented object's properties. This is fine and makes 
sense.

But my item view contains a custom view that needs access to the represented 
object in the NSCollectionViewItem. Since my custom view can't be bound within 
IB, I need to bind it programmatically. But I can't find the right place to do 
this. I tried doing it in awakeFromNib, with an outlet in my custom view to the 
NSCollectionViewItem, but it's sometimes nil (Currently I have data for two 
items, and the first time awakeFromNib is called, the item outlet is set, and 
the second time, it's not; not sure why).

When does IB actually set the bindings specified in the nib? When can I add 
bind: calls and have access to both my view instance and the 
NSCollectionViewItem?

TIA,
Rick

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to