Bug 448615

Summary: The "Open" Button in the folder chooser dialog only works when a folder is actively selected in the view
Product: [Plasma] xdg-desktop-portal-kde Reporter: jakobdev
Component: generalAssignee: Jan Grulich <jgrulich>
Status: RESOLVED DOWNSTREAM    
Severity: normal CC: aleixpol, mleduque, nate, ritalat
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Manjaro   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description jakobdev 2022-01-16 19:38:21 UTC
If I run any Qt App in a Flatpak, that uses the Open Directory Dialog (QFileDialog.getExistingDirectory()) the dialog opens without any problems and I can browse Directories, but when I click Open, nothing happens.
Comment 1 Nate Graham 2022-01-18 19:19:57 UTC
Can confirm. You have to have a window selected in the main view and then it will work.

This is problematic for the default single-click setting, since single-clicking on a folder opens it, rather than selecting it.

What we should probably do is make the "Open" button choose the currently viewed folder when nothing is selected
Comment 2 Nate Graham 2022-01-18 19:48:55 UTC
*** Bug 440236 has been marked as a duplicate of this bug. ***
Comment 3 Aleix Pol 2022-02-28 15:07:27 UTC
I tried to reproduce using DuckStation as 440236 says and I could not reproduce this issue.

> What we should probably do is make the "Open" button choose the currently viewed folder when nothing is selected

For me, there's $HOME already selected by default.
Comment 4 Nate Graham 2022-03-09 20:21:47 UTC
Hmm, I can't remember what app I used to reproduce it, but I just tried DuckStation and it looks like it now has an inline built in folder chooser and doesn't use the portal.

The folder selector works for me too, when I try using Filelight in a Flatpak.

However it doesn't look the same as how it looked when I reproduced it, so I suspect the app in question was inappropriately using the file dialog as a folder selector, which won't work. Closing for now.
Comment 5 jakobdev 2022-03-15 08:47:40 UTC
I can't reproduce this anymore. It looks like it has been fixed in the latest System update.
Comment 6 Mickaël Leduque 2024-03-03 11:03:12 UTC
Hi,
I can still reproduce this problem here

dpkg -l xdg-desktop-portal-kde 
Souhait=inconnU/Installé/suppRimé/Purgé/H=à garder
| État=Non/Installé/fichier-Config/dépaqUeté/échec-conFig/H=semi-installé/W=attend-traitement-déclenchements
|/ Err?=(aucune)/besoin Réinstallation (État,Err: majuscule=mauvais)
||/ Nom                    Version                          Architecture Description
+++-======================-================================-============-======================================================
ii  xdg-desktop-portal-kde 5.27.9-0ubuntu1~ubuntu23.10~ppa1 amd64        backend implementation for xdg-desktop-portal using Qt

I don't know if I should REOPEN the issue, so I won't until told otherwise.