开发者

Why, if I bind to an NSPathControl, is it grayed out?

开发者 https://www.devze.com 2023-02-17 13:37 出处:网络
I have bound the value of an NSPathControl through a value transformer that converts strings to URLs to my model (a NSMutableArray of NSMutableDictionaries). I have the control\'s target/action set up

I have bound the value of an NSPathControl through a value transformer that converts strings to URLs to my model (a NSMutableArray of NSMutableDictionaries). I have the control's target/action set up.

With the binding in place开发者_如何学Python the control works, showing the path from my model as my table selection is changed. However, it is grayed out and does not accept clicks. Why is this?

If I explicitly set the path control to enabled to YES in code, it makes no difference.

If I remove the binding, it shows whatever path I give it in IB, it is not grayed out, and clicks are accepted and run my action.

I am not using the Enabled binding of the path control. Should I be?

I'm using Xcode 4 and 10.6.


The answer turned out to be that Conditionally Sets Enabled was turned on (the default). Turning that off appears to have fixed it. Chalk another one up for bindings opacity.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号