Re: Bindings NSArrayController is changing selectionIndex
Re: Bindings NSArrayController is changing selectionIndex
- Subject: Re: Bindings NSArrayController is changing selectionIndex
- From: Ondra Cada <email@hidden>
- Date: Mon, 20 Sep 2004 04:28:59 +0200
On 20.9.2004, at 4:14, Scott Stevenson wrote:
[logArrayController addObserver:self
forKeyPath:@"selectionIndex"
options:
NSKeyValueObservingOptionNew|NSKeyValueObservingOptionOld
context:nil];
You really want to put the options in parenthesis (bitwise or):
options: (NSKeyValueObservingOptionNew|NSKeyValueObservingOptionOld)
In this case, there really is no need at all. That may be needed in
more complicated expressions, but not here.
I'm not sure offhand if this is causing your problem with receiving
NSNull for the values.
I am sure. Whatever may cause the problem, it is not the missing
superfluous parentheses :)
---
Ondra Čada
OCSoftware: email@hidden http://www.ocs.cz
private email@hidden http://www.ocs.cz/oc
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden