libinput: Support disableEventsOnExternalMouse for touchpads
Related MR to expose this option in the Touchpad KCM: plasma-desktop!2672
Commit message
The third "Send Events Mode" for a libinput device, in addition to
"enabled" and "disabled" modes, was previously only hinted at
through a supportsDisableEventsOnExternalMouse
property.
It couldn't be queried or set though.
This commit adds a new property, disableEventsOnExternalMouse
as well as a corresponding disableWhileTypingEnabledByDefault
,
to KWin's InputDevice D-Bus interface.
The libinput API allows passing both kinds of "disabled" modes
as bitmask (although with uncertain outcomes if combining with
the "enabled" bit) and its X11 property access API features the
same two booleans. Given this, as well as the pre-existing
supportsDisableEventsOnExternalMouse
property, it makes sense
to expose the new option as separate boolean, independent from
the enabled
property except perhaps on the initial read.
enabled
will remain true while the new boolean is set, and also
when connecting an external mouse actually disables the device.