[gtk+/gtk-2-24] filechooser: Show FUSE mounted locations in shortcuts
- From: Federico Mena Quintero <federico src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/gtk-2-24] filechooser: Show FUSE mounted locations in shortcuts
- Date: Thu, 10 Mar 2016 21:32:10 +0000 (UTC)
commit 616172d133bd730f1e446f37865893f357ddce1a
Author: Timothy Arceri <t_arceri yahoo com au>
Date: Sun Nov 18 19:39:11 2012 +1100
filechooser: Show FUSE mounted locations in shortcuts
Since FUSE locations can be handled safely by applications show these mounted locations regardless of
whether gtk_file_chooser_set_local_only()
is set to TRUE
https://bugzilla.gnome.org/show_bug.cgi?id=586367
Conflicts:
gtk/gtkfilechooser.c
gtk/gtkfilechooserdefault.c
gtk/gtkfilesystem.c
gtk/gtkfilesystem.h
gtk/gtkfilechooser.c | 12 ++++++++++--
gtk/gtkfilechooserentry.c | 2 +-
2 files changed, 11 insertions(+), 3 deletions(-)
---
diff --git a/gtk/gtkfilechooser.c b/gtk/gtkfilechooser.c
index 8dd0dec..62dd01e 100644
--- a/gtk/gtkfilechooser.c
+++ b/gtk/gtkfilechooser.c
@@ -1498,10 +1498,18 @@ gtk_file_chooser_get_uri (GtkFileChooser *chooser)
if (file)
{
if (gtk_file_chooser_get_local_only (chooser))
- result = file_to_uri_with_native_path (file);
+ {
+ gchar *local = g_file_get_path (file);
+ if (local)
+ {
+ result = g_filename_to_uri (local, NULL, NULL);
+ g_free (local);
+ }
+ }
else
+ {
result = g_file_get_uri (file);
-
+ }
g_object_unref (file);
}
diff --git a/gtk/gtkfilechooserentry.c b/gtk/gtkfilechooserentry.c
index b3e7c88..c360aba 100644
--- a/gtk/gtkfilechooserentry.c
+++ b/gtk/gtkfilechooserentry.c
@@ -561,7 +561,7 @@ set_completion_folder (GtkFileChooserEntry *chooser_entry,
{
if (folder_file &&
chooser_entry->local_only
- && !g_file_is_native (folder_file))
+ && !_gtk_file_has_native_path (folder_file))
folder_file = NULL;
if ((chooser_entry->current_folder_file
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]