cocoa: explicitly re-dispatch Cmd- key combinations
original commit: 72d57d8db86b53adadef214fef051a78f9965bf5
This commit is contained in:
parent
467341591e
commit
06ab79f133
|
@ -41,8 +41,16 @@
|
|||
;; Disable automatic handling of keyboard shortcuts, except for
|
||||
;; the Apple menu
|
||||
(-a _BOOL (performKeyEquivalent: [_id evt])
|
||||
(and the-apple-menu
|
||||
(tell #:type _BOOL the-apple-menu performKeyEquivalent: evt))))
|
||||
(or (and the-apple-menu
|
||||
(tell #:type _BOOL the-apple-menu performKeyEquivalent: evt))
|
||||
;; Explicity send the event to the keyWindow:
|
||||
(let ([w (tell app keyWindow)])
|
||||
(and w
|
||||
(let ([r (tell w firstResponder)])
|
||||
(and r
|
||||
(begin
|
||||
(tell r keyDown: evt)
|
||||
#t))))))))
|
||||
|
||||
(define cocoa-mb (tell (tell MyBarMenu alloc) init))
|
||||
(define current-mb #f)
|
||||
|
|
Loading…
Reference in New Issue
Block a user