From 6ae41be8260f0f5403367eb01f7cd8319779674a Mon Sep 17 00:00:00 2001 From: Jan Grulich Date: Tue, 9 Mar 2021 09:28:57 +0100 Subject: [PATCH] FileChooser portal: send window id in hex --- qt5-qtbase.spec | 8 ++++-- ...chooser-portal-send-window-id-in-hex.patch | 26 +++++++++++++++++++ 2 files changed, 32 insertions(+), 2 deletions(-) create mode 100644 qtbase-filechooser-portal-send-window-id-in-hex.patch diff --git a/qt5-qtbase.spec b/qt5-qtbase.spec index cb45d3b..ce0055f 100644 --- a/qt5-qtbase.spec +++ b/qt5-qtbase.spec @@ -55,7 +55,8 @@ BuildRequires: pkgconfig(libsystemd) Name: qt5-qtbase Summary: Qt5 - QtBase components Version: 5.15.2 -Release: 14%{?dist} +Release: 15%{?dist} + # See LGPL_EXCEPTIONS.txt, for exception details License: LGPLv2 with exceptions or GPLv3 with exceptions @@ -136,7 +137,7 @@ Patch90: %{name}-gcc11.patch # see also patch90 Patch200: qtbase-QTBUG-90395.patch Patch201: qtbase-QTBUG-89977.patch - +Patch202: qtbase-filechooser-portal-send-window-id-in-hex.patch # Do not check any files in %%{_qt5_plugindir}/platformthemes/ for requires. # Those themes are there for platform integration. If the required libraries are @@ -1060,6 +1061,9 @@ fi %changelog +* Tue Mar 09 2021 Jan Grulich - 5.15.2-15 +- FileChooser portal: send window id in hex + * Fri Feb 19 2021 Rex Dieter - 5.15.2-14 - %%build: explicitly pass -egl build option - unconditional BR: pkgconfig(glesv2) again diff --git a/qtbase-filechooser-portal-send-window-id-in-hex.patch b/qtbase-filechooser-portal-send-window-id-in-hex.patch new file mode 100644 index 0000000..4203036 --- /dev/null +++ b/qtbase-filechooser-portal-send-window-id-in-hex.patch @@ -0,0 +1,26 @@ +From acaabc9108dfe75530960cf8e3ec4f3602cd82e0 Mon Sep 17 00:00:00 2001 +From: Jan Grulich +Date: Mon, 08 Mar 2021 12:29:21 +0100 +Subject: [PATCH] FileChooser portal: send window id in hex + +We send window id in decimal, however, it is expected to be send in hex. +This causes a mismatch and makes portal dialog to show in background. + +Pick-to: 5.15 6.0 6.1 +Change-Id: Ibd77199bbb4a2ad4782a0457ddc5506c6b5608fe +Reviewed-by: Thiago Macieira +--- + +diff --git a/src/plugins/platformthemes/xdgdesktopportal/qxdgdesktopportalfiledialog.cpp b/src/plugins/platformthemes/xdgdesktopportal/qxdgdesktopportalfiledialog.cpp +index ec153f6..85bdd1a 100644 +--- a/src/plugins/platformthemes/xdgdesktopportal/qxdgdesktopportalfiledialog.cpp ++++ b/src/plugins/platformthemes/xdgdesktopportal/qxdgdesktopportalfiledialog.cpp +@@ -185,7 +185,7 @@ + QLatin1String("/org/freedesktop/portal/desktop"), + QLatin1String("org.freedesktop.portal.FileChooser"), + d->saveFile ? QLatin1String("SaveFile") : QLatin1String("OpenFile")); +- QString parentWindowId = QLatin1String("x11:") + QString::number(d->winId); ++ QString parentWindowId = QLatin1String("x11:") + QString::number(d->winId, 16); + + QVariantMap options; + if (!d->acceptLabel.isEmpty())