From dedc7ca218ec755fe4f4787f8cd6b16283d3cec3 Mon Sep 17 00:00:00 2001 From: eabdullin Date: Mon, 30 Sep 2024 15:34:03 +0000 Subject: [PATCH] import CS gnome-control-center-40.0-31.el9 --- ...de-connector-name-for-disambiguation.patch | 76 +++++++++++++++++++ SPECS/gnome-control-center.spec | 8 +- 2 files changed, 83 insertions(+), 1 deletion(-) create mode 100644 SOURCES/0001-wacom-Provide-connector-name-for-disambiguation.patch diff --git a/SOURCES/0001-wacom-Provide-connector-name-for-disambiguation.patch b/SOURCES/0001-wacom-Provide-connector-name-for-disambiguation.patch new file mode 100644 index 0000000..7fcd070 --- /dev/null +++ b/SOURCES/0001-wacom-Provide-connector-name-for-disambiguation.patch @@ -0,0 +1,76 @@ +From 55ea6e7468634f97f48ceae20e3e4219e14a8320 Mon Sep 17 00:00:00 2001 +From: Carlos Garnacho +Date: Wed, 7 Feb 2024 22:30:40 +0100 +Subject: [PATCH] wacom: Provide connector name for disambiguation + +Provide the connector name as the fourth value in the +tablet's output setting. With recent Mutter, this will +allow disambiguating the mapped output if there happens +to be multiple outputs with the same EDID data. +--- + panels/wacom/cc-wacom-device.c | 14 ++++++++------ + 1 file changed, 8 insertions(+), 6 deletions(-) + +diff --git a/panels/wacom/cc-wacom-device.c b/panels/wacom/cc-wacom-device.c +index 4a3f98068..36781c9fc 100644 +--- a/panels/wacom/cc-wacom-device.c ++++ b/panels/wacom/cc-wacom-device.c +@@ -257,7 +257,8 @@ static GnomeRROutput * + find_output_by_edid (GnomeRRScreen *rr_screen, + const gchar *vendor, + const gchar *product, +- const gchar *serial) ++ const gchar *serial, ++ const gchar *connector) + { + GnomeRROutput **rr_outputs; + GnomeRROutput *retval = NULL; +@@ -284,8 +285,8 @@ find_output_by_edid (GnomeRRScreen *rr_screen, + (g_strcmp0 (serial, o_serial) == 0); + + if (match) { +- retval = rr_outputs[i]; +- break; ++ if (!retval || g_strcmp0 (connector, gnome_rr_output_get_name (rr_outputs[i])) == 0) ++ retval = rr_outputs[i]; + } + } + +@@ -309,7 +310,7 @@ find_output (GnomeRRScreen *rr_screen, + variant = g_settings_get_value (settings, "output"); + edid = g_variant_get_strv (variant, &n); + +- if (n != 3) { ++ if (n < 3) { + g_critical ("Expected 'output' key to store %d values; got %"G_GSIZE_FORMAT".", 3, n); + return NULL; + } +@@ -317,7 +318,7 @@ find_output (GnomeRRScreen *rr_screen, + if (strlen (edid[0]) == 0 || strlen (edid[1]) == 0 || strlen (edid[2]) == 0) + return NULL; + +- return find_output_by_edid (rr_screen, edid[0], edid[1], edid[2]); ++ return find_output_by_edid (rr_screen, edid[0], edid[1], edid[2], n == 4 ? edid[3] : NULL); + } + + GnomeRROutput * +@@ -353,7 +354,7 @@ cc_wacom_device_set_output (CcWacomDevice *device, + g_autofree gchar *vendor = NULL; + g_autofree gchar *product = NULL; + g_autofree gchar *serial = NULL; +- const gchar *values[] = { "", "", "", NULL }; ++ const gchar *values[] = { "", "", "", "", NULL }; + + g_return_if_fail (CC_IS_WACOM_DEVICE (device)); + +@@ -368,6 +369,7 @@ cc_wacom_device_set_output (CcWacomDevice *device, + values[0] = vendor; + values[1] = product; + values[2] = serial; ++ values[3] = gnome_rr_output_get_name (output); + } + + g_settings_set_strv (settings, "output", values); +-- +2.43.0 + diff --git a/SPECS/gnome-control-center.spec b/SPECS/gnome-control-center.spec index 9b57561..8eafd47 100644 --- a/SPECS/gnome-control-center.spec +++ b/SPECS/gnome-control-center.spec @@ -14,7 +14,7 @@ Name: gnome-control-center Version: 40.0 -Release: 30%{?dist} +Release: 31%{?dist} Summary: Utilities to configure the GNOME desktop License: GPLv2+ and CC-BY-SA @@ -53,6 +53,8 @@ Patch13: gnome-control-center-wwan-5g-support.patch # https://bugzilla.redhat.com/show_bug.cgi?id=2168686 Patch14: 0001-shell-Avoid-handling-map-events-from-other-windows.patch +Patch15: 0001-wacom-Provide-connector-name-for-disambiguation.patch + BuildRequires: chrpath BuildRequires: cups-devel BuildRequires: desktop-file-utils @@ -242,6 +244,10 @@ chrpath --delete $RPM_BUILD_ROOT%{_bindir}/gnome-control-center %dir %{_datadir}/gnome/wm-properties %changelog +* Fri Apr 19 2024 Carlos Garnacho - 40.0-31 +- Provide connector name for disambiguation in Wacom display mapping + Resolves: RHEL-23162 + * Tue Jan 09 2024 Ray Strode - 40.0-30 - Handle subscription manager service not running without crashing