Re: Making a bound view re-read its value
Re: Making a bound view re-read its value
- Subject: Re: Making a bound view re-read its value
- From: Caleb Strockbine <email@hidden>
- Date: Fri, 15 Aug 2008 00:47:08 -0400
On Aug 14, 2008, at 8:36 PM, Markus Spoettl wrote:
When the user changes the preference, the view should update its value
so it uses the right units. There is no change to the underlying data,
so there's no change notification that would force the binding to
refresh the view.
So how can I manually make the view update? It seems so simple but I
can't figure out how to do this.
Why not use -setKeys:triggerChangeNotificationsForDependentKey:? Make
the key for your data dependent on the key for the preference, so
that anyone who's watching the data will get a notification when the
preference changes. This way, you don't worry about manually updating
the view -- it'll happen automatically.
cheers,
-Caleb
_______________________________________________
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