[Xfce4-commits] <xfdesktop:master> Remove unused functions related to ThunarVFS.

Jannis Pohlmann noreply at xfce.org
Tue Nov 2 01:14:45 CET 2010


Updating branch refs/heads/master
         to adf8f1bdfa784fdafaded4e6f75cfd19a2900017 (commit)
       from f5d4f6d41fb5e9717446688d7e14d43b03296389 (commit)

commit adf8f1bdfa784fdafaded4e6f75cfd19a2900017
Author: Jannis Pohlmann <jannis at xfce.org>
Date:   Fri Oct 29 21:38:03 2010 +0200

    Remove unused functions related to ThunarVFS.

 src/xfdesktop-file-utils.c |   75 --------------------------------------------
 src/xfdesktop-file-utils.h |    6 ---
 2 files changed, 0 insertions(+), 81 deletions(-)

diff --git a/src/xfdesktop-file-utils.c b/src/xfdesktop-file-utils.c
index 6622d97..1ce6581 100644
--- a/src/xfdesktop-file-utils.c
+++ b/src/xfdesktop-file-utils.c
@@ -138,32 +138,6 @@ xfdesktop_file_utils_handle_fileop_error(GtkWindow *parent,
     }
 }
 
-gchar *
-xfdesktop_file_utils_get_file_kind(const ThunarVfsInfo *info,
-                                   gboolean *is_link)
-{
-    gchar *str = NULL;
-
-    if(!strcmp(thunar_vfs_mime_info_get_name(info->mime_info),
-               "inode/symlink"))
-    {
-        str = g_strdup(_("broken link"));
-        if(is_link)
-            *is_link = TRUE;
-    } else if(info->flags & THUNAR_VFS_FILE_FLAGS_SYMLINK) {
-        str = g_strdup_printf(_("link to %s"),
-                              thunar_vfs_mime_info_get_comment(info->mime_info));
-        if(is_link)
-            *is_link = TRUE;
-    } else {
-        str = g_strdup(thunar_vfs_mime_info_get_comment(info->mime_info));
-        if(is_link)
-            *is_link = FALSE;
-    }
-    
-    return str;
-}
-
 gboolean 
 xfdesktop_file_utils_is_desktop_file(GFileInfo *info)
 {
@@ -523,55 +497,6 @@ xfdesktop_file_utils_set_window_cursor(GtkWindow *window,
     }
 }
 
-gboolean
-xfdesktop_file_utils_launch_fallback(const ThunarVfsInfo *info,
-                                     GdkScreen *screen,
-                                     GtkWindow *parent)
-{
-    gboolean ret = FALSE;
-    gchar *file_manager_app;
-    
-    g_return_val_if_fail(info, FALSE);
-    
-    file_manager_app = g_find_program_in_path(FILE_MANAGER_FALLBACK);
-    if(file_manager_app) {
-        gchar *commandline, *uri, *display_name;
-        
-        if(!screen && parent)
-            screen = gtk_widget_get_screen(GTK_WIDGET(parent));
-        else if(!screen)
-            screen = gdk_display_get_default_screen(gdk_display_get_default());
-        
-        display_name = gdk_screen_make_display_name(screen);
-        uri = thunar_vfs_path_dup_uri(info->path);
-        
-        commandline = g_strconcat("\"", file_manager_app, "\" \"",
-                                  uri, "\"", NULL);
-        
-        DBG("executing:\n%s\n", commandline);
-        
-        ret = xfce_spawn_command_line_on_screen(screen, commandline, FALSE, TRUE, NULL);
-        
-        g_free(commandline);
-        g_free(file_manager_app);
-        g_free(uri);
-        g_free(display_name);
-    }
-    
-    if(!ret) {
-        gchar *primary = g_markup_printf_escaped(_("Unable to launch \"%s\":"),
-                                                 info->display_name);
-        xfce_message_dialog(GTK_WINDOW(parent),
-                            _("Launch Error"), GTK_STOCK_DIALOG_ERROR,
-                            primary,
-                            _("This feature requires a file manager service present (such as that supplied by Thunar)."),
-                            GTK_STOCK_CLOSE, GTK_RESPONSE_ACCEPT, NULL);
-        g_free(primary);
-    }
-    
-    return ret;
-}
-
 static gchar *
 xfdesktop_file_utils_change_working_directory (const gchar *new_directory)
 {
diff --git a/src/xfdesktop-file-utils.h b/src/xfdesktop-file-utils.h
index 200f30e..ba1438b 100644
--- a/src/xfdesktop-file-utils.h
+++ b/src/xfdesktop-file-utils.h
@@ -55,8 +55,6 @@ void xfdesktop_file_utils_move_into(GtkWindow *parent,
                                     GList *path_list,
                                     ThunarVfsPath *dest_path);
 
-gchar *xfdesktop_file_utils_get_file_kind(const ThunarVfsInfo *info,
-                                          gboolean *is_link);
 gboolean xfdesktop_file_utils_is_desktop_file(GFileInfo *info);
 gboolean xfdesktop_file_utils_file_is_executable(GFileInfo *info);
 gchar *xfdesktop_file_utils_format_time_for_display(guint64 file_time);
@@ -79,10 +77,6 @@ GdkPixbuf *xfdesktop_file_utils_get_icon(const gchar *custom_icon_name,
 void xfdesktop_file_utils_set_window_cursor(GtkWindow *window,
                                             GdkCursorType cursor_type);
 
-gboolean xfdesktop_file_utils_launch_fallback(const ThunarVfsInfo *info,
-                                              GdkScreen *screen,
-                                              GtkWindow *parent);
-
 gboolean xfdesktop_file_utils_app_info_launch(GAppInfo *app_info,
                                               GFile *working_directory,
                                               GList *files,



More information about the Xfce4-commits mailing list