• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
NSPopUpButton Display Last Selected
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSPopUpButton Display Last Selected


  • Subject: NSPopUpButton Display Last Selected
  • From: Richard Somers <email@hidden>
  • Date: Tue, 13 Jul 2010 13:00:42 -0600

I have a programmatic NSPopUpButton used by a toolbar item. The pop-up list does not display the option that was last selected.

The documentation says "A pop-up list lets the user choose one option among several and generally displays the option that was last selected."

How do I make the button automatically display the last selection?

     NSPopUpButton *button = [[NSPopUpButton alloc]
         initWithFrame:NSMakeRect(0.0, 0.0, 60.0, 22.0) pullsDown:NO];
     [button addItemWithTitle:@"1"];
     [button addItemWithTitle:@"2"];

--Richard

_______________________________________________

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


  • Follow-Ups:
    • Re: NSPopUpButton Display Last Selected
      • From: Richard Somers <email@hidden>
  • Prev by Date: Re: NSTextView becomes temporarily unresponsive
  • Next by Date: Re: Testing background task expiration; lowering backgroundTimeRemaining?
  • Previous by thread: find out all domains in network
  • Next by thread: Re: NSPopUpButton Display Last Selected
  • Index(es):
    • Date
    • Thread