Bindings not staying in sync when using NSPopUpButton selectItemWithTitle
Bindings not staying in sync when using NSPopUpButton selectItemWithTitle
- Subject: Bindings not staying in sync when using NSPopUpButton selectItemWithTitle
- From: Tod Cunningham <email@hidden>
- Date: Sat, 11 Sep 2004 23:47:55 -0400
I am just wondering if this is a bug or by design for some reason. I
have a NSPopUpButton that is bound via cocoa bindings. When I change
the data it is bound to the popup works fine. However, if I change the
value of the popup via selectItemWithTitle the popup's value changes,
but the bound data doesn't get updated.
if( [bandPopUpButton itemWithTitle:[menuItem title]] != nil )
{
// Works find and the popup's value gets updated
[m_contact setBand:[menuItem title]];
// !! TC !! Why do I have to call setBand. If I just
try to call selectItemWithTitle
// the datamodel isn't getting updated.
//[bandPopUpButton selectItemWithTitle:[menuItem
title]];
}
Thanks,
Tod Cunningham
_______________________________________________
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