cocoa: fix problem with dispatching key-up events

Closes PR 11635
 Merge to 5.1
This commit is contained in:
Matthew Flatt 2011-01-31 12:39:57 -07:00
parent f7fd6ee689
commit 152c636e1c

View File

@ -58,7 +58,12 @@
(and r
(begin
(parameterize ([recurring-for-command #t])
(tell r keyDown: evt))
(let ([evt-type (tell #:type _NSInteger evt type)])
(cond
[(= NSKeyDown evt-type)
(tell r keyDown: evt)]
[(= NSKeyUp evt-type)
(tell r keyUp: evt)])))
#t)))))))))
(define cocoa-mb (tell (tell MyBarMenu alloc) init))