Re: NSPopupButton in main window changes when NSUserDefaultsController adds/removes item in Preference Pane
Re: NSPopupButton in main window changes when NSUserDefaultsController adds/removes item in Preference Pane
- Subject: Re: NSPopupButton in main window changes when NSUserDefaultsController adds/removes item in Preference Pane
- From: Matt Neuburg <email@hidden>
- Date: Tue, 03 Jul 2007 10:42:22 -0700
- Thread-topic: NSPopupButton in main window changes when NSUserDefaultsController adds/removes item in Preference Pane
On Tue, 3 Jul 2007 11:33:05 +1000, Tony Kambourakis
<email@hidden> said:
>> I have an NSPopupButton in my main application window that is bound
>> to an NSArrayController which in turn is bound to the Defaults
>> Controller (NSUserDefaultsController) point to that list of items.
>>
>> I initially set the NSPopupButton to "unselect" items so that even
>> though it has content via the bindings to the default list of items,
>> it shows a blank item as nothing is selected.
>>
>> As soon as I add/remove an item in the Preference window table, for
>> some reason the NSPopupButton selects the first item on its list. I
>> would rather the user make the selection. I don't know why the
>> NSPopupButton updates itself like that. Why would the selection of an
>> item in NSPopupButton be linked to the process of adding/removing an
>> item to the NSUserDefaultsController?
You evidently imply above that the popup button's *content* is bound. But
what about the popup button's *selection*? It needs to get selectedIndex
info from somewhere. m.
--
matt neuburg, phd = email@hidden, <http://www.tidbits.com/matt/>
A fool + a tool + an autorelease pool = cool!
AppleScript: the Definitive Guide - Second Edition!
<http://www.amazon.com/gp/product/0596102119>
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden