Module: wine Branch: master Commit: b341688dbd9dfc05bd61d6b8f494867e6343b702 URL: https://gitlab.winehq.org/wine/wine/-/commit/b341688dbd9dfc05bd61d6b8f494867...
Author: Rémi Bernon rbernon@codeweavers.com Date: Sun Jan 28 19:32:11 2024 +0100
winex11: Process XInput2 events with QS_INPUT filter.
---
dlls/winex11.drv/event.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/dlls/winex11.drv/event.c b/dlls/winex11.drv/event.c index aafb89a4fed..8b02361aaff 100644 --- a/dlls/winex11.drv/event.c +++ b/dlls/winex11.drv/event.c @@ -233,9 +233,6 @@ static Bool filter_event( Display *display, XEvent *event, char *arg ) case ButtonPress: case ButtonRelease: return (mask & QS_MOUSEBUTTON) != 0; -#ifdef GenericEvent - case GenericEvent: -#endif case MotionNotify: case EnterNotify: case LeaveNotify: @@ -250,6 +247,13 @@ static Bool filter_event( Display *display, XEvent *event, char *arg ) case PropertyNotify: case ClientMessage: return (mask & QS_POSTMESSAGE) != 0; +#ifdef GenericEvent + case GenericEvent: +#ifdef HAVE_X11_EXTENSIONS_XINPUT2_H + if (event->xcookie.extension == xinput2_opcode) return (mask & QS_INPUT) != 0; +#endif + /* fallthrough */ +#endif default: return (mask & QS_SENDMESSAGE) != 0; }