|
|
RegisterEventHotKey
|
|
|
|
Admin Emeritus
Join Date: Oct 2000
Location: Boston, MA
Status:
Offline
|
|
Can someone give sample parameter values for RegisterEventHotKey()?
I'm trying to use hotkeys in my cocoa app (running a carbon loop in another thread) but I'm getting paramErrs for this call. Help!
|
"Against stupidity, the gods themselves contend in vain" (Schiller)
|
|
|
|
|
|
|
|
Addicted to MacNN
Join Date: Mar 2000
Location: London, UK
Status:
Offline
|
|
I don't think you can from Cocoa... I'm pretty sure someone said you can't, but I haven't tried it myself.
|
|
|
|
|
|
|
|
|
Admin Emeritus
Join Date: Oct 2000
Location: Boston, MA
Status:
Offline
|
|
Well, I tried it, and it seemed to work to some degree, but I don't know how to capture the hotkey event. When I put in some bad pointers and type in the hotkey the program crashes (so I assume its receiving the hotkey), but I'm not sure which EventTypeSpec to use to capture it properly.
|
"Against stupidity, the gods themselves contend in vain" (Schiller)
|
|
|
|
|
|
|
|
Admin Emeritus
Join Date: Oct 2000
Location: Boston, MA
Status:
Offline
|
|
lol, nevermind. kEventHotKeyPressed, Heh, that helps.
Anyway, for those of you that want to use HotKeys in Cocoa, it is possible using Carbon Events (setting up a Carbon event loop). I'll release the code in some wrapper so you all can use it easily.
|
"Against stupidity, the gods themselves contend in vain" (Schiller)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Forum Rules
|
|
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is Off
|
|
|
|
|
|
|
|
|
|
|
|