Re: Bindings and the selected object
Re: Bindings and the selected object
- Subject: Re: Bindings and the selected object
- From: Steve Israelson <email@hidden>
- Date: Fri, 25 May 2007 14:06:10 -0700
So far, the way I am making it work is in the
tableViewSelectionDidChange method I am fetching the selection object
and setting its reference myself. I was hoping a binding could do
this but I can't figure out how, but this works great so far.
On 25-May-07, at 1:43 PM, Steve Israelson wrote:
I have a CoreData object graph of "item" entities.
I have an Array controller setup for an "item" entity.
I have a TableView bound to the controller to show all the "item"
entities.
Now, in another nib file, or maybe in a nib loaded from a plug-in,
I have an inspector that can inspect the selected "item" entity.
I need it to show the details of the item selected in the array
controller above.
I do NOT want to tightly couple these NIB's or classes at all since
the plug-ins will be written by third parties.
My idea for this is to have a SINGLE "selection" entity object that
has a reference to one of the "item" entities and have that get set
by the array controller when a selection is made.
The anyone can fetch this "selection" entity and bind to its
reference to the selected item.
This seems like an ideal solution.
The problem I am trying to figure out is how to have the array
controller set the selection reference in the "selection" entity.
I am experimenting with an Object controller to do this and it
seems like maybe it will work.
Is this the right way to go, or what? (mmalc I am looking at you :) )
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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