• 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
Re: Get NSPopUpButton from NSMenuItem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Get NSPopUpButton from NSMenuItem


  • Subject: Re: Get NSPopUpButton from NSMenuItem
  • From: Quincey Morris <email@hidden>
  • Date: Thu, 09 Jun 2011 12:40:48 -0700

On Jun 9, 2011, at 11:43, Siegfried wrote:

> Does anyone know if there is a way to get a pointer for the NSPopUpButton containing a NSMenu containing a NSMenuItem, which is the IBAction sender?
>
> I have multiple similar popups, and all of them have a "Custom…" menu item, designated to hiding the popup and bringing more controls to the user. It would be nice to avoid extra methods for each item.
>
> I could not find a clue in the docs, so any help is really appreciated.

If the "Custom" item is just one of the popup's items (that is, there's no submenu involved) then IIRC the popup button will be the sender, not the menu item.

Or is there a submenu involved here (which would be a NSPopUpButton containing a NSMenuItem containing a NSMenu containing a NSMenuItem, which is not exactly what you said)?


_______________________________________________

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: Get NSPopUpButton from NSMenuItem
      • From: Siegfried <email@hidden>
References: 
 >Get NSPopUpButton from NSMenuItem (From: Siegfried <email@hidden>)

  • Prev by Date: Get NSPopUpButton from NSMenuItem
  • Next by Date: Re: Get NSPopUpButton from NSMenuItem
  • Previous by thread: Get NSPopUpButton from NSMenuItem
  • Next by thread: Re: Get NSPopUpButton from NSMenuItem
  • Index(es):
    • Date
    • Thread