Summary: | Support xdg-document-portal | ||
---|---|---|---|
Product: | [Applications] systemsettings | Reporter: | Ilya Fedin <fedin-ilja2010> |
Component: | kcm_filetypes | Assignee: | Plasma Bugs List <plasma-bugs-null> |
Status: | CONFIRMED --- | ||
Severity: | wishlist | CC: | faure, kde, kdedev, meven, nate |
Priority: | NOR | ||
Version First Reported In: | 6.2.5 | ||
Target Milestone: | --- | ||
Platform: | NixOS | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Ilya Fedin
2025-02-10 23:59:53 UTC
Thanks for the heads-up about this, Ilya. Looks like I made a mistake about the version, it's actually used since 4.10 by any application using the GtkUriLauncher/GtkFileLauncher APIs (opposed to the deprecated gtk_show_uri). So it's live for around 2 years already. 4.18 won't make a difference regarding URL opening actually. I think having per app default apps might be a bit too much to show in the UI. I had a look at this and I think it might no even be needed. - if a mime type has a default app the portal will use that - the app forces to show the app choosing dialog => nothing to do the dialog will always be shown. - the case that some mime type doesnt have a default app - in the case the user selects "remember" => go to 1 - if the user doesn't select a default app, the portal will keep asking a defined number of times and then stop asking, this is where this would matter - the number of times the portal should ask is saved in the permission store, we could just increase that number to some incredibly high number or even reset the number of times it has asked in the past from the portal impl to sidestep this problem. > if a mime type has a default app the portal will use that No, that's true only for a few schemes. All other schemes and all file types get asked 3 times and then remembered for the app that attempted to open the URI/file. https://github.com/flatpak/xdg-desktop-portal/blob/main/src/open-uri.c#L478 That sucks. SO I guess the comment there is not entirely true https://github.com/flatpak/xdg-desktop-portal/issues/472#issuecomment-1423002949 They changed the logic multiple times during the years, it's possible it was the true back then. Or maybe he meant only http(s) URLs talking about firefox. Apparently the latter given that https://github.com/flatpak/xdg-desktop-portal/issues/472#issuecomment-614701580 links the PR changing the logic to the current state. |