Re: KVO Bug With Keypaths
Re: KVO Bug With Keypaths
- Subject: Re: KVO Bug With Keypaths
- From: Keary Suska <email@hidden>
- Date: Tue, 01 Jul 2008 19:12:46 -0600
- Thread-topic: KVO Bug With Keypaths
7/1/08 5:13 PM, also sprach email@hidden:
> So to clarify: "related" is a dictionary that always contains a key
> called "content", the object for which is a dictionary that always
> contains a key called "status", the object for which is always
> KVO-compliant for "value"?
"relations" (the object being sent the addObserver message) is a dictionary:
"related" is an object, "content" is a dictionary; "value" is a property of
"status", another object.
> And you can getValueForKey:@"order.related.content.status.value"
> directly, but when you set the object for either of those keys, you
> fail to get notified?
Yes, but the problem I am seeing is that when "related" is changed, KVO
notifications aren't sent, even though everything descending from it must
have changed too by implication. I also tested setting "value", which isn't
working either.
> What happens if you register for notifications for
> @"order.related.content.status", @"order.related.content", etc.? Do
> you get any of those notifications?
Nope, none, even "order.related", i.e. when I change "related" or
"status.value". Note that other observers who are watching "status.value",
do get notifications--at least ones that are not observing through
"related".
My initial tests seem to indicate some problem observing through
relations/related, although I have NSController subclasses (using bindings)
that don't seem to have any issues, although their key path starts at the
object that own "relations".
Best,
Keary Suska
Esoteritech, Inc.
"Demystifying technology for your home or business"
_______________________________________________
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