• 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: How to get key code from "SysDefined" Carbon Event
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to get key code from "SysDefined" Carbon Event


  • Subject: Re: How to get key code from "SysDefined" Carbon Event
  • From: James Walker <email@hidden>
  • Date: Tue, 18 Oct 2011 13:22:26 -0700

On 10/18/2011 1:00 PM, Jerry Krinock wrote:
I've registered a handler for global hot keys with the Carbon Event
Manager, using InstallEventHandler().  However, I'd like the user to
be able to specify *two* different global hot key functions.  Thus,
in my callback/handler, I need the key code and modifier flags of the
event, to determine which function they want.

The only documented parameter in the kEventClassKeyboard / kEventHotKeyPressed Carbon Event is


  kEventParamDirectObject (in, typeEventHotKeyID)
	The ID of the hot key that was pressed.

That's the ID that was passed to RegisterEventHotKey. That's what you should use to distinguish different hot keys.
--
James W. Walker, Innoventive Software LLC
<http://www.frameforge3d.com/>
_______________________________________________


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: How to get key code from "SysDefined" Carbon Event
      • From: Jerry Krinock <email@hidden>
References: 
 >How to get key code from "SysDefined" Carbon Event (From: Jerry Krinock <email@hidden>)

  • Prev by Date: Re: Launching 10.5 app on 10.4
  • Next by Date: Re: Blocks vs. life, the universe and everything
  • Previous by thread: How to get key code from "SysDefined" Carbon Event
  • Next by thread: Re: How to get key code from "SysDefined" Carbon Event
  • Index(es):
    • Date
    • Thread