Updated user32-rawinput patchset

This commit is contained in:
Alistair Leslie-Hughes 2019-09-29 18:06:18 +10:00
parent 9fe5cabf21
commit 0c7512f5f5
11 changed files with 66 additions and 66 deletions

View File

@ -1,4 +1,4 @@
From 5b72eb081757521ee2f86aad97c36ed751733b1d Mon Sep 17 00:00:00 2001
From c91add917b374a1dd98f07d4d3647295d4fd7f20 Mon Sep 17 00:00:00 2001
From: Derek Lesho <dereklesho52@Gmail.com>
Date: Tue, 25 Jun 2019 16:23:02 -0400
Subject: [PATCH 01/11] user32: Add support for RIDEV_NOLEGACY flag.
@ -10,10 +10,10 @@ Signed-off-by: Derek Lesho <dereklesho52@Gmail.com>
2 files changed, 10 insertions(+), 1 deletion(-)
diff --git a/dlls/user32/rawinput.c b/dlls/user32/rawinput.c
index 49cf9f73a0..58480b8ae7 100644
index 94cf7a9a5d..661a0e3b25 100644
--- a/dlls/user32/rawinput.c
+++ b/dlls/user32/rawinput.c
@@ -271,7 +271,7 @@ BOOL WINAPI DECLSPEC_HOTPATCH RegisterRawInputDevices(RAWINPUTDEVICE *devices, U
@@ -282,7 +282,7 @@ BOOL WINAPI DECLSPEC_HOTPATCH RegisterRawInputDevices(RAWINPUTDEVICE *devices, U
TRACE("device %u: page %#x, usage %#x, flags %#x, target %p.\n",
i, devices[i].usUsagePage, devices[i].usUsage,
devices[i].dwFlags, devices[i].hwndTarget);
@ -23,7 +23,7 @@ index 49cf9f73a0..58480b8ae7 100644
d[i].usage_page = devices[i].usUsagePage;
diff --git a/server/queue.c b/server/queue.c
index 96587d11d1..40a566a2b7 100644
index b5e17be18f..7c3c7e5148 100644
--- a/server/queue.c
+++ b/server/queue.c
@@ -372,6 +372,9 @@ static void set_cursor_pos( struct desktop *desktop, int x, int y )

View File

@ -1,4 +1,4 @@
From 8cd2c66e39dee6edb4dda9faef5601785a8eb9eb Mon Sep 17 00:00:00 2001
From 107e1c0afb7e4a6639726891df26a724ffda5f1e Mon Sep 17 00:00:00 2001
From: Derek Lesho <dereklesho52@Gmail.com>
Date: Tue, 25 Jun 2019 20:47:20 -0400
Subject: [PATCH 02/11] server: Move mouse raw-input message faking from user32
@ -12,7 +12,7 @@ Signed-off-by: Derek Lesho <dereklesho52@Gmail.com>
3 files changed, 52 insertions(+), 49 deletions(-)
diff --git a/dlls/user32/message.c b/dlls/user32/message.c
index 43ce77c2dd..b6dd7d5932 100644
index 1336865112..cf0fbe2f0c 100644
--- a/dlls/user32/message.c
+++ b/dlls/user32/message.c
@@ -2295,54 +2295,14 @@ static BOOL process_rawinput_message( MSG *msg, const struct hardware_msg_data *
@ -74,7 +74,7 @@ index 43ce77c2dd..b6dd7d5932 100644
rawinput->data.mouse.ulRawButtons = 0;
rawinput->data.mouse.lLastX = msg_data->rawinput.mouse.x;
diff --git a/server/protocol.def b/server/protocol.def
index 8157199f2f..f7e0008b04 100644
index 6af0ae0cff..7346e6aa44 100644
--- a/server/protocol.def
+++ b/server/protocol.def
@@ -304,10 +304,11 @@ struct hardware_msg_data
@ -94,7 +94,7 @@ index 8157199f2f..f7e0008b04 100644
} rawinput;
};
diff --git a/server/queue.c b/server/queue.c
index 40a566a2b7..b58dfd5213 100644
index 7c3c7e5148..a85bb15227 100644
--- a/server/queue.c
+++ b/server/queue.c
@@ -1627,6 +1627,16 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons

View File

@ -1,4 +1,4 @@
From 2fd717d14d73b529d09aa786346cc2d205f29137 Mon Sep 17 00:00:00 2001
From 3757f19f58dcbf11648d602212f412d29dc37750 Mon Sep 17 00:00:00 2001
From: Derek Lesho <dereklesho52@Gmail.com>
Date: Tue, 25 Jun 2019 21:24:12 -0400
Subject: [PATCH 03/11] server: Add request for sending native raw-input
@ -14,7 +14,7 @@ Signed-off-by: Derek Lesho <dereklesho52@Gmail.com>
5 files changed, 104 insertions(+), 20 deletions(-)
diff --git a/dlls/user32/message.c b/dlls/user32/message.c
index b6dd7d5932..4c8d485954 100644
index cf0fbe2f0c..98d2c1d2c2 100644
--- a/dlls/user32/message.c
+++ b/dlls/user32/message.c
@@ -2299,7 +2299,7 @@ static BOOL process_rawinput_message( MSG *msg, const struct hardware_msg_data *
@ -27,7 +27,7 @@ index b6dd7d5932..4c8d485954 100644
rawinput->data.mouse.u.s.usButtonFlags = msg_data->rawinput.mouse.button_flags;
rawinput->data.mouse.u.s.usButtonData = msg_data->rawinput.mouse.button_data;
diff --git a/server/protocol.def b/server/protocol.def
index f7e0008b04..009e0b2593 100644
index 7346e6aa44..451c9253ee 100644
--- a/server/protocol.def
+++ b/server/protocol.def
@@ -286,31 +286,39 @@ struct hw_msg_source
@ -102,7 +102,7 @@ index f7e0008b04..009e0b2593 100644
@REQ(get_message)
unsigned int flags; /* PM_* flags */
diff --git a/server/queue.c b/server/queue.c
index b58dfd5213..246fcffd23 100644
index a85bb15227..f9787933f2 100644
--- a/server/queue.c
+++ b/server/queue.c
@@ -2421,6 +2421,55 @@ DECL_HANDLER(send_hardware_message)
@ -162,7 +162,7 @@ index b58dfd5213..246fcffd23 100644
DECL_HANDLER(post_quit_message)
{
diff --git a/server/trace.c b/server/trace.c
index 0df649ea29..4fbfee88c8 100644
index 615542cff5..c936c7e57a 100644
--- a/server/trace.c
+++ b/server/trace.c
@@ -405,6 +405,27 @@ static void dump_hw_input( const char *prefix, const hw_input_t *input )

View File

@ -1,4 +1,4 @@
From 1f278c6a5f906910c08e6e122850c7df00f30b7a Mon Sep 17 00:00:00 2001
From 8e384f61c8d864ee95892f250cd0f384ac98d587 Mon Sep 17 00:00:00 2001
From: Derek Lesho <dereklesho52@Gmail.com>
Date: Tue, 25 Jun 2019 21:28:54 -0400
Subject: [PATCH 04/11] user32: Add helper for input drivers to submit native

View File

@ -1,4 +1,4 @@
From d7343cb3d9c68873003bbf92315dad23808221c4 Mon Sep 17 00:00:00 2001
From 45b1aba399b89c20e93bc358dfba261e40fcf30b Mon Sep 17 00:00:00 2001
From: Derek Lesho <dereklesho52@Gmail.com>
Date: Tue, 25 Jun 2019 21:58:34 -0400
Subject: [PATCH 05/11] server: Don't emulate rawinput mouse events if native
@ -10,7 +10,7 @@ Signed-off-by: Derek Lesho <dereklesho52@Gmail.com>
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/server/queue.c b/server/queue.c
index 246fcffd23..c9446f7f4b 100644
index f9787933f2..060e73b819 100644
--- a/server/queue.c
+++ b/server/queue.c
@@ -1599,6 +1599,8 @@ static int send_hook_ll_message( struct desktop *desktop, struct message *hardwa

View File

@ -1,4 +1,4 @@
From 7bc3e25b06e580c82ca1289f1758a980cfd51543 Mon Sep 17 00:00:00 2001
From 73d2f9ea82a3897f7ba3f979b599ba0273d8f39d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
Date: Tue, 23 Jul 2019 14:10:44 +0200
Subject: [PATCH 06/11] winex11.drv: Directly listen to master XInput2 devices
@ -21,10 +21,10 @@ Signed-off-by: Derek Lesho <dereklesho52@Gmail.com>
2 files changed, 42 insertions(+), 56 deletions(-)
diff --git a/dlls/winex11.drv/event.c b/dlls/winex11.drv/event.c
index 5c465aa033..1e64f0d2a3 100644
index 25730192d3..e31e2cc0c5 100644
--- a/dlls/winex11.drv/event.c
+++ b/dlls/winex11.drv/event.c
@@ -271,46 +271,6 @@ enum event_merge_action
@@ -274,46 +274,6 @@ enum event_merge_action
MERGE_IGNORE /* ignore the new event, keep the old one */
};
@ -71,7 +71,7 @@ index 5c465aa033..1e64f0d2a3 100644
/***********************************************************************
* merge_events
*
@@ -362,7 +322,7 @@ static enum event_merge_action merge_events( XEvent *prev, XEvent *next )
@@ -365,7 +325,7 @@ static enum event_merge_action merge_events( XEvent *prev, XEvent *next )
if (next->xcookie.extension != xinput2_opcode) break;
if (next->xcookie.evtype != XI_RawMotion) break;
if (x11drv_thread_data()->warp_serial) break;
@ -81,10 +81,10 @@ index 5c465aa033..1e64f0d2a3 100644
}
break;
diff --git a/dlls/winex11.drv/mouse.c b/dlls/winex11.drv/mouse.c
index f737a306a5..90fd11831b 100644
index 15e5c04a41..23c7c6fb35 100644
--- a/dlls/winex11.drv/mouse.c
+++ b/dlls/winex11.drv/mouse.c
@@ -130,6 +130,8 @@ static Cursor create_cursor( HANDLE handle );
@@ -133,6 +133,8 @@ static Cursor create_cursor( HANDLE handle );
#ifdef HAVE_X11_EXTENSIONS_XINPUT2_H
static BOOL xinput2_available;
@ -93,7 +93,7 @@ index f737a306a5..90fd11831b 100644
static BOOL broken_rawevents;
#define MAKE_FUNCPTR(f) static typeof(f) * p##f
MAKE_FUNCPTR(XIGetClientPointer);
@@ -301,8 +303,11 @@ static void enable_xinput2(void)
@@ -304,8 +306,11 @@ static void enable_xinput2(void)
if (data->xi2_state == xi_unknown)
{
@ -107,7 +107,7 @@ index f737a306a5..90fd11831b 100644
else
{
data->xi2_state = xi_unavailable;
@@ -314,11 +319,19 @@ static void enable_xinput2(void)
@@ -317,11 +322,19 @@ static void enable_xinput2(void)
mask.mask = mask_bits;
mask.mask_len = sizeof(mask_bits);
@ -129,7 +129,7 @@ index f737a306a5..90fd11831b 100644
pXISelectEvents( data->display, DefaultRootWindow( data->display ), &mask, 1 );
@@ -333,7 +346,7 @@ static void enable_xinput2(void)
@@ -336,7 +349,7 @@ static void enable_xinput2(void)
* safe to be obtained statically at enable_xinput2() time.
*/
if (data->xi2_devices) pXIFreeDeviceInfo( data->xi2_devices );
@ -138,7 +138,7 @@ index f737a306a5..90fd11831b 100644
data->xi2_current_slave = 0;
data->xi2_state = xi_enabled;
@@ -356,7 +369,13 @@ static void disable_xinput2(void)
@@ -359,7 +372,13 @@ static void disable_xinput2(void)
mask.mask = NULL;
mask.mask_len = 0;
@ -153,7 +153,7 @@ index f737a306a5..90fd11831b 100644
pXISelectEvents( data->display, DefaultRootWindow( data->display ), &mask, 1 );
pXIFreeDeviceInfo( data->xi2_devices );
@@ -1735,25 +1754,32 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
@@ -1793,25 +1812,32 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
if (!event->valuators.mask_len) return FALSE;
if (thread_data->xi2_state != xi_enabled) return FALSE;

View File

@ -1,8 +1,8 @@
From 5ce9048468f363c5f844a35327aecc40d8304c9b Mon Sep 17 00:00:00 2001
From c91c52063e8c06bc8e8788309ecb7dca70bc6b9a Mon Sep 17 00:00:00 2001
From: Derek Lesho <dereklesho52@Gmail.com>
Date: Tue, 25 Jun 2019 22:37:34 -0400
Subject: [PATCH] winex11.drv: Implement native mouse-movement raw-input using
RawMotion.
Subject: [PATCH 07/11] winex11.drv: Implement native mouse-movement raw-input
using RawMotion.
Signed-off-by: Derek Lesho <dereklesho52@Gmail.com>
---
@ -12,7 +12,7 @@ Signed-off-by: Derek Lesho <dereklesho52@Gmail.com>
3 files changed, 97 insertions(+), 19 deletions(-)
diff --git a/dlls/winex11.drv/mouse.c b/dlls/winex11.drv/mouse.c
index 23c7c6fb35b..212511fde84 100644
index 23c7c6fb35..212511fde8 100644
--- a/dlls/winex11.drv/mouse.c
+++ b/dlls/winex11.drv/mouse.c
@@ -262,6 +262,8 @@ static void update_relative_valuators(XIAnyClassInfo **valuators, int n_valuator
@ -244,7 +244,7 @@ index 23c7c6fb35b..212511fde84 100644
}
diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h
index b8cfda43410..d79c78ecbc9 100644
index 135faa8989..e9d9514ee2 100644
--- a/dlls/winex11.drv/x11drv.h
+++ b/dlls/winex11.drv/x11drv.h
@@ -194,6 +194,8 @@ extern BOOL CDECL X11DRV_UnrealizePalette( HPALETTE hpal ) DECLSPEC_HIDDEN;
@ -256,7 +256,7 @@ index b8cfda43410..d79c78ecbc9 100644
extern DWORD copy_image_bits( BITMAPINFO *info, BOOL is_r8g8b8, XImage *image,
const struct gdi_image_bits *src_bits, struct gdi_image_bits *dst_bits,
@@ -336,11 +338,13 @@ struct x11drv_thread_data
@@ -335,11 +337,13 @@ struct x11drv_thread_data
HWND clip_hwnd; /* message window stored in desktop while clipping is active */
DWORD clip_reset; /* time when clipping was last reset */
HKL kbd_layout; /* active keyboard layout */
@ -271,7 +271,7 @@ index b8cfda43410..d79c78ecbc9 100644
int xi2_core_pointer; /* XInput2 core pointer id */
int xi2_current_slave; /* Current slave driving the Core pointer */
};
@@ -427,6 +431,8 @@ enum x11drv_atoms
@@ -426,6 +430,8 @@ enum x11drv_atoms
XATOM_RAW_CAP_HEIGHT,
XATOM_Rel_X,
XATOM_Rel_Y,
@ -281,7 +281,7 @@ index b8cfda43410..d79c78ecbc9 100644
XATOM_WM_DELETE_WINDOW,
XATOM_WM_STATE,
diff --git a/dlls/winex11.drv/x11drv_main.c b/dlls/winex11.drv/x11drv_main.c
index 54de5d8a6b0..9f896bddd9a 100644
index 21807af3f1..fb25a45ae2 100644
--- a/dlls/winex11.drv/x11drv_main.c
+++ b/dlls/winex11.drv/x11drv_main.c
@@ -120,6 +120,8 @@ static const char * const atom_names[NB_XATOMS - FIRST_XATOM] =
@ -302,7 +302,7 @@ index 54de5d8a6b0..9f896bddd9a 100644
if (data->xim) XCloseIM( data->xim );
if (data->font_set) XFreeFontSet( data->display, data->font_set );
XCloseDisplay( data->display );
@@ -684,6 +688,8 @@ struct x11drv_thread_data *x11drv_init_thread_data(void)
@@ -681,6 +685,8 @@ struct x11drv_thread_data *x11drv_init_thread_data(void)
if (use_xim) X11DRV_SetupXIM();

View File

@ -1,4 +1,4 @@
From 8cd3d08315b108d2736356318c6ef74d3a0b1ec8 Mon Sep 17 00:00:00 2001
From f55c05132e87dd3e9436c68920ad512bdcfb8df8 Mon Sep 17 00:00:00 2001
From: Derek Lesho <dereklesho52@Gmail.com>
Date: Fri, 26 Jul 2019 17:37:19 -0400
Subject: [PATCH 08/11] winex11.drv: Implement native mouse-button raw-input
@ -12,10 +12,10 @@ Signed-off-by: Derek Lesho <dereklesho52@Gmail.com>
3 files changed, 95 insertions(+), 6 deletions(-)
diff --git a/dlls/winex11.drv/mouse.c b/dlls/winex11.drv/mouse.c
index 472ba77d0a..65b1b500d0 100644
index 212511fde8..1d9833b5c9 100644
--- a/dlls/winex11.drv/mouse.c
+++ b/dlls/winex11.drv/mouse.c
@@ -261,12 +261,21 @@ static void update_relative_valuators(XIAnyClassInfo **valuators, int n_valuator
@@ -264,12 +264,21 @@ static void update_relative_valuators(XIAnyClassInfo **valuators, int n_valuator
thread_data->y_rel_valuator.number = -1;
thread_data->x_abs_valuator.number = -1;
thread_data->y_abs_valuator.number = -1;
@ -32,12 +32,12 @@ index 472ba77d0a..65b1b500d0 100644
+ if (valuators[i]->type == XIScrollClass)
+ {
+ if (scroll_class->scroll_type == XIScrollTypeVertical)
+ thread_data->xi2_wheel_multiplier = WHEEL_DELTA / scroll_class->increment;
+ thread_data->xi2_wheel_multiplier = -WHEEL_DELTA / scroll_class->increment;
+ }
if (valuators[i]->type != XIValuatorClass) continue;
if (class->label == x11drv_atom( Rel_X ) ||
(!class->label && class->number == 0 && class->mode == XIModeRelative))
@@ -288,6 +297,11 @@ static void update_relative_valuators(XIAnyClassInfo **valuators, int n_valuator
@@ -291,6 +300,11 @@ static void update_relative_valuators(XIAnyClassInfo **valuators, int n_valuator
{
valuator_data = &thread_data->y_abs_valuator;
}
@ -49,7 +49,7 @@ index 472ba77d0a..65b1b500d0 100644
if (valuator_data) {
valuator_data->number = class->number;
@@ -336,6 +350,8 @@ void X11DRV_XInput2_Enable(void)
@@ -339,6 +353,8 @@ void X11DRV_XInput2_Enable(void)
XISetMask( mask_bits, XI_DeviceChanged );
XISetMask( mask_bits, XI_RawMotion );
XISetMask( mask_bits, XI_DeviceChanged );
@ -58,7 +58,7 @@ index 472ba77d0a..65b1b500d0 100644
/* XInput 2.0 has a problematic behavior where master pointer will
* not send raw events to the root window whenever a grab is active
@@ -393,6 +409,7 @@ void X11DRV_XInput2_Disable(void)
@@ -396,6 +412,7 @@ void X11DRV_XInput2_Disable(void)
pXIFreeDeviceInfo( data->xi2_devices );
data->x_rel_valuator.number = -1;
data->y_rel_valuator.number = -1;
@ -66,7 +66,7 @@ index 472ba77d0a..65b1b500d0 100644
data->xi2_devices = NULL;
data->xi2_core_pointer = 0;
data->xi2_current_slave = 0;
@@ -1775,12 +1792,13 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
@@ -1833,12 +1850,13 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
INPUT input;
RAWINPUT raw_input;
int i;
@ -83,7 +83,7 @@ index 472ba77d0a..65b1b500d0 100644
if (!event->valuators.mask_len) return FALSE;
if (thread_data->xi2_state < xi_enabled) return FALSE;
@@ -1816,6 +1834,7 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
@@ -1874,6 +1892,7 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
y_rel = &thread_data->y_rel_valuator;
x_abs = &thread_data->x_abs_valuator;
y_abs = &thread_data->y_abs_valuator;
@ -91,7 +91,7 @@ index 472ba77d0a..65b1b500d0 100644
input.type = INPUT_MOUSE;
input.u.mi.mouseData = 0;
@@ -1836,7 +1855,7 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
@@ -1894,7 +1913,7 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
virtual_rect = get_virtual_screen_rect();
@ -100,7 +100,7 @@ index 472ba77d0a..65b1b500d0 100644
{
if (!XIMaskIsSet( event->valuators.mask, i )) continue;
val = *values++;
@@ -1871,6 +1890,10 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
@@ -1929,6 +1948,10 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
raw_input.data.mouse.usFlags = MOUSE_MOVE_ABSOLUTE | MOUSE_VIRTUAL_DESKTOP;
raw_input.data.mouse.lLastY = raw_y = raw_val * (65536 / (y_abs->max - y_abs->min));
}
@ -111,7 +111,7 @@ index 472ba77d0a..65b1b500d0 100644
}
if (broken_rawevents && is_old_motion_event( xev->serial ))
@@ -1885,13 +1908,70 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
@@ -1943,13 +1966,70 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
__wine_send_input( 0, &input );
}
@ -184,7 +184,7 @@ index 472ba77d0a..65b1b500d0 100644
#endif /* HAVE_X11_EXTENSIONS_XINPUT2_H */
@@ -1956,6 +2036,11 @@ BOOL X11DRV_GenericEvent( HWND hwnd, XEvent *xev )
@@ -2014,6 +2094,11 @@ BOOL X11DRV_GenericEvent( HWND hwnd, XEvent *xev )
case XI_RawMotion:
ret = X11DRV_RawMotion( event );
break;
@ -197,7 +197,7 @@ index 472ba77d0a..65b1b500d0 100644
default:
TRACE( "Unhandled event %#x\n", event->evtype );
diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h
index 2c59f19815..928f858924 100644
index e9d9514ee2..599ed48154 100644
--- a/dlls/winex11.drv/x11drv.h
+++ b/dlls/winex11.drv/x11drv.h
@@ -344,6 +344,8 @@ struct x11drv_thread_data
@ -209,7 +209,7 @@ index 2c59f19815..928f858924 100644
int xi2_core_pointer; /* XInput2 core pointer id */
int xi2_current_slave; /* Current slave driving the Core pointer */
};
@@ -431,6 +433,7 @@ enum x11drv_atoms
@@ -432,6 +434,7 @@ enum x11drv_atoms
XATOM_Rel_Y,
XATOM_Abs_X,
XATOM_Abs_Y,

View File

@ -1,4 +1,4 @@
From acc742850b54dcd6d3fc0ad91efd7146ffbeff93 Mon Sep 17 00:00:00 2001
From 5c4db171dc87400ecd3e57b7efff805032328b5f Mon Sep 17 00:00:00 2001
From: Jordan Galby <gravemind2a+wine@gmail.com>
Date: Tue, 16 Jul 2019 00:34:38 -0400
Subject: [PATCH 09/11] winex11.drv: Don't react to small slow mouse movements.
@ -12,10 +12,10 @@ Signed-off-by: Derek Lesho <dereklesho52@Gmail.com>
2 files changed, 42 insertions(+), 10 deletions(-)
diff --git a/dlls/winex11.drv/mouse.c b/dlls/winex11.drv/mouse.c
index 65b1b500d0..4d5b0a45ff 100644
index 1d9833b5c9..1b109c8d1a 100644
--- a/dlls/winex11.drv/mouse.c
+++ b/dlls/winex11.drv/mouse.c
@@ -263,6 +263,10 @@ static void update_relative_valuators(XIAnyClassInfo **valuators, int n_valuator
@@ -266,6 +266,10 @@ static void update_relative_valuators(XIAnyClassInfo **valuators, int n_valuator
thread_data->y_abs_valuator.number = -1;
thread_data->wheel_valuator.number = -1;
@ -26,7 +26,7 @@ index 65b1b500d0..4d5b0a45ff 100644
thread_data->xi2_wheel_multiplier = 0;
for (i = 0; i < n_valuators; i++)
@@ -1862,9 +1866,9 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
@@ -1920,9 +1924,9 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
raw_val = *raw_values++;
if (i == x_rel->number)
{
@ -38,7 +38,7 @@ index 65b1b500d0..4d5b0a45ff 100644
/ (x_rel->max - x_rel->min);
raw_input.data.mouse.usFlags = MOUSE_MOVE_RELATIVE;
@@ -1872,9 +1876,9 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
@@ -1930,9 +1934,9 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
}
if (i == y_rel->number)
{
@ -50,7 +50,7 @@ index 65b1b500d0..4d5b0a45ff 100644
/ (y_rel->max - y_rel->min);
raw_input.data.mouse.usFlags = MOUSE_MOVE_RELATIVE;
@@ -1898,20 +1902,47 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
@@ -1956,20 +1960,47 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
if (broken_rawevents && is_old_motion_event( xev->serial ))
{
@ -105,7 +105,7 @@ index 65b1b500d0..4d5b0a45ff 100644
TRACE("raw %s event %f,%f + %f\n",
diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h
index 928f858924..206473fde9 100644
index 599ed48154..005512fc4e 100644
--- a/dlls/winex11.drv/x11drv.h
+++ b/dlls/winex11.drv/x11drv.h
@@ -320,6 +320,7 @@ struct x11drv_valuator_data

View File

@ -1,4 +1,4 @@
From 068d3780cc90fccfd49c23670baf526c4f93ad82 Mon Sep 17 00:00:00 2001
From 97ab5ded8d021c911308f215bbfd27ebd0de4294 Mon Sep 17 00:00:00 2001
From: Derek Lesho <dereklesho52@Gmail.com>
Date: Sat, 10 Aug 2019 12:20:59 -0400
Subject: [PATCH 10/11] server: Implement RIDEV_INPUTSINK flag
@ -10,10 +10,10 @@ Signed-off-by: Derek Lesho <dereklesho52@Gmail.com>
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/dlls/user32/rawinput.c b/dlls/user32/rawinput.c
index 58480b8ae7..c231e2059c 100644
index 661a0e3b25..a93dc36500 100644
--- a/dlls/user32/rawinput.c
+++ b/dlls/user32/rawinput.c
@@ -271,7 +271,7 @@ BOOL WINAPI DECLSPEC_HOTPATCH RegisterRawInputDevices(RAWINPUTDEVICE *devices, U
@@ -282,7 +282,7 @@ BOOL WINAPI DECLSPEC_HOTPATCH RegisterRawInputDevices(RAWINPUTDEVICE *devices, U
TRACE("device %u: page %#x, usage %#x, flags %#x, target %p.\n",
i, devices[i].usUsagePage, devices[i].usUsage,
devices[i].dwFlags, devices[i].hwndTarget);
@ -23,7 +23,7 @@ index 58480b8ae7..c231e2059c 100644
d[i].usage_page = devices[i].usUsagePage;
diff --git a/server/queue.c b/server/queue.c
index c9446f7f4b..2596925aca 100644
index 060e73b819..0c3b5354bd 100644
--- a/server/queue.c
+++ b/server/queue.c
@@ -2442,7 +2442,9 @@ DECL_HANDLER(send_rawinput_message)

View File

@ -1,4 +1,4 @@
From 899bf2085fbd1e8b3e5ddcea3a9070f2836f3c06 Mon Sep 17 00:00:00 2001
From 1a2b1df3e51425163af922ae5181d17a7f5ad380 Mon Sep 17 00:00:00 2001
From: Derek Lesho <dereklesho52@Gmail.com>
Date: Wed, 4 Sep 2019 10:07:39 -0500
Subject: [PATCH 11/11] winex11.drv: [HACK] XWayland workaround.
@ -8,7 +8,7 @@ Subject: [PATCH 11/11] winex11.drv: [HACK] XWayland workaround.
1 file changed, 32 insertions(+), 4 deletions(-)
diff --git a/dlls/winex11.drv/mouse.c b/dlls/winex11.drv/mouse.c
index 4d5b0a45ff..178e717131 100644
index 1b109c8d1a..b06b7dc170 100644
--- a/dlls/winex11.drv/mouse.c
+++ b/dlls/winex11.drv/mouse.c
@@ -25,6 +25,7 @@
@ -19,7 +19,7 @@ index 4d5b0a45ff..178e717131 100644
#ifdef HAVE_X11_EXTENSIONS_XINPUT2_H
#include <X11/extensions/XInput2.h>
#endif
@@ -1784,6 +1785,17 @@ static BOOL X11DRV_DeviceChanged( XGenericEventCookie *xev )
@@ -1842,6 +1843,17 @@ static BOOL X11DRV_DeviceChanged( XGenericEventCookie *xev )
return TRUE;
}
@ -37,7 +37,7 @@ index 4d5b0a45ff..178e717131 100644
/***********************************************************************
* X11DRV_RawMotion
*/
@@ -1886,13 +1898,29 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
@@ -1944,13 +1956,29 @@ static BOOL X11DRV_RawMotion( XGenericEventCookie *xev )
}
if (i == x_abs->number)
{