It sounds like you're accessing the variable directly, which doesn't
allow the KVO system to send the appropriate notifications in order to
notify the menu item that there was a change. If you want to set the
value of the variable and expect the menu item to respond, you must
make sure the appropriate KVO notifications are being sent. This can
be done in several ways - through generated accessors (properties) or
sending the willChangeValueForKey/didChangeValueForKey messages
manually.

Try reading up on KVC:
http://developer.apple.com/documentation/Cocoa/Conceptual/KeyValueCoding/Concepts/BasicPrinciples.html
and KVO: 
http://developer.apple.com/documentation/Cocoa/Conceptual/KeyValueObserving/Concepts/Overview.html

(KVO/KVC are the technologies that the bindings system relies on.)

... and could you post the relevant code?

David
_______________________________________________

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