[PATCH v2 3/3] Revert "winex11.drv: Only call XWarpPointer if we can get exclusive pointer grab."
Rémi Bernon
rbernon at codeweavers.com
Tue Sep 24 03:52:13 CDT 2019
This reverts commit 8d29f1c84b3da8c5b86d594bab3ac7b628dba1a9.
This is causing some issues and delay in some games (ie: Alan Wake), it
should be safer now to only rely on the keyboard_grabbed flag.
Signed-off-by: Rémi Bernon <rbernon at codeweavers.com>
---
dlls/winex11.drv/mouse.c | 13 -------------
1 file changed, 13 deletions(-)
diff --git a/dlls/winex11.drv/mouse.c b/dlls/winex11.drv/mouse.c
index a12998a40ff..dc7eb8841d3 100644
--- a/dlls/winex11.drv/mouse.c
+++ b/dlls/winex11.drv/mouse.c
@@ -1469,21 +1469,8 @@ BOOL CDECL X11DRV_SetCursorPos( INT x, INT y )
return FALSE;
}
- if (!clipping_cursor &&
- XGrabPointer( data->display, root_window, False,
- PointerMotionMask | ButtonPressMask | ButtonReleaseMask,
- GrabModeAsync, GrabModeAsync, root_window, None, CurrentTime ) != GrabSuccess)
- {
- WARN( "refusing to warp pointer to %u, %u without exclusive grab\n", pos.x, pos.y );
- return FALSE;
- }
-
XWarpPointer( data->display, root_window, root_window, 0, 0, 0, 0, pos.x, pos.y );
data->warp_serial = NextRequest( data->display );
-
- if (!clipping_cursor)
- XUngrabPointer( data->display, CurrentTime );
-
XNoOp( data->display );
XFlush( data->display ); /* avoids bad mouse lag in games that do their own mouse warping */
TRACE( "warped to %d,%d serial %lu\n", x, y, data->warp_serial );
--
2.23.0
More information about the wine-devel
mailing list