original commit: 51e2379471994c2804c7921b21a7f3c659a5f014
This commit is contained in:
Matthew Flatt 2002-12-18 00:36:18 +00:00
parent 84b674e553
commit 8a61eecf38

View File

@ -5371,17 +5371,22 @@
(lambda () (lambda ()
(set! wx (make-object wx-menu% this title (set! wx (make-object wx-menu% this title
(lambda (mwx e) (lambda (mwx e)
(let ([wx (wx:id-to-menu-item (send e get-menu-id))]) (let ([go
(when wx (lambda ()
(send (wx->mred wx) command (make-object wx:control-event% 'menu))) (let ([wx (wx:id-to-menu-item (send e get-menu-id))])
(dynamic-wind (when wx
void (send (wx->mred wx) command (make-object wx:control-event% 'menu)))
(lambda () (dynamic-wind
(popdown-callback this (make-object wx:control-event% void
(if wx (lambda ()
'menu-popdown (popdown-callback this (make-object wx:control-event%
(if wx
'menu-popdown
'menu-popdown-none)))) 'menu-popdown-none))))
(lambda () (send mwx popup-release))))))) (lambda () (send mwx popup-release)))))])
(if (eq? 'windows (system-type))
(wx:queue-callback go wx:middle-queue-key)
(go))))))
(super-init wx)))))) (super-init wx))))))
(define menu-bar% (define menu-bar%