Some keyboards export scroll axes and any absolute axis possible in 11
dimensions. All these axes are mute, except possibly for the scroll wheels.

So if a device has a scroll axis, and we're configuring it as mouse, force
the x/y axes into existence. This stops the logspam complaining about not
enough axes on pointer movement after a xrandr change.

Signed-off-by: Peter Hutterer <[email protected]>
---
This may also be the fix for 47281 though it's likely more of a workaround
than a fix.

 src/evdev.c |    3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/evdev.c b/src/evdev.c
index ff43dcf..923d9cd 100644
--- a/src/evdev.c
+++ b/src/evdev.c
@@ -2364,6 +2364,9 @@ EvdevProbe(InputInfoPtr pInfo)
             xf86IDrvMsg(pInfo, X_INFO, "Configuring as touchscreen\n");
             pInfo->type_name = XI_TOUCHSCREEN;
        } else {
+            if (!EvdevBitIsSet(pEvdev->rel_bitmask, REL_X) ||
+                !EvdevBitIsSet(pEvdev->rel_bitmask, REL_Y))
+                EvdevForceXY(pInfo, Relative);
            xf86IDrvMsg(pInfo, X_INFO, "Configuring as mouse\n");
            pInfo->type_name = XI_MOUSE;
        }
-- 
1.7.10
_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to