• 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: menu item status
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: menu item status


  • Subject: Re: menu item status
  • From: gweston <email@hidden>
  • Date: Wed, 07 Sep 2011 07:07:13 +0000 (GMT)

I am trying to determine the state of a menu item in another application. I have tried via AppleScript UI scripting, and via AppleScript Studio's state of menu item. I am coming up empty. I can get to the menu and select the item fine - but I can't get the status. I am interested whether or not the menu item has a check mark next to it.

I know this can be done programmatically, because QuicKeys knows about the status.

I'd be grateful for any hints as to how to solve this problem.

Frankly, I don't think there *is* a reliable way to solve this problem regardless of the luck QuickKeys might exhibit. Why? Because I can't see any reason to assume the checked/unchecked state of a given menu item will be valid while the menu containing it is not displayed.

Without knowing the details of what program you're trying to interact with any why, my first inclination would be too look not for a way to tell if the menu item is checked but to query the state of the underlying setting or object that menu item represents.

Greg

_______________________________________________

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


  • Prev by Date: Re: menu item status
  • Next by Date: Re: UINavigationBar Look and feel
  • Previous by thread: Re: menu item status
  • Next by thread: Open NSPanel with button click in PDE
  • Index(es):
    • Date
    • Thread