Ziqing Hui : server: Also queue hotkey message for WM_SYSKEYDOWN.

Alexandre Julliard julliard at winehq.org
Tue Nov 2 17:27:44 CDT 2021


Module: wine
Branch: master
Commit: 77f1658393b46fd29b998876129b2c4851ac6619
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=77f1658393b46fd29b998876129b2c4851ac6619

Author: Ziqing Hui <zhui at codeweavers.com>
Date:   Tue Nov  2 10:54:22 2021 +0800

server: Also queue hotkey message for WM_SYSKEYDOWN.

ALT and F10 key generate WM_SYSKEYDOWN message.
They should also have the ability to queue hotkey message.

Signed-off-by: Ziqing Hui <zhui at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/user32/tests/msg.c | 2 +-
 server/queue.c          | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/user32/tests/msg.c b/dlls/user32/tests/msg.c
index 73737eab98b..c054a145112 100644
--- a/dlls/user32/tests/msg.c
+++ b/dlls/user32/tests/msg.c
@@ -17699,7 +17699,7 @@ static void test_hotkey(void)
         }
         DispatchMessageA(&msg);
     }
-    ok_sequence(WmHotkeyPressWithALT, "window hotkey press with ALT", TRUE);
+    ok_sequence(WmHotkeyPressWithALT, "window hotkey press with ALT", FALSE);
 
     keybd_event(hotkey_letter, 0, KEYEVENTF_KEYUP, 0);
     while (PeekMessageA(&msg, NULL, 0, 0, PM_REMOVE))
diff --git a/server/queue.c b/server/queue.c
index 63a3a1fe2db..f7bc28f39e9 100644
--- a/server/queue.c
+++ b/server/queue.c
@@ -1422,7 +1422,7 @@ static int queue_hotkey_message( struct desktop *desktop, struct message *msg )
     struct hotkey *hotkey;
     unsigned int modifiers = 0;
 
-    if (msg->msg != WM_KEYDOWN) return 0;
+    if (msg->msg != WM_KEYDOWN && msg->msg != WM_SYSKEYDOWN) return 0;
 
     if (desktop->keystate[VK_MENU] & 0x80) modifiers |= MOD_ALT;
     if (desktop->keystate[VK_CONTROL] & 0x80) modifiers |= MOD_CONTROL;




More information about the wine-cvs mailing list