https://bugs.kde.org/show_bug.cgi?id=305136

--- Comment #12 from nyanpasu64 <nyanpas...@tuta.io> ---
To my knowledge, GNOME determines file associations through a standard XDG
lookup; it's technically performed using VFS, but I don't think it matters for
KDE trying to write default apps. GTK's "Default Applications" settings dialog
uses g_app_info_get_recommended_for_type and g_app_info_get_default_for_type to
fetch the current default app, and g_app_info_set_as_default_for_type to set a
default app. And editing ~/.config/mimeapps.list is necessary and sufficient to
change GNOME's default apps in both Files and Default Applications.

Caveats:

- I haven't looked into how `gio mime` sets associations, but I assume it works
the same way.
- Apparently g_app_info_get/set...()
(https://developer.gnome.org/gio/stable/GAppInfo.html) are actually implemented
in terms of the GIO VFS API. However I've only seen them query the various
mimeapps.list/mimeinfo.cache files, never any virtualized apps. I don't know if
it's necessary for KDE to shell out to these APIs; I was planning to just write
tools that interface with the standard XDG MIME/application files.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to