Re: addObserver:
Re: addObserver:
- Subject: Re: addObserver:
- From: Keary Suska <email@hidden>
- Date: Mon, 11 Aug 2008 08:38:18 -0600
- Thread-topic: addObserver:
8/11/08 8:15 AM, also sprach email@hidden:
> I'm making the following call (and defining observeValueForKeyPath on self
> etc) on an NSArrayController, hoping to get notifications of it changing. But
> I don't seem to be getting any notifications. Should this work?
>
>
> [arrayController addObserver:self
> forKeyPath:@"content"
> options:(NSKeyValueObservingOptionNew|NSKeyValueObservingOptionOld)
> context:nil];
It works, but perhaps not the way you want it to. You will receive
notifications any time the "content" property of your array controller is
changed (or led to believe that it has changed). I.e. any time the array
object itself is changed to another array object, *not* when the elements of
the array are changed.
HTH,
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