mirror of
https://github.com/gnif/LookingGlass.git
synced 2024-11-22 13:37:22 +00:00
[client] x11: register for absolute motion events while grabbed
This commit is contained in:
parent
5789a7efc0
commit
d1043e590a
@ -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;
|
||||
|
@ -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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user