Add a setting to control emulation of middle mouse button under Wayland
I have a Logitech Marble trackball that does not have neither a "middle" button nor a scroll wheel. I've used the org.gnome.desktop.peripherals.trackball scroll-wheel-emulation-button
setting to emulate the wheel by pressing the "back" button (id 8) and rolling the ball. Works perfectly well. But the middle click default emulation works by clicking both left and right buttons at the same time, and that is not very ergonomic. Under X.org, I've configured the button mapping so that the "back" button emulates the middle click, but there is no such option under Wayland. Would it be possible to add a middle-click-emulation
setting of some sort?
Here is my hand-tuned libinput configuration under X.org, for reference:
Section "InputClass"
Identifier "Marble Mouse"
MatchProduct "Logitech USB Trackball"
MatchIsPointer "on"
MatchDevicePath "/dev/input/event*"
Driver "libinput"
Option "ButtonMapping" "1 8 3 4 5 6 7 2 9"
Option "ScrollMethod" "button"
Option "ScrollButton" "8"
EndSection
Thanks for all your efforts!
Edited by dsboger