From 2b7d3981c024645dbba7da65b16bfd7e4b94efd4 Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Thu, 9 Dec 2010 15:18:39 -0700 Subject: [PATCH] win32: fix alt-combination handling original commit: 518cff7b6362be675d506dc90175fe5be455e7e0 --- collects/mred/private/wx/win32/window.rkt | 28 +++++++++++++---------- 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/collects/mred/private/wx/win32/window.rkt b/collects/mred/private/wx/win32/window.rkt index 5abf242e..061e3357 100644 --- a/collects/mred/private/wx/win32/window.rkt +++ b/collects/mred/private/wx/win32/window.rkt @@ -150,22 +150,26 @@ [(= msg WM_KILLFOCUS) (queue-window-event this (lambda () (on-kill-focus))) 0] - [(and (= msg WM_SYSKEYDOWN) - (or (= wParam VK_MENU) (= wParam VK_F4))) ;; F4 is close - (unhide-cursor) - (begin0 - (default w msg wParam lParam) - (do-key w msg wParam lParam #f #f void))] + [(= msg WM_SYSKEYDOWN) + (let ([result (if (or (= wParam VK_MENU) (= wParam VK_F4)) ;; F4 is close + (begin + (unhide-cursor) + (default w msg wParam lParam)) + 0)]) + (do-key w msg wParam lParam #f #f void) + result)] [(= msg WM_KEYDOWN) (do-key w msg wParam lParam #f #f default)] [(= msg WM_KEYUP) (do-key w msg wParam lParam #f #t default)] - [(and (= msg WM_SYSCHAR) - (= wParam VK_MENU)) - (unhide-cursor) - (begin0 - (default w msg wParam lParam) - (do-key w msg wParam lParam #t #f void))] + [(= msg WM_SYSCHAR) + (let ([result (if (= wParam VK_MENU) + (begin + (unhide-cursor) + (default w msg wParam lParam)) + 0)]) + (do-key w msg wParam lParam #t #f void) + result)] [(= msg WM_CHAR) (do-key w msg wParam lParam #t #f default)] [(= msg WM_COMMAND)