mirror of
https://github.com/brl/mutter.git
synced 2025-07-12 21:37:17 +00:00
backends/x11: Add a synaptics check for two finger scroll availability
Commit "backends/x11: Support synaptics configuration" added support for synaptics two finger scrolling but didn't add the code to check that it is available resulting in the upper layer always assuming it isn't.
This commit is contained in:
@ -625,6 +625,17 @@ meta_input_settings_x11_has_two_finger_scroll (MetaInputSettings *settings,
|
|||||||
guchar *available = NULL;
|
guchar *available = NULL;
|
||||||
gboolean has_two_finger = TRUE;
|
gboolean has_two_finger = TRUE;
|
||||||
|
|
||||||
|
if (is_device_synaptics (device))
|
||||||
|
{
|
||||||
|
available = get_property (device, "Synaptics Capabilities",
|
||||||
|
XA_INTEGER, 8, 4);
|
||||||
|
if (!available || !available[3])
|
||||||
|
has_two_finger = FALSE;
|
||||||
|
|
||||||
|
meta_XFree (available);
|
||||||
|
return has_two_finger;
|
||||||
|
}
|
||||||
|
|
||||||
available = get_property (device, "libinput Scroll Methods Available",
|
available = get_property (device, "libinput Scroll Methods Available",
|
||||||
XA_INTEGER, 8, SCROLL_METHOD_NUM_FIELDS);
|
XA_INTEGER, 8, SCROLL_METHOD_NUM_FIELDS);
|
||||||
if (!available || !available[SCROLL_METHOD_FIELD_2FG])
|
if (!available || !available[SCROLL_METHOD_FIELD_2FG])
|
||||||
|
Reference in New Issue
Block a user