[gvfs/wip/oholy/google-native-html: 2/4] google: Use G_FILE_TYPE_REGULAR for native files to fix DND
- From: Ondrej Holy <oholy src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gvfs/wip/oholy/google-native-html: 2/4] google: Use G_FILE_TYPE_REGULAR for native files to fix DND
- Date: Thu, 1 Nov 2018 14:50:21 +0000 (UTC)
commit 8a06ee58eb3e010d49b21588218c16d7a67b3346
Author: Ondrej Holy <oholy redhat com>
Date: Thu Nov 1 09:13:56 2018 +0100
google: Use G_FILE_TYPE_REGULAR for native files to fix DND
daemon/gvfsbackendgoogle.c | 11 ++---------
1 file changed, 2 insertions(+), 9 deletions(-)
---
diff --git a/daemon/gvfsbackendgoogle.c b/daemon/gvfsbackendgoogle.c
index 94a1fa8c..0fdd2c4e 100644
--- a/daemon/gvfsbackendgoogle.c
+++ b/daemon/gvfsbackendgoogle.c
@@ -969,23 +969,16 @@ build_file_info (GVfsBackendGoogle *self,
}
else
{
- content_type = get_content_type_from_entry (entry);
file_type = G_FILE_TYPE_REGULAR;
/* We want native Drive content to open in the browser. */
if (is_native_file (entry))
{
- GDataLink *alternate;
- const gchar *uri;
-
- file_type = G_FILE_TYPE_SHORTCUT;
- alternate = gdata_entry_look_up_link (entry, GDATA_LINK_ALTERNATE);
- uri = gdata_link_get_uri (alternate);
- g_file_info_set_attribute_string (info, G_FILE_ATTRIBUTE_STANDARD_TARGET_URI, uri);
+ content_type = g_strdup ("text/html");
}
else
{
- goffset size;
+ content_type = get_content_type_from_entry (entry);
#if HAVE_LIBGDATA_0_17_7
size = gdata_documents_entry_get_file_size (GDATA_DOCUMENTS_ENTRY (entry));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]