After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 753589 - "Keep aspect ratio" does not always work
"Keep aspect ratio" does not always work
Status: RESOLVED FIXED
Product: gnome-control-center
Classification: Core
Component: Wacom
3.16.x
Other Linux
: Normal normal
: ---
Assigned To: Carlos Garnacho
Control-Center Maintainers
Depends on:
Blocks:
 
 
Reported: 2015-08-13 15:08 UTC by Jehan
Modified: 2015-11-02 18:40 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
common: Add GsdDeviceManager::device-changed (5.80 KB, patch)
2015-10-17 13:49 UTC, Carlos Garnacho
committed Details | Review

Description Jehan 2015-08-13 15:08:07 UTC
I've been testing the "Keep aspect ratio" on an old Wacom bamboo (16:10) on a 16:9 screen. Well it worked.
Yet on another computer, the person had a Wacom Intuos 5 (also 16:10) with a 16:10 screen and an older 5:4 screen. After a few tests, the aspect ratio did not seem like it was kept (we could go as far on every 4 corners as we could on the 16:10 screen.

Not sure what information is needed to diagnose. Do not hesitate to ask.
Thanks!
Comment 1 Carlos Garnacho 2015-10-17 13:49:55 UTC
Created attachment 313530 [details] [review]
common: Add GsdDeviceManager::device-changed

When devices are plugged, we may end up emitting
GsdDeviceManager::device-added at a time when not all GdkDevices have been
attached to the GsdDevice, this makes these devices occasionally not being
applied the right keep-aspect/area settings.

Add a GsdDeviceManager::device-changed signal, emitted for the GsdDevice
for those situations, so the late-added devices are ensured to be updated.
Comment 2 Rui Matos 2015-10-18 15:08:54 UTC
Review of attachment 313530 [details] [review]:

otherwise looks good

::: plugins/wacom/gsd-wacom-manager.c
@@ -863,2 @@
 	if (g_str_equal (key, KEY_ROTATION)) {
-                /* Real device rotation is handled in GsdDeviceMapper */

seems unrelated?

@@ +1139,3 @@
+		return;
+
+	devices = gsd_x11_device_manager_get_gdk_devices (GSD_X11_DEVICE_MANAGER (device_manager),

you don't free the devices array. In fact, the two other existing places where we call this function are leaking it as well.
Comment 3 Carlos Garnacho 2015-11-02 18:40:40 UTC
Oops, fixed the former leaks in a separate commit and fixed these comments in this patch.

Attachment 313530 [details] pushed as 9b62e36 - common: Add GsdDeviceManager::device-changed