For future touch points, we need positionSprite to calculate the coordinates but we don't want to actually change the cursor position for non-emulating touches.
Signed-off-by: Peter Hutterer <[email protected]> --- dix/getevents.c | 7 +++++-- 1 files changed, 5 insertions(+), 2 deletions(-) diff --git a/dix/getevents.c b/dix/getevents.c index 57d8c17..3b7b626 100644 --- a/dix/getevents.c +++ b/dix/getevents.c @@ -808,7 +808,7 @@ scale_from_screen(DeviceIntPtr dev, ValuatorMask *mask) * @param[out] screeny y coordinate in desktop coordinate system */ static ScreenPtr -positionSprite(DeviceIntPtr dev, int mode, ValuatorMask *mask, +positionSprite(DeviceIntPtr dev, Bool update, int mode, ValuatorMask *mask, double *devx, double *devy, double *screenx, double *screeny) { @@ -839,6 +839,9 @@ positionSprite(DeviceIntPtr dev, int mode, ValuatorMask *mask, *devx = x; *devy = y; + if (!update) + return scr; + /* miPointerSetPosition takes care of crossing screens for us, as well as * clipping to the current screen. Coordinates returned are in desktop * coord system */ @@ -1251,7 +1254,7 @@ fill_pointer_events(InternalEvent *events, DeviceIntPtr pDev, int type, if ((flags & POINTER_NORAW) == 0) set_raw_valuators(raw, &mask, raw->valuators.data); - scr = positionSprite(pDev, (flags & POINTER_ABSOLUTE) ? Absolute : Relative, + scr = positionSprite(pDev, TRUE, (flags & POINTER_ABSOLUTE) ? Absolute : Relative, &mask, &devx, &devy, &screenx, &screeny); /* screenx, screeny are in desktop coordinates, -- 1.7.7.1 _______________________________________________ [email protected]: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel
