diff --git a/client/displayservers/X11/x11.c b/client/displayservers/X11/x11.c index 43bcc22f..0a1dcee0 100644 --- a/client/displayservers/X11/x11.c +++ b/client/displayservers/X11/x11.c @@ -467,9 +467,6 @@ static bool x11EventFilter(SDL_Event * event) case XI_Motion: { - if (!x11.focused || !x11.entered) - return true; - XIDeviceEvent *device = cookie->data; app_updateCursorPos(device->event_x, device->event_y); return true; @@ -588,6 +585,7 @@ static void x11GrabPointer(void) XISetMask(mask.mask, XI_RawButtonPress ); XISetMask(mask.mask, XI_RawButtonRelease); XISetMask(mask.mask, XI_RawMotion ); + XISetMask(mask.mask, XI_Motion ); XIGrabDevice( x11.display, @@ -599,6 +597,7 @@ static void x11GrabPointer(void) GrabModeAsync, false, &mask); + XSync(x11.display, False); x11.pointerGrabbed = true; diff --git a/client/src/main.c b/client/src/main.c index dea3d947..39635fd4 100644 --- a/client/src/main.c +++ b/client/src/main.c @@ -1356,7 +1356,6 @@ void app_handleMouseNormal(double ex, double ey) /* ungrab the pointer and move the local cursor to the exit point */ g_state.ds->ungrabPointer(); - warpPointer(tx, ty, true); return; }