diff options
author | Simon McVittie <smcv@debian.org> | 2023-08-28 14:47:38 +0100 |
---|---|---|
committer | Simon McVittie <smcv@debian.org> | 2023-10-26 19:28:38 +0100 |
commit | ae0867f17383a408e3ab70da530fcf9597c8396b (patch) | |
tree | 504559a4bce7b73cd4b14f4315f6919a525c0637 | |
parent | fc05a16a9dc93ab96f379bd1e3cb3c9db8fbbb37 (diff) |
portal-impl: Hard-code x-d-p-gtk as a last-resort fallback
x-d-p-gtk has historically been used in Debian as the portal
implementation of last resort. Until we can get all desktop environments
to ship a suitable portals.conf(5), continue to fall back to it.
Forwarded: not-needed, Debian-specific
Signed-off-by: Simon McVittie <smcv@debian.org>
Gbp-Pq: Topic debian
Gbp-Pq: Name portal-impl-Hard-code-x-d-p-gtk-as-a-last-resort-fallback.patch
-rw-r--r-- | src/portal-impl.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/portal-impl.c b/src/portal-impl.c index 0fa9682..b67522a 100644 --- a/src/portal-impl.c +++ b/src/portal-impl.c @@ -587,19 +587,24 @@ find_portal_implementation (const char *interface) } } -#if 0 - /* Fall back to *any* installed implementation */ for (l = implementations; l != NULL; l = l->next) { PortalImplementation *impl = l->data; + if (!g_str_equal (impl->dbus_name, "org.freedesktop.impl.portal.desktop.gtk")) + continue; + if (!g_strv_contains ((const char **)impl->interfaces, interface)) continue; - g_debug ("Falling back to %s.portal for %s", impl->source, interface); + g_warning ("Choosing %s.portal for %s via temporary hard-coded fallback", + impl->source, interface); + g_warning_once ("The preferred method to match portal implementations " + "to desktop environments is to use the portals.conf(5) " + "configuration file"); + return impl; } -#endif return NULL; } |