The KVC infrastructure did not always generate value-changed notifications for setValue:forUndefinedKey: overrides.

The setValue:forUndefinedKey: override should have nothing to do with it. It's the setValue:forKey: call -- the one which provokes the call to setValue:forUndefinedKey: -- that's responsible for triggering the KVO change notifications.

Doubting my own sanity (always a good approach, IMO) I searched for, and found some evidence of this in an old discussion:

http://www.cocoabuilder.com/archive/message/cocoa/2006/10/12/172593

That thread doesn't confirm what you're saying. It says the opposite. It says what I just said. If you override setValue:foKey: _then_ you lose automatic KVO notifications and would have to reimplement them yourself, but if you just override setValue:forUndefinedKey: you don't have that problem.

Indeed! I feel like a jackass, thanks for catching this :-)

Gabe
_______________________________________________

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