KVO on NSDictionary elements
KVO on NSDictionary elements
- Subject: KVO on NSDictionary elements
- From: Gustavo Pizano <email@hidden>
- Date: Thu, 11 Mar 2010 11:19:35 +0100
Hello all.
Im implementing a live filter, and each, time I insert a filter in the filterDictionary the controller (which is another class) gets notified about the insertion.\
I was reading the KVO, and its says something about NSKeyValueChangeKindKey.
So this is what Im doing in the Controller class:
[_filterController addObserver:self forKeyPath:@"_filterSettings" options:(NSKeyValueObservingOptionNew|NSKeyValueObservingOptionOld) context:NULL];
so I undertand that as it is above I will get notified only when I setUp a new NSDictionary in the ivar _filterSettings, obviously Im not getting notified when I insert something in the _filterSettings dictionary.
How should I add the observer? is it possible to do so?
thanks
Gustavo
_______________________________________________
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