On 17/02/2010, at 15:53 , Graham Cox wrote:
> On 17/02/2010, at 6:49 PM, Peter N Lewis wrote:
>
>> Is there any way to dynamically populate a popup menu on the fly (as it is
>> exposed)?
>
> Look into the NSMenuDelegate protocol. It has methods to do what you want.
Yes,
On 18/02/2010, at 3:00 AM, Steven Degutis wrote:
> While NSMenuDelegate isn't wrong per se, I still prefer to use the
> NSPopUpButton's notification myself. Touching the button's internal menu
> seems like dipping my fingers where they don't belong.
NSMenuDelegate works fine with pop-up buttons
ocol.
> There is some method to dynamically populate the menu.
>
> Le 17 févr. 2010 à 16:09, Steven Degutis a écrit :
>
> > Check out NSPopUpButton's NSPopUpButtonWillPopUpNotification
> >
> > On Wed, Feb 17, 2010 at 2:49 AM, Peter N Lewis
> > wrote:
&
ee NSMenuDelegate protocol.
> There is some method to dynamically populate the menu.
>
> Le 17 févr. 2010 à 16:09, Steven Degutis a écrit :
>
> > Check out NSPopUpButton's NSPopUpButtonWillPopUpNotification
> >
> > On Wed, Feb 17, 2010 at 2:49 AM, Peter N Lewis >
any way to dynamically populate a popup menu on the fly (as it is
>> exposed)?
>>
>> For example, a popup menu that displayed the harddisk hierarchy would need
>> this sort of thing - you wouldn't want the entire thing populated as soon as
>> you click the popu
Check out NSPopUpButton's NSPopUpButtonWillPopUpNotification
On Wed, Feb 17, 2010 at 2:49 AM, Peter N Lewis wrote:
> Is there any way to dynamically populate a popup menu on the fly (as it is
> exposed)?
>
> For example, a popup menu that displayed the harddisk hierarchy would
On 17/02/2010, at 6:49 PM, Peter N Lewis wrote:
> Is there any way to dynamically populate a popup menu on the fly (as it is
> exposed)?
Look into the NSMenuDelegate protocol. It has methods to do what you want.
--Graham___
Cocoa-dev mailin
Is there any way to dynamically populate a popup menu on the fly (as it is
exposed)?
For example, a popup menu that displayed the harddisk hierarchy would need this
sort of thing - you wouldn't want the entire thing populated as soon as you
click the popup menu, it would take forever an