summaryrefslogtreecommitdiff
path: root/src/evdev.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/evdev.c')
-rw-r--r--src/evdev.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/evdev.c b/src/evdev.c
index b1f9b2e..562c7e7 100644
--- a/src/evdev.c
+++ b/src/evdev.c
@@ -408,6 +408,10 @@ EvdevProcessValuators(InputInfoPtr pInfo)
tmp = pEvdev->delta[REL_X];
pEvdev->delta[REL_X] = pEvdev->delta[REL_Y];
pEvdev->delta[REL_Y] = tmp;
+ if (pEvdev->delta[REL_X] == 0)
+ valuator_mask_unset(pEvdev->vals, REL_X);
+ if (pEvdev->delta[REL_Y] == 0)
+ valuator_mask_unset(pEvdev->vals, REL_Y);
}
if (pEvdev->invert_x)
pEvdev->delta[REL_X] *= -1;