Skip navigation.
 
mlRe: catching command-enter keyDown events in a table view
FROM : Harilaos Skiadas
DATE : Thu Nov 04 19:41:25 2004

Hi Ben,

  I think what you need is NSEvent's modifierFlags:
method. In particular, comparing it to
NSCommandKeyMask. The documentation on NSEvent has all
this info and more:
http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/ObjC_classic/Classes/NSEvent.html#//apple_ref/doc/uid/20000016/BBCGEBIG

I hope this helps, haven't tried it myself. In my app,
I only cared about catching arrow up and arrow down
presses.
Haris

>Hi all,
>
>I got stuck while I was trying to catch command-enter

keyDown >events in
>my NSTableView.
>I subclassed NSTableView and added keyDown: and

insertNewLine: >and i
>can now successfully work with my code after an enter

was pressed >on my
>tableview, but how can I check if the command (apple)

or any other
>modifier key for that matter was pressed at the same

time?
>
>Thanks,
>
>Ben



       
__________________________________
Do you Yahoo!?
Check out the new Yahoo! Front Page.
www.yahoo.com

Related mailsAuthorDate
mlcatching command-enter keyDown events in a table view Salánki Benjámin Nov 4, 13:23
mlRe: catching command-enter keyDown events in a table view Todd Ransom Nov 4, 16:46
mlRe: catching command-enter keyDown events in a table view August Trometer Nov 4, 17:40
mlRe: catching command-enter keyDown events in a table view Will Mason Nov 4, 18:21
mlRe: catching command-enter keyDown events in a table view Todd Ransom Nov 4, 19:16
mlRe: catching command-enter keyDown events in a table view Harilaos Skiadas Nov 4, 19:41