Binding to a "dotted" Key Path in an IBPalette. Should work?
Binding to a "dotted" Key Path in an IBPalette. Should work?
- Subject: Binding to a "dotted" Key Path in an IBPalette. Should work?
- From: Jerry Krinock <email@hidden>
- Date: Mon, 4 Jun 2007 21:34:10 -0700
I'm building an IBPalette containing a slightly complicated widget
which needs a little NSTableView in its IBInspector.
The NSTableColumns are bound in IB to an NSArrayController. This
array controller's object class is NSMutableDictionary, and its
contentArray is bound to a key path "object.indexedWidths" in my
IBInspector subclass, which is also the nib File's Owner. The -
object of my IBInspector subclass is correctly returned as my widget,
and my widget class is KVC-compliant for key "indexedWidths". The
key "indexedWidths" is dependent on a couple other keys, so in my
widget class I've implemented a +initialize method which invokes
[self setKeys:[NSArray arrayWithObjects:@"numberOfButtons",
@"widths",nil]
triggerChangeNotificationsForDependentKey:@"indexedWidths"] ;
Everything seems to be working, except that the array controller
doesn't seem to observe changes in my widget's indexedWidths.
Console does not show any errors or warnings when it runs.
Can anyone think of a reason why this might not work? I've presumed
that KVO will "just work" through "dotted" key paths like "a.b.c".
Is there a "piecewise" way to test this?
Thanks,
Jerry Krinock
_______________________________________________
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