On Sun, Feb 1, 2009 at 11:45 AM, Chris Idou <[email protected]> wrote: > I've got an NSTextView whose attributeValue is bound to a core-data object. > > I've got a menu item which programmatically modifies the NSTextView's > contents. > > The programmatic changes don't trigger a modification to the underlying > object unless the user tabs to and exits the NSTextView manually. > > What is the correct way, when programmatically modifying an NSTextView, to > make sure the system propagates changes to underlying bindings?
The correct way is not to do it in the first place. Views are there for the user to modify, not for your program to modify. Bindings are two-directional: your program should change the *model*, and then the binding will ensure that the NSTextView matches that change. Mike _______________________________________________ Cocoa-dev mailing list ([email protected]) 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 [email protected]
