mirror of
https://github.com/brl/mutter.git
synced 2024-11-10 16:16:20 -05:00
input-settings-x11: don't create non-existing atoms
If the atom doesn't exist it won't exist on the device either so we can shortcut the property retrieval/modification. Creating atoms by name but not doing anything with them also confuses kcm_touchpad https://bugzilla.redhat.com/show_bug.cgi?id=1199825 https://bugzilla.gnome.org/show_bug.cgi?id=751471
This commit is contained in:
parent
dd060d78ce
commit
b55f792302
@ -50,7 +50,10 @@ get_property (ClutterInputDevice *device,
|
||||
Atom property_atom, type_ret;
|
||||
guchar *data_ret = NULL;
|
||||
|
||||
property_atom = XInternAtom (xdisplay, property, False);
|
||||
property_atom = XInternAtom (xdisplay, property, True);
|
||||
if (!property_atom)
|
||||
return NULL;
|
||||
|
||||
device_id = clutter_input_device_get_device_id (device);
|
||||
|
||||
rc = XIGetProperty (xdisplay, device_id, property_atom,
|
||||
@ -82,7 +85,10 @@ change_property (ClutterInputDevice *device,
|
||||
Atom property_atom;
|
||||
guchar *data_ret;
|
||||
|
||||
property_atom = XInternAtom (xdisplay, property, False);
|
||||
property_atom = XInternAtom (xdisplay, property, True);
|
||||
if (!property_atom)
|
||||
return;
|
||||
|
||||
device_id = clutter_input_device_get_device_id (device);
|
||||
|
||||
data_ret = get_property (device, property, type, format, nitems);
|
||||
|
Loading…
Reference in New Issue
Block a user