diff --git a/patches/user32-rawinput-mouse/0004-server-Add-send_hardware_message-flags-for-rawinput-.patch b/patches/user32-rawinput-mouse/0004-server-Add-send_hardware_message-flags-for-rawinput-.patch index b6858cb3..5873bb4f 100644 --- a/patches/user32-rawinput-mouse/0004-server-Add-send_hardware_message-flags-for-rawinput-.patch +++ b/patches/user32-rawinput-mouse/0004-server-Add-send_hardware_message-flags-for-rawinput-.patch @@ -1,4 +1,4 @@ -From b08aae4c2d967c0c66f4349584d2e33de353b5ad Mon Sep 17 00:00:00 2001 +From 84025e765979320128422a50d5f892e8f501b2df Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Bernon?= Date: Mon, 26 Aug 2019 14:37:20 +0200 Subject: [PATCH] server: Add send_hardware_message flags for rawinput @@ -11,10 +11,10 @@ Subject: [PATCH] server: Add send_hardware_message flags for rawinput 3 files changed, 15 insertions(+), 8 deletions(-) diff --git a/include/ntuser.h b/include/ntuser.h -index f947fec7fea..4ded432bd99 100644 +index ff45ffa2bc8..bc51f04af6e 100644 --- a/include/ntuser.h +++ b/include/ntuser.h -@@ -1423,6 +1423,10 @@ struct hid_packet +@@ -1440,6 +1440,10 @@ struct hid_packet C_ASSERT(sizeof(struct hid_packet) == offsetof(struct hid_packet, data[0])); @@ -26,7 +26,7 @@ index f947fec7fea..4ded432bd99 100644 { UINT flags; diff --git a/server/protocol.def b/server/protocol.def -index 054d47eb81f..d847f046eeb 100644 +index 1fdedd161ff..4d199a6407c 100644 --- a/server/protocol.def +++ b/server/protocol.def @@ -2164,7 +2164,7 @@ enum message_type @@ -47,10 +47,10 @@ index 054d47eb81f..d847f046eeb 100644 /* Get a message from the current queue */ diff --git a/server/queue.c b/server/queue.c -index 938e3e310e5..eb3a2b0326e 100644 +index ac863fd439b..c38d91ba28c 100644 --- a/server/queue.c +++ b/server/queue.c -@@ -2027,7 +2027,7 @@ static void dispatch_rawinput_message( struct desktop *desktop, struct rawinput_ +@@ -2019,7 +2019,7 @@ static void dispatch_rawinput_message( struct desktop *desktop, struct rawinput_ /* queue a hardware message for a mouse event */ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, const hw_input_t *input, @@ -59,7 +59,7 @@ index 938e3e310e5..eb3a2b0326e 100644 { const struct rawinput_device *device; struct hardware_msg_data *msg_data; -@@ -2082,7 +2082,7 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons +@@ -2075,7 +2075,7 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons y = desktop->cursor.y; } @@ -68,7 +68,7 @@ index 938e3e310e5..eb3a2b0326e 100644 { memset( &raw_msg, 0, sizeof(raw_msg) ); raw_msg.foreground = foreground; -@@ -2104,6 +2104,8 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons +@@ -2097,6 +2097,8 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons return 0; } @@ -77,7 +77,7 @@ index 938e3e310e5..eb3a2b0326e 100644 for (i = 0; i < ARRAY_SIZE( messages ); i++) { if (!messages[i]) continue; -@@ -2135,7 +2137,7 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons +@@ -2128,7 +2130,7 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons /* queue a hardware message for a keyboard event */ static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, const hw_input_t *input, @@ -86,16 +86,16 @@ index 938e3e310e5..eb3a2b0326e 100644 { struct hw_msg_source source = { IMDT_KEYBOARD, origin }; const struct rawinput_device *device; -@@ -2234,7 +2236,7 @@ static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, c +@@ -2232,7 +2234,7 @@ static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, c } } -- if ((foreground = get_foreground_thread( desktop, win ))) -+ if (!(send_flags & SEND_HWMSG_NO_RAW) && (foreground = get_foreground_thread( desktop, win ))) +- if (!unicode && (foreground = get_foreground_thread( desktop, win ))) ++ if (!(send_flags & SEND_HWMSG_NO_RAW) && ((!unicode && (foreground = get_foreground_thread( desktop, win ))))) { struct rawinput_message raw_msg = {0}; raw_msg.foreground = foreground; -@@ -2255,6 +2257,8 @@ static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, c +@@ -2253,6 +2255,8 @@ static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, c return 0; } @@ -104,7 +104,7 @@ index 938e3e310e5..eb3a2b0326e 100644 if (!(msg = alloc_hardware_message( input->kbd.info, source, time, 0 ))) return 0; msg_data = msg->data; -@@ -3010,10 +3014,10 @@ DECL_HANDLER(send_hardware_message) +@@ -3004,10 +3008,10 @@ DECL_HANDLER(send_hardware_message) switch (req->input.type) { case INPUT_MOUSE: diff --git a/staging/upstream-commit b/staging/upstream-commit index 56bd3786..50b8fef7 100644 --- a/staging/upstream-commit +++ b/staging/upstream-commit @@ -1 +1 @@ -b6eada5e2f9e3c86c18df118cddd20e6212f64de +951e0e27a743e52c75c7fedc0b1eaa9eb77e6bb6