linkbutton: Use GtkFileLauncher for file URI
authorEmmanuele Bassi <ebassi@gnome.org>
Thu, 16 Mar 2023 12:09:55 +0000 (12:09 +0000)
committerEmmanuele Bassi <ebassi@gnome.org>
Thu, 16 Mar 2023 12:22:21 +0000 (12:22 +0000)
commitde3c1d0c739872258699088777a21e49bd474d9e
treedb03a87feb44402c2c47ce99e04d1eaa4c825fe6
parent12858114a291b2e908bb6fdae982b5558c4ceee0
linkbutton: Use GtkFileLauncher for file URI

The GtkUriLauncher calls into the openuri portal, which distinguishes
between files, directories, and URI. The GtkFileLauncher contains logic
to deal with this, because it can already handle the file and folder
differences.

If we have a file:// URI it's easier to create a GFile out of it, and
use the GtkFileLauncher API, while leaving the GtkUriLauncher API for
every other URI scheme.

Fixes: #5671
gtk/gtklinkbutton.c