Bug 1931080 - Portal file dialog opens in background on X session
Summary: Portal file dialog opens in background on X session
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: xdg-desktop-portal-gtk
Version: 33
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: David King
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-02-20 14:19 UTC by kb1000
Modified: 2021-11-30 16:12 UTC (History)
8 users (show)

Fixed In Version: qt5-qtbase-5.15.2-15.fc33 qt5-qtbase-5.15.2-15.fc34
Clone Of:
Environment:
Last Closed: 2021-11-30 16:12:47 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Screencast showing issue is still present (578.56 KB, image/gif)
2021-03-22 22:36 UTC, Nyall Dawson
no flags Details

Description kb1000 2021-02-20 14:19:39 UTC
Description of problem:
Qt applications open the Flatpak portal file picker, even though they are not inside Flatpaks. In addition to that, this file picker is not associated to the application window and opens in the background.
Version-Release number of selected component (if applicable):
qgnomeplatform-0.7.0-2.fc33

How reproducible:
On my machine, always (tested with VLC media player, KDevelop and MultiMC).

Steps to Reproduce:
1. Open any Qt application that contains a file picker on GNOME
2. Open the file picker from the application

Actual results:
The xdg-desktop-portal file picker opens in the background, and says "Portal" in the gnome status bar instead of the application name (as well as sometimes showing an "open files read-only" button)

Expected results:
The native file picker should open in the foreground, and have a window attached to the application window

Additional info:

Comment 1 Jan Grulich 2021-02-22 06:57:47 UTC
This is intentional, QGnomePlatform now defaults to using native file dialog through the portal. I cannot reproduce the issue where it is opened in the background, but the application association is something we have to fix on Wayland.

Comment 2 kb1000 2021-02-24 19:56:23 UTC
Apparently e-mail replies don't go through to bugzilla?
Either way, I forgot to mention in the original post, I'm not on Wayland, I'm on Xorg.

Comment 3 Jan Grulich 2021-02-25 07:18:59 UTC
It doesn't actually matter, it will use xdg-desktop-portal on both. However, on Xorg it should have proper dialog ←→ app association [1]. I will try to look into this.

[1] - https://code.woboq.org/qt5/qtbase/src/plugins/platformthemes/xdgdesktopportal/qxdgdesktopportalfiledialog.cpp.html#174

Comment 4 Jan Grulich 2021-03-09 08:24:23 UTC
Should be fixed with https://codereview.qt-project.org/c/qt/qtbase/+/337969. I will it backport to Fedora.

Comment 5 Fedora Update System 2021-03-09 11:03:39 UTC
FEDORA-2021-dd40f54279 has been submitted as an update to Fedora 33. https://bodhi.fedoraproject.org/updates/FEDORA-2021-dd40f54279

Comment 6 Fedora Update System 2021-03-09 22:46:41 UTC
FEDORA-2021-87f8cd1bf7 has been pushed to the Fedora 34 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-87f8cd1bf7`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-87f8cd1bf7

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 7 Fedora Update System 2021-03-10 00:06:15 UTC
FEDORA-2021-dd40f54279 has been pushed to the Fedora 33 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-dd40f54279`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-dd40f54279

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 8 kb1000 2021-03-12 11:59:59 UTC
This does not fix the issue for me.

Comment 9 Jan Grulich 2021-03-12 12:08:54 UTC
(In reply to kb1000 from comment #8)
> This does not fix the issue for me.

It should fix the issue where portal dialog appears in the background.

Comment 10 Nyall Dawson 2021-03-19 23:12:56 UTC
I confirm @kb1000's finding that the patch does NOT fix the issue of dialogs opening behind the application window.

Comment 11 Fedora Update System 2021-03-22 01:03:58 UTC
FEDORA-2021-dd40f54279 has been pushed to the Fedora 33 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 12 Fedora Update System 2021-03-22 02:07:13 UTC
FEDORA-2021-87f8cd1bf7 has been pushed to the Fedora 34 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 13 Jan Grulich 2021-03-22 06:40:48 UTC
(In reply to Nyall Dawson from comment #10)
> I confirm @kb1000's finding that the patch does NOT fix the issue of dialogs
> opening behind the application window.

Is this on Wayland? This will fix it only on X sessions.

Comment 14 Nyall Dawson 2021-03-22 22:36:26 UTC
> Is this on Wayland? This will fix it only on X sessions.


No, it's on x session. I've added a screencast showing the issue is still present after qt5-qtbase-5.15.2-15.fc33.x86_64

Comment 15 Nyall Dawson 2021-03-22 22:36:50 UTC
Created attachment 1765416 [details]
Screencast showing issue is still present

Comment 16 Nyall Dawson 2021-03-22 22:43:28 UTC
Strangely enough, it works correctly for the VERY FIRST file dialog opened after a new xorg session is launched, but then all subsequent dialogs open behind the application!

Comment 17 Jan Grulich 2021-03-26 12:51:22 UTC
I can reproduce on X session, but also with GTK apps (like GNOME Boxes). I verified whether we send correct window id and we do, same goes for GNOME Boxes, but there is probably something wrong in xdg-desktop-portal-gtk.

Comment 18 Jan Grulich 2021-03-26 12:52:25 UTC
I can reproduce on X session, but also with GTK apps (like GNOME Boxes). I verified whether we send correct window id and we do, same goes for GNOME Boxes, but there is probably something wrong in xdg-desktop-portal-gtk. First opening makes it open correctly with focus, next time and any other opens a dialog without focus.

Comment 19 Ben Cotton 2021-11-04 14:51:06 UTC
This message is a reminder that Fedora 33 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora 33 on 2021-11-30.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
Fedora 'version' of '33'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 33 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 20 Ben Cotton 2021-11-04 15:49:34 UTC
This message is a reminder that Fedora 33 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora 33 on 2021-11-30.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
Fedora 'version' of '33'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 33 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 21 Nyall Dawson 2021-11-05 03:53:23 UTC
Still reproducible on Fedora 35.

Comment 22 Ben Cotton 2021-11-30 16:12:47 UTC
Fedora 33 changed to end-of-life (EOL) status on 2021-11-30. Fedora 33 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


Note You need to log in before you can comment on or make changes to this bug.