rfd icon indicating copy to clipboard operation
rfd copied to clipboard

Use portals by default

Open orowith2os opened this issue 2 years ago • 2 comments

It can be safely assumed that a system has portals by default; if they don't, many things will simply fail to work, including, but not limited to, the dark mode preference and many other freedesktop settings.

Those that absolutely refuse to use D-Bus will thus end up with an unusable system in the first place, if they want to use anything desktop-related. So enabling the portal backend by default is fine.

GTK will, of course, fall back to using the portals if it's running inside of a Flatpak environment, but it requires manual workarounds outside of one. And, of course, having a library depend on GTK when it's more or less unnecessary isn't ideal.

Closes (although it's already closed) https://github.com/PolyMeilex/rfd/issues/99

orowith2os avatar Aug 04 '23 20:08 orowith2os

Not going to merge this until #66 is resolved (it is mostly implemented already https://github.com/PolyMeilex/rfd/blob/master/src/backend/linux/zenity.rs but needs to be wired in as a fallback).

You'd be surprised how many people actually use those "unusable systems". Just recently, me merging settings portal code in sctk-adwaita caused startup time problems for some users of winit, because people use portal setups so broken that any calls to them result in ~30s delay (xdg portal simply times out after that period as it can't find or communicate with *-impl portal). So those cases are even worse than people without portal setup whatsoever.

It's supper annoying, but those people exist and there is nothing we can do about that.

PolyMeilex avatar Aug 05 '23 00:08 PolyMeilex

We can tell them to fix their systems.

orowith2os avatar Aug 05 '23 01:08 orowith2os

Zenity is now used as a fallback for broken systems, so this is good to go now! :rocket:

PolyMeilex avatar Feb 19 '24 18:02 PolyMeilex