[Xfce4-commits] <xfdesktop:danielm/port-to-gio> * src/xfdesktop-dbus-bindings-filemanager.xml: - Updated bindings file (Added Thunar interface) * src/xfdesktop-file-icon.c: * src/xfdesktop-file-icon.h: - Drop file Jobs. * src/xfdesktop-file-utils.c: * src/xfdesktop-file-utils.c: - Drop file Jobs stuff. - Added Thunar Dbus proxy. - Implemented xfdesktop_file_utils_launch_icon()

Daniel Morales noreply at xfce.org
Wed Feb 24 02:12:03 CET 2010


Updating branch refs/heads/danielm/port-to-gio
         to 09715fddfffa5491ec65d808b569927925681ca2 (commit)
       from a7d66f5d3304447273f661e72073af3b7cc8f791 (commit)

commit 09715fddfffa5491ec65d808b569927925681ca2
Author: Daniel Morales <daniel at daniel.com.uy>
Date:   Tue Feb 23 19:52:24 2010 -0200

    * src/xfdesktop-dbus-bindings-filemanager.xml:
    		- Updated bindings file (Added Thunar interface)
    * src/xfdesktop-file-icon.c:
    * src/xfdesktop-file-icon.h:
    		- Drop file Jobs.
    * src/xfdesktop-file-utils.c:
    * src/xfdesktop-file-utils.c:
    		- Drop file Jobs stuff.
    		- Added Thunar Dbus proxy.
    		- Implemented xfdesktop_file_utils_launch_icon()

 src/xfdesktop-dbus-bindings-filemanager.xml |  109 ++++++++++++++
 src/xfdesktop-file-icon.c                   |  113 +--------------
 src/xfdesktop-file-icon.h                   |    7 +-
 src/xfdesktop-file-utils.c                  |  212 +++++++--------------------
 src/xfdesktop-file-utils.h                  |   24 +---
 5 files changed, 171 insertions(+), 294 deletions(-)

diff --git a/src/xfdesktop-dbus-bindings-filemanager.xml b/src/xfdesktop-dbus-bindings-filemanager.xml
index b76fa74..fd09019 100644
--- a/src/xfdesktop-dbus-bindings-filemanager.xml
+++ b/src/xfdesktop-dbus-bindings-filemanager.xml
@@ -97,4 +97,113 @@
       <arg direction="in" name="display" type="s" />
     </method>
   </interface>
+
+  <!--
+    org.xfce.Thunar
+
+    The Thunar specific interface, which provides Thunar specific
+    methods, and which should not be implemented by any other
+    file manager.
+
+    This interface is also subject to change. So, unless you know
+    what you are doing, and you want to limit yourself to Thunar,
+    do not use this interface, but use org.xfce.FileManager instead.
+  -->
+  <interface name="org.xfce.Thunar">
+    <annotation name="org.freedesktop.DBus.GLib.CSymbol" value="thunar_dbus_service" />
+
+    <!--
+      LaunchFiles (working_directory : STRING, filenames : ARRAY OF STRING, display : STRING, startup_id : STRING) : VOID
+
+      working_directory : the directory, relative to which filenames should
+                          be interpreted.
+      filenames         : an array of file names to launch. The file names may
+                          be either file:-URIs, absolute paths or paths relative
+                          to the working_directory.
+      display           : the screen on which to launch the filenames or ""
+                          to use the default screen of the file manager.
+      startup_id        : the DESKTOP_STARTUP_ID environment variable for properly
+                           handling startup notification and focus stealing.
+    -->
+    <method name="LaunchFiles">
+      <arg direction="in" name="working_directory" type="s" />
+      <arg direction="in" name="filenames" type="as" />
+      <arg direction="in" name="display" type="s" />
+      <arg direction="in" name="startup_id" type="s" />
+    </method>
+
+    <!--
+      CopyInto (filenames : ARRAY OF STRING, target : STRING, display : STRING, startup_id : STRING) : VOID
+
+      filenames         : an array of file names to copy. The file names may
+                          be either file:-URIs, absolute paths or paths relative
+                          to the working_directory.
+      target            : the target directory.
+      display           : the screen on which to launch the filenames or ""
+                          to use the default screen of the file manager.
+      startup_id        : the DESKTOP_STARTUP_ID environment variable for properly
+                           handling startup notification and focus stealing.
+    -->
+    <method name="CopyInto">
+      <arg direction="in" name="filenames" type="as" />
+      <arg direction="in" name="target" type="s" />
+      <arg direction="in" name="display" type="s" />
+      <arg direction="in" name="startup_id" type="s" />
+    </method>
+
+    <!--
+      MoveInto (filenames : ARRAY OF STRING, target : STRING, display : STRING, startup_id : STRING) : VOID
+
+      filenames         : an array of file names to move. The file names may
+                          be either file:-URIs, absolute paths or paths relative
+                          to the working_directory.
+      target            : the target directory.
+      display           : the screen on which to launch the filenames or ""
+                          to use the default screen of the file manager.
+      startup_id        : the DESKTOP_STARTUP_ID environment variable for properly
+                           handling startup notification and focus stealing.
+    -->
+    <method name="MoveInto">
+      <arg direction="in" name="filenames" type="as" />
+      <arg direction="in" name="target" type="s" />
+      <arg direction="in" name="display" type="s" />
+      <arg direction="in" name="startup_id" type="s" />
+    </method>
+
+    <!--
+      LinkInto (filenames : ARRAY OF STRING, target : STRING, display : STRING, startup_id : STRING) : VOID
+
+      filenames         : an array of file names to link. The file names may
+                          be either file:-URIs, absolute paths or paths relative
+                          to the working_directory.
+      target            : the target directory.
+      display           : the screen on which to launch the filenames or ""
+                          to use the default screen of the file manager.
+      startup_id        : the DESKTOP_STARTUP_ID environment variable for properly
+                           handling startup notification and focus stealing.
+    -->
+    <method name="LinkInto">
+      <arg direction="in" name="filenames" type="as" />
+      <arg direction="in" name="target" type="s" />
+      <arg direction="in" name="display" type="s" />
+      <arg direction="in" name="startup_id" type="s" />
+    </method>
+
+    <!--
+      UnlinkFiles (filenames : ARRAY OF STRING, display : STRING, startup_id : STRING) : VOID
+
+      filenames         : an array of file names to delete. The file names may
+                          be either file:-URIs, absolute paths or paths relative
+                          to the working_directory.
+      display           : the screen on which to launch the filenames or ""
+                          to use the default screen of the file manager.
+      startup_id        : the DESKTOP_STARTUP_ID environment variable for properly
+                           handling startup notification and focus stealing.
+    -->
+    <method name="UnlinkFiles">
+      <arg direction="in" name="filenames" type="as" />
+      <arg direction="in" name="display" type="s" />
+      <arg direction="in" name="startup_id" type="s" />
+    </method>
+  </interface>
 </node>
diff --git a/src/xfdesktop-file-icon.c b/src/xfdesktop-file-icon.c
index 536fb54..2e25b80 100644
--- a/src/xfdesktop-file-icon.c
+++ b/src/xfdesktop-file-icon.c
@@ -30,11 +30,11 @@
 
 #include "xfdesktop-file-utils.h"
 #include "xfdesktop-file-icon.h"
-#include "xfdesktop-job.h"
+#include "xfdesktop-dbus-bindings-filemanager.h"
 
 struct _XfdesktopFileIconPrivate
 {
-    GList *active_jobs;
+    /* private */
 };
 
 static void xfdesktop_file_icon_finalize(GObject *obj);
@@ -76,30 +76,6 @@ xfdesktop_file_icon_finalize(GObject *obj)
 
     if(icon->gfile)
         g_object_unref(icon->gfile);
-
-    if(icon->priv->active_jobs) {
-        GList *l;
-        XfdesktopJob *job;
-        GCallback cb;
-        
-        for(l = icon->priv->active_jobs; l; l = l->next) {
-            job = XFDESKTOP_JOB(l->data);
-            cb = g_object_get_data(G_OBJECT(job),
-                                             "--xfdesktop-file-icon-callback");
-            if(cb) {
-                gpointer data = g_object_get_data(obj,
-                                                  "--xfdesktop-file-icon-data");
-                g_signal_handlers_disconnect_by_func(G_OBJECT(job),
-                                                     G_CALLBACK(cb),
-                                                     data);
-                g_object_set_data(G_OBJECT(job),
-                                  "--xfdesktop-file-icon-callback", NULL);
-            }
-            xfdesktop_job_cancel(job);
-            g_object_unref(G_OBJECT(job));
-        }
-        g_list_free(icon->priv->active_jobs);
-    }
     
     G_OBJECT_CLASS(xfdesktop_file_icon_parent_class)->finalize(obj);
 }
@@ -107,68 +83,7 @@ xfdesktop_file_icon_finalize(GObject *obj)
 static gboolean
 xfdesktop_file_icon_activated(XfdesktopIcon *icon)
 {
-    XfdesktopFileIcon *file_icon = XFDESKTOP_FILE_ICON(icon);
-    GtkWidget *icon_view, *toplevel;
-    GdkScreen *gscreen;
-    gboolean success = FALSE;
-    
-    TRACE("entering");
-
-    g_return_val_if_fail(G_IS_FILE(file_icon->gfile), FALSE);
-    g_return_val_if_fail(G_IS_FILE_INFO(file_icon->gfile), FALSE);
-    
-    icon_view = xfdesktop_icon_peek_icon_view(icon);
-    toplevel = gtk_widget_get_toplevel(icon_view);
-    gscreen = gtk_widget_get_screen(icon_view);
-
-    if(xfdesktop_file_utils_is_directory(file_icon)) {
-        xfdesktop_file_utils_open_folder(file_icon, gscreen, GTK_WINDOW(toplevel));
-        success = TRUE;
-    } else {
-
-        if(xfdesktop_file_utils_is_executable(file_icon)) {
-#if 0
-            success = thunar_vfs_info_execute(info, gscreen, NULL,
-                                                xfce_get_homedir(), NULL);
-#endif
-        }
-
-        if(!success) {
-            GAppInfo *app_info;
-            GdkAppLaunchContext *context;
-
-            app_info = g_file_query_default_handler(file_icon->gfile, NULL, NULL);
-
-            if(app_info != NULL) {
-                GList *file_list = g_list_prepend(NULL, file_icon->gfile);
-
-                context = gdk_app_launch_context_new();
-                gdk_app_launch_context_set_screen(context, gscreen);
-
-                /* We're not showing the GError message.. at the moment */
-                success = g_app_info_launch(app_info, file_list, G_APP_LAUNCH_CONTEXT(context), NULL);
-                if(!success) {
-                    gchar *primary = g_markup_printf_escaped(_("Unable to launch \"%s\":"),
-                                                             g_file_info_get_display_name(file_icon->info));
-                    xfce_message_dialog(GTK_WINDOW(toplevel), _("Launch Error"),
-                                        GTK_STOCK_DIALOG_ERROR, primary,
-                                        _("The associated application could not be found or executed."),
-                                        GTK_STOCK_CLOSE, GTK_RESPONSE_ACCEPT, NULL);
-                    g_free(primary);
-                }
-
-                g_object_unref(context);
-                g_object_unref(app_info);
-                g_list_free(file_list);
-            } else {
-                success = xfdesktop_file_utils_launch_fallback(file_icon,
-                                                               gscreen,
-                                                               GTK_WINDOW(toplevel));
-            }
-        }
-    }
-
-    return success;
+    return xfdesktop_file_utils_launch_icon(XFDESKTOP_FILE_ICON(icon));
 }
 
 void
@@ -247,25 +162,3 @@ xfdesktop_file_icon_delete_file(XfdesktopFileIcon *icon)
         return FALSE;
 }
 
-
-void
-xfdesktop_file_icon_add_active_job(XfdesktopFileIcon *icon,
-                                   XfdesktopJob *job)
-{
-    g_return_if_fail(XFDESKTOP_IS_FILE_ICON(icon) && job);
-    
-    icon->priv->active_jobs = g_list_prepend(icon->priv->active_jobs,
-                                             g_object_ref(G_OBJECT(job)));
-}
-
-gboolean
-xfdesktop_file_icon_remove_active_job(XfdesktopFileIcon *icon,
-                                      XfdesktopJob *job)
-{
-    if(g_list_find(icon->priv->active_jobs, job)) {
-        icon->priv->active_jobs = g_list_remove(icon->priv->active_jobs, job);
-        g_object_unref(G_OBJECT(job));
-        return TRUE;
-    } else
-        return FALSE;
-}
diff --git a/src/xfdesktop-file-icon.h b/src/xfdesktop-file-icon.h
index 419e981..b2c5cde 100644
--- a/src/xfdesktop-file-icon.h
+++ b/src/xfdesktop-file-icon.h
@@ -26,7 +26,6 @@
 #include <gio/gio.h>
 
 #include "xfdesktop-icon.h"
-#include "xfdesktop-job.h"
 
 G_BEGIN_DECLS
 
@@ -76,12 +75,8 @@ gboolean xfdesktop_file_icon_rename_file(XfdesktopFileIcon *icon,
 gboolean xfdesktop_file_icon_can_delete_file(XfdesktopFileIcon *icon);
 gboolean xfdesktop_file_icon_delete_file(XfdesktopFileIcon *icon);
 
-void xfdesktop_file_icon_add_active_job(XfdesktopFileIcon *icon,
-                                        XfdesktopJob *job);
-gboolean xfdesktop_file_icon_remove_active_job(XfdesktopFileIcon *icon,
-                                               XfdesktopJob *job);
-
 
 G_END_DECLS
 
 #endif  /* __XFDESKTOP_FILE_ICON_H__ */
+
diff --git a/src/xfdesktop-file-utils.c b/src/xfdesktop-file-utils.c
index b5bc273..4b5c9c0 100644
--- a/src/xfdesktop-file-utils.c
+++ b/src/xfdesktop-file-utils.c
@@ -48,58 +48,10 @@
 #include "xfdesktop-file-icon.h"
 #include "xfdesktop-common.h"
 #include "xfdesktop-file-utils.h"
-#include "xfdesktop-job.h"
 
 /* File information to query using: xfdesktop_file_utils_get_file_info() */
 #define XFDESKTOP_QUERY_FILE_INFO "standard::*,access::*,unix::*,id::*,time::*"
 
-XfdesktopJobResponse
-xfdesktop_file_utils_interactive_job_ask(GtkWindow *parent,
-                                         const gchar *message,
-                                         XfdesktopJobResponse choices)
-{
-    GtkWidget *dlg, *btn;
-    gint resp;
-    
-    dlg = xfce_message_dialog_new(parent, _("Question"),
-                                  GTK_STOCK_DIALOG_QUESTION, NULL, message,
-                                  NULL, NULL);
-    
-    if(choices & XFDESKTOP_JOB_RESPONSE_CANCEL) {
-        btn = gtk_button_new_from_stock(GTK_STOCK_CANCEL);
-        gtk_widget_show(btn);
-        gtk_dialog_add_action_widget(GTK_DIALOG(dlg), btn,
-                                     XFDESKTOP_JOB_RESPONSE_CANCEL);
-    }
-    
-    if(choices & XFDESKTOP_JOB_RESPONSE_NO) {
-        btn = gtk_button_new_from_stock(GTK_STOCK_NO);
-        gtk_widget_show(btn);
-        gtk_dialog_add_action_widget(GTK_DIALOG(dlg), btn,
-                                     XFDESKTOP_JOB_RESPONSE_NO);
-    }
-    
-    if(choices & XFDESKTOP_JOB_RESPONSE_YES_ALL) {
-        btn = gtk_button_new_with_mnemonic(_("Yes to _all"));
-        gtk_widget_show(btn);
-        gtk_dialog_add_action_widget(GTK_DIALOG(dlg), btn,
-                                     XFDESKTOP_JOB_RESPONSE_YES_ALL);
-    }
-    
-    if(choices & XFDESKTOP_JOB_RESPONSE_YES) {
-        btn = gtk_button_new_from_stock(GTK_STOCK_YES);
-        gtk_widget_show(btn);
-        gtk_dialog_add_action_widget(GTK_DIALOG(dlg), btn,
-                                     XFDESKTOP_JOB_RESPONSE_YES);
-    }
-    
-    resp = gtk_dialog_run(GTK_DIALOG(dlg));
-    
-    gtk_widget_destroy(dlg);
-    
-    return (XfdesktopJobResponse)resp;
-}
-
 void
 xfdesktop_file_utils_handle_fileop_error(GtkWindow *parent,
                                          const XfdesktopFileIcon *src_icon,
@@ -562,118 +514,52 @@ xfdesktop_file_utils_set_window_cursor(GtkWindow *window,
 }
 
 gboolean
-xfdesktop_file_utils_launch_fallback(const XfdesktopFileIcon *icon,
-                                     GdkScreen *screen,
-                                     GtkWindow *parent)
-{
-    gboolean ret = FALSE;
-    gchar *file_manager_app;
-    
-    g_return_val_if_fail(XFDESKTOP_IS_FILE_ICON(icon), FALSE);
-    g_return_val_if_fail(G_IS_FILE_INFO(icon->info), FALSE);
-    g_return_val_if_fail(G_IS_FILE(icon->gfile), 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 = g_file_get_uri(icon->gfile);
-        
-        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);
+xfdesktop_file_utils_launch_icon(const XfdesktopFileIcon *file_icon)
+{
+    DBusGProxy *thunar_proxy;
+    GtkWidget *icon_view, *toplevel;
+    GdkScreen *gscreen;
+    gboolean success = FALSE;
+
+    g_return_val_if_fail(XFDESKTOP_IS_FILE_ICON(file_icon), FALSE);
+    g_return_val_if_fail(G_IS_FILE(file_icon->gfile), FALSE);
+    g_return_val_if_fail(G_IS_FILE_INFO(file_icon->info), FALSE);
+    
+    icon_view = xfdesktop_icon_peek_icon_view(XFDESKTOP_ICON(file_icon));
+    toplevel = gtk_widget_get_toplevel(icon_view);
+    gscreen = gtk_widget_get_screen(icon_view);
+
+    /* use thunar D-BUS API */
+    thunar_proxy = xfdesktop_file_utils_peek_filemanager_proxy();
+    if(thunar_proxy) {
+		GError *error = NULL;
+        gchar *display_name;
+        gchar *uri;
+
+        uri = g_file_get_uri(file_icon->gfile);
+        display_name = gdk_screen_make_display_name(gscreen);
+
+        success = org_xfce_FileManager_launch(thunar_proxy,
+                                              uri,
+                                              display_name,
+                                              &error);
+
+        if(!success) {
+            gchar *primary = g_markup_printf_escaped(_("Unable to launch \"%s\":"),
+                                                     g_file_info_get_display_name(file_icon->info));
+            xfce_message_dialog(GTK_WINDOW(toplevel), _("Launch Error"),
+                                GTK_STOCK_DIALOG_ERROR, primary,
+                                error->message,
+                                GTK_STOCK_CLOSE, GTK_RESPONSE_ACCEPT, NULL);
+            g_error_free(error);
+            g_free(primary);
+        }
+
         g_free(uri);
         g_free(display_name);
     }
-    
-    if(!ret) {
-        gchar *primary = g_markup_printf_escaped(_("Unable to launch \"%s\":"),
-                                                 g_file_info_get_display_name(icon->info));
-        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;
-}
-
-typedef struct
-{
-    const XfdesktopFileIcon *icon;
-    GdkScreen *screen;
-    GtkWindow *parent;
-} XfdesktopDisplayFolderData;
-
-static void
-xfdesktop_file_utils_display_folder_cb(DBusGProxy *proxy,
-                                       GError *error,
-                                       gpointer user_data)
-{
-    XfdesktopDisplayFolderData *dfdata = user_data;
-    
-    g_return_if_fail(dfdata);
-    
-    xfdesktop_file_utils_set_window_cursor(dfdata->parent, GDK_LEFT_PTR);
-    
-    if(error) {
-        xfdesktop_file_utils_launch_fallback(dfdata->icon, dfdata->screen,
-                                             dfdata->parent);
-    }
-    
-    g_free(user_data);
-}
 
-void
-xfdesktop_file_utils_open_folder(const XfdesktopFileIcon *icon,
-                                 GdkScreen *screen,
-                                 GtkWindow *parent)
-{
-    DBusGProxy *fileman_proxy;
-    
-    g_return_if_fail(XFDESKTOP_IS_FILE_ICON(icon) && (screen || parent));
-    g_return_if_fail(G_IS_FILE(icon->gfile));
-    
-    if(!screen)
-        screen = gtk_widget_get_screen(GTK_WIDGET(parent));
-    
-    fileman_proxy = xfdesktop_file_utils_peek_filemanager_proxy();
-    if(fileman_proxy) {
-        XfdesktopDisplayFolderData *dfdata = g_new(XfdesktopDisplayFolderData, 1);
-        gchar *uri = g_file_get_uri(icon->gfile);
-        gchar *display_name = gdk_screen_make_display_name(screen);
-        
-        dfdata->icon = icon;
-        dfdata->screen = screen;
-        dfdata->parent = parent;
-        if(!org_xfce_FileManager_display_folder_async(fileman_proxy,
-                                                      uri, display_name,
-                                                      xfdesktop_file_utils_display_folder_cb,
-                                                      dfdata))
-        {
-            xfdesktop_file_utils_launch_fallback(icon, screen, parent);
-            g_free(dfdata);
-        } else
-            xfdesktop_file_utils_set_window_cursor(parent, GDK_WATCH);
-        
-        g_free(uri);
-        g_free(display_name);
-    } else
-        xfdesktop_file_utils_launch_fallback(icon, screen, parent);
+    return success;
 }
 
 
@@ -681,6 +567,7 @@ static gint dbus_ref_cnt = 0;
 static DBusGConnection *dbus_gconn = NULL;
 static DBusGProxy *dbus_trash_proxy = NULL;
 static DBusGProxy *dbus_filemanager_proxy = NULL;
+static DBusGProxy *dbus_thunar_proxy = NULL;
 
 gboolean
 xfdesktop_file_utils_dbus_init(void)
@@ -711,6 +598,11 @@ xfdesktop_file_utils_dbus_init(void)
                                                            "org.xfce.FileManager",
                                                            "/org/xfce/FileManager",
                                                            "org.xfce.FileManager");
+
+        dbus_thunar_proxy = dbus_g_proxy_new_for_name(dbus_gconn,
+                                                      "org.xfce.FileManager",
+                                                      "/org/xfce/FileManager",
+                                                       "org.xfce.Thunar");
     } else {
         ret = FALSE;
         dbus_ref_cnt = 0;
@@ -731,6 +623,12 @@ xfdesktop_file_utils_peek_filemanager_proxy(void)
     return dbus_filemanager_proxy;
 }
 
+DBusGProxy *
+xfdesktop_file_utils_peek_thunar_proxy(void)
+{
+    return dbus_thunar_proxy;
+}
+
 void
 xfdesktop_file_utils_dbus_cleanup(void)
 {
@@ -741,7 +639,9 @@ xfdesktop_file_utils_dbus_cleanup(void)
         g_object_unref(G_OBJECT(dbus_trash_proxy));
     if(dbus_filemanager_proxy)
         g_object_unref(G_OBJECT(dbus_filemanager_proxy));
-    
+    if(dbus_thunar_proxy)
+        g_object_unref(G_OBJECT(dbus_thunar_proxy));
+
     /* we aren't going to unref dbus_gconn because dbus appears to have a
      * memleak in dbus_connection_setup_with_g_main().  really; the comments
      * in dbus-gmain.c admit this. */
diff --git a/src/xfdesktop-file-utils.h b/src/xfdesktop-file-utils.h
index 9151126..d3b0808 100644
--- a/src/xfdesktop-file-utils.h
+++ b/src/xfdesktop-file-utils.h
@@ -29,11 +29,6 @@
 #endif
 
 #include "xfdesktop-file-icon.h"
-#include "xfdesktop-job.h"
-
-XfdesktopJobResponse xfdesktop_file_utils_interactive_job_ask(GtkWindow *parent,
-                                                              const gchar *message,
-                                                              XfdesktopJobResponse choices);
 
 typedef enum
 {
@@ -48,16 +43,6 @@ void xfdesktop_file_utils_handle_fileop_error(GtkWindow *parent,
                                               XfdesktopFileUtilsFileop fileop,
                                               GError *error);
 
-#if 0
-/* The implementation of both functions are already commented on "master" */
-void xfdesktop_file_utils_copy_into(GtkWindow *parent,
-                                    GList *path_list,
-                                    ThunarVfsPath *dest_path);
-void xfdesktop_file_utils_move_into(GtkWindow *parent,
-                                    GList *path_list,
-                                    ThunarVfsPath *dest_path);
-#endif
-
 GFileInfo *xfdesktop_file_utils_get_file_info(GFile *gfile,
                                               GCancellable *cancellable);
 
@@ -95,18 +80,13 @@ GdkPixbuf *xfdesktop_file_utils_get_file_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 XfdesktopFileIcon *icon,
-                                              GdkScreen *screen,
-                                              GtkWindow *parent);
-
-void xfdesktop_file_utils_open_folder(const XfdesktopFileIcon *icon,
-                                      GdkScreen *screen,
-                                      GtkWindow *parent);
+gboolean xfdesktop_file_utils_launch_icon(const XfdesktopFileIcon *icon);
 
 
 gboolean xfdesktop_file_utils_dbus_init();
 DBusGProxy *xfdesktop_file_utils_peek_trash_proxy();
 DBusGProxy *xfdesktop_file_utils_peek_filemanager_proxy();
+DBusGProxy *xfdesktop_file_utils_peek_thunar_proxy();
 void xfdesktop_file_utils_dbus_cleanup();
 
 



More information about the Xfce4-commits mailing list