[Xfce4-commits] r30002 - in thunar/branches/migration-to-gio: . thunar

Jannis Pohlmann jannis at xfce.org
Fri Jun 12 03:09:48 CEST 2009


Author: jannis
Date: 2009-06-12 01:09:47 +0000 (Fri, 12 Jun 2009)
New Revision: 30002

Added:
   thunar/branches/migration-to-gio/thunar/thunar-thumbnailer-manager-dbus.xml
Modified:
   thunar/branches/migration-to-gio/ChangeLog
   thunar/branches/migration-to-gio/thunar/Makefile.am
   thunar/branches/migration-to-gio/thunar/thunar-thumbnailer.c
   thunar/branches/migration-to-gio/thunar/thunar-thumbnailer.h
Log:
	* thunar/Makefile.am, thunar/thunar-thumbnailer-manager-dbus.xml: Add
	  XML D-Bus information for the org.freedesktop.thumbnails.Manager
	  interface.
	* thunar/thunar-thumbnailer.{c,h}: Start implementing the client side
	  of the org.freedesktop.thumbnails.Manager interface. Add new method
	  thunar_thumbnailer_file_is_supported() which requests the supported
	  content types from the thumbnailer manager on demand and checks if
	  the content type of a ThunarFile is a subtype of any of these. Use
	  this in thunar_thumbnailer_queue_files() and
	  thunar_thumbnailer_queue_file() to filter out files which
	  are not supported by the thumbnailer anyway. Make queue requests
	  fail when there are no supported files in the request.

Modified: thunar/branches/migration-to-gio/ChangeLog
===================================================================
--- thunar/branches/migration-to-gio/ChangeLog	2009-06-12 00:21:23 UTC (rev 30001)
+++ thunar/branches/migration-to-gio/ChangeLog	2009-06-12 01:09:47 UTC (rev 30002)
@@ -1,5 +1,20 @@
 2009-06-12	Jannis Pohlmann <jannis at xfce.org>
 
+	* thunar/Makefile.am, thunar/thunar-thumbnailer-manager-dbus.xml: Add
+	  XML D-Bus information for the org.freedesktop.thumbnails.Manager
+	  interface.
+	* thunar/thunar-thumbnailer.{c,h}: Start implementing the client side
+	  of the org.freedesktop.thumbnails.Manager interface. Add new method
+	  thunar_thumbnailer_file_is_supported() which requests the supported
+	  content types from the thumbnailer manager on demand and checks if
+	  the content type of a ThunarFile is a subtype of any of these. Use
+	  this in thunar_thumbnailer_queue_files() and
+	  thunar_thumbnailer_queue_file() to filter out files which
+	  are not supported by the thumbnailer anyway. Make queue requests
+	  fail when there are no supported files in the request.
+
+2009-06-12	Jannis Pohlmann <jannis at xfce.org>
+
 	* Makefile.am, thunar/thunar-image.{c,h},
 	  thunar/thunar-thumbnailer-dbus.xml, thunar/thunar-thumbnailer.{c,h}:
 	  Add two new classes ThunarImage and ThunarThumbnailer. ThunarImage

Modified: thunar/branches/migration-to-gio/thunar/Makefile.am
===================================================================
--- thunar/branches/migration-to-gio/thunar/Makefile.am	2009-06-12 00:21:23 UTC (rev 30001)
+++ thunar/branches/migration-to-gio/thunar/Makefile.am	2009-06-12 01:09:47 UTC (rev 30002)
@@ -248,14 +248,16 @@
 if HAVE_DBUS
 thunar_built_sources +=							\
 	thunar-dbus-service-infos.h					\
-	thunar-thumbnailer-proxy.h
+	thunar-thumbnailer-proxy.h					\
+	thunar-thumbnailer-manager-proxy.h
 
 thunar_dbus_sources =							\
 	thunar-dbus-client.c						\
 	thunar-dbus-client.h						\
 	thunar-dbus-service.c						\
 	thunar-dbus-service.h						\
-	thunar-thumbnailer-proxy.h
+	thunar-thumbnailer-proxy.h					\
+	thunar-thumbnailer-manager-proxy.h
 
 Thunar_CFLAGS +=							\
 	-DDBUS_API_SUBJECT_TO_CHANGE					\
@@ -330,6 +332,12 @@
 		$(srcdir)/thunar-thumbnailer-dbus.xml > thunar-thumbnailer-proxy.h \
 	&& sed -i -e 's/org_freedesktop_thumbnails_Thumbnailer/thunar_thumbnailer_proxy/g' \
 		thunar-thumbnailer-proxy.h
+
+thunar-thumbnailer-manager-proxy.h: $(srcdir)/thunar-thumbnailer-manager-dbus.xml Makefile
+	dbus-binding-tool --mode=glib-client \
+		$(srcdir)/thunar-thumbnailer-manager-dbus.xml > thunar-thumbnailer-manager-proxy.h \
+	&& sed -i -e 's/org_freedesktop_thumbnails_Manager/thunar_thumbnailer_manager_proxy/g' \
+		thunar-thumbnailer-manager-proxy.h
 endif
 
 thunar-throbber-fallback.c: $(srcdir)/thunar-throbber-fallback.png Makefile

Added: thunar/branches/migration-to-gio/thunar/thunar-thumbnailer-manager-dbus.xml
===================================================================
--- thunar/branches/migration-to-gio/thunar/thunar-thumbnailer-manager-dbus.xml	                        (rev 0)
+++ thunar/branches/migration-to-gio/thunar/thunar-thumbnailer-manager-dbus.xml	2009-06-12 01:09:47 UTC (rev 30002)
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<node name="/org/freedesktop/thumbnails/Manager">
+  <interface name="org.freedesktop.thumbnails.Manager">
+    <method name="Register">
+      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/>
+      <arg type="s" name="uri_scheme" direction="in" />
+      <arg type="s" name="mime_type" direction="in" />
+    </method>
+    <method name="GetSupported">
+      <annotation name="org.freedesktop.DBus.GLib.Async" value="true"/>
+      <arg type="as" name="mime_types" direction="out" />
+    </method>
+  </interface>
+</node>

Modified: thunar/branches/migration-to-gio/thunar/thunar-thumbnailer.c
===================================================================
--- thunar/branches/migration-to-gio/thunar/thunar-thumbnailer.c	2009-06-12 00:21:23 UTC (rev 30001)
+++ thunar/branches/migration-to-gio/thunar/thunar-thumbnailer.c	2009-06-12 01:09:47 UTC (rev 30002)
@@ -1,21 +1,21 @@
-/* $Id$ */
+/* vi:set et ai sw=2 sts=2 ts=2: */
 /*-
- * Copyright (c) 2005-2006 Benedikt Meurer <benny at xfce.org>
  * Copyright (c) 2009 Jannis Pohlmann <jannis at xfce.org>
  *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the Free
- * Software Foundation; either version 2 of the License, or (at your option)
- * any later version.
+ * This program is free software; you can redistribute it and/or 
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of 
+ * the License, or (at your option) any later version.
  *
- * This program is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
- * more details.
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the 
+ * GNU General Public License for more details.
  *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA  02111-1307  USA
+ * You should have received a copy of the GNU General Public 
+ * License along with this program; if not, write to the Free 
+ * Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
  */
 
 #ifdef HAVE_CONFIG_H
@@ -29,6 +29,7 @@
 #include <thunar/thunar-private.h>
 #include <thunar/thunar-thumbnailer.h>
 #include <thunar/thunar-thumbnailer-proxy.h>
+#include <thunar/thunar-thumbnailer-manager-proxy.h>
 
 
 
@@ -44,22 +45,26 @@
 
 
 
-static void thunar_thumbnailer_finalize             (GObject           *object);
-static void thunar_thumbnailer_thumbnailer_error    (DBusGProxy        *proxy,
-                                                     guint              handle,
-                                                     const gchar      **uris,
-                                                     gint               code,
-                                                     const gchar       *message,
-                                                     ThunarThumbnailer *thumbnailer);
-static void thunar_thumbnailer_thumbnailer_finished (DBusGProxy        *proxy,
-                                                     guint              handle,
-                                                     ThunarThumbnailer *thumbnailer);
-static void thunar_thumbnailer_thumbnailer_ready    (DBusGProxy        *proxy,
-                                                     const gchar      **uris,
-                                                     ThunarThumbnailer *thumbnailer);
-static void thunar_thumbnailer_thumbnailer_started  (DBusGProxy        *proxy,
-                                                     guint              handle,
-                                                     ThunarThumbnailer *thumbnailer);
+static void thunar_thumbnailer_init_thumbnailer_proxy (ThunarThumbnailer *thumbnailer,
+                                                       DBusGConnection   *connection);
+static void thunar_thumbnailer_init_manager_proxy     (ThunarThumbnailer *thumbnailer,
+                                                       DBusGConnection   *connection);
+static void thunar_thumbnailer_finalize               (GObject           *object);
+static void thunar_thumbnailer_thumbnailer_error      (DBusGProxy        *proxy,
+                                                       guint              handle,
+                                                       const gchar      **uris,
+                                                       gint               code,
+                                                       const gchar       *message,
+                                                       ThunarThumbnailer *thumbnailer);
+static void thunar_thumbnailer_thumbnailer_finished   (DBusGProxy        *proxy,
+                                                       guint              handle,
+                                                       ThunarThumbnailer *thumbnailer);
+static void thunar_thumbnailer_thumbnailer_ready      (DBusGProxy        *proxy,
+                                                       const gchar      **uris,
+                                                       ThunarThumbnailer *thumbnailer);
+static void thunar_thumbnailer_thumbnailer_started    (DBusGProxy        *proxy,
+                                                       guint              handle,
+                                                       ThunarThumbnailer *thumbnailer);
 
 
 
@@ -72,14 +77,19 @@
 {
   GObject __parent__;
 
+  DBusGProxy *manager_proxy;
   DBusGProxy *thumbnailer_proxy;
+
   GMutex     *lock;
-  GList      *requests;
+
+  gchar     **supported_types;
 };
 
 
 
+static DBusGProxy *thunar_thumbnailer_manager_proxy;
 static DBusGProxy *thunar_thumbnailer_proxy;
+static DBusGProxy *thunar_manager_proxy;
 static guint       thumbnailer_signals[LAST_SIGNAL];
 
 
@@ -154,73 +164,114 @@
 
   thumbnailer->lock = g_mutex_new ();
 
+  thumbnailer->supported_types = NULL;
+
   connection = dbus_g_bus_get (DBUS_BUS_SESSION, NULL);
 
+  thunar_thumbnailer_init_thumbnailer_proxy (thumbnailer, connection);
+  thunar_thumbnailer_init_manager_proxy (thumbnailer, connection);
+
   if (connection != NULL)
+    dbus_g_connection_unref (connection);
+}
+
+
+
+static void
+thunar_thumbnailer_init_thumbnailer_proxy (ThunarThumbnailer *thumbnailer,
+                                           DBusGConnection   *connection)
+{
+  if (connection == NULL)
     {
-      if (thunar_thumbnailer_proxy == NULL)
-        {
-          thunar_thumbnailer_proxy = 
-            dbus_g_proxy_new_for_name (connection, 
-                                       "org.freedesktop.thumbnails.Thumbnailer",
-                                       "/org/freedesktop/thumbnails/Thumbnailer",
-                                       "org.freedesktop.thumbnails.Thumbnailer");
+      thumbnailer->thumbnailer_proxy = NULL;
+      return;
+    }
 
-          g_object_add_weak_pointer (G_OBJECT (thunar_thumbnailer_proxy),
-                                     (gpointer) &thunar_thumbnailer_proxy);
+  if (thunar_thumbnailer_proxy == NULL)
+    {
+      thunar_thumbnailer_proxy = 
+        dbus_g_proxy_new_for_name (connection, 
+                                   "org.freedesktop.thumbnails.Thumbnailer",
+                                   "/org/freedesktop/thumbnails/Thumbnailer",
+                                   "org.freedesktop.thumbnails.Thumbnailer");
 
-          thumbnailer->thumbnailer_proxy = thunar_thumbnailer_proxy;
+      g_object_add_weak_pointer (G_OBJECT (thunar_thumbnailer_proxy),
+                                 (gpointer) &thunar_thumbnailer_proxy);
 
-          /* TODO this should actually be VOID:UINT,POINTER,INT,STRING */
-          dbus_g_object_register_marshaller (_thunar_marshal_VOID__UINT_POINTER_UINT_STRING,
-                                             G_TYPE_NONE,
-                                             G_TYPE_UINT, 
-                                             G_TYPE_STRV, 
-                                             G_TYPE_UINT, 
-                                             G_TYPE_STRING,
-                                             G_TYPE_INVALID);
+      thumbnailer->thumbnailer_proxy = thunar_thumbnailer_proxy;
 
-          dbus_g_object_register_marshaller ((GClosureMarshal) g_cclosure_marshal_VOID__POINTER,
-                                             G_TYPE_NONE,
-                                             G_TYPE_STRV,
-                                             G_TYPE_INVALID);
+      /* TODO this should actually be VOID:UINT,POINTER,INT,STRING */
+      dbus_g_object_register_marshaller (_thunar_marshal_VOID__UINT_POINTER_UINT_STRING,
+                                         G_TYPE_NONE,
+                                         G_TYPE_UINT, 
+                                         G_TYPE_STRV, 
+                                         G_TYPE_UINT, 
+                                         G_TYPE_STRING,
+                                         G_TYPE_INVALID);
 
-          dbus_g_proxy_add_signal (thumbnailer->thumbnailer_proxy, "Error", 
-                                   G_TYPE_UINT, G_TYPE_STRV, G_TYPE_UINT, G_TYPE_STRING, 
-                                   G_TYPE_INVALID);
+      dbus_g_object_register_marshaller ((GClosureMarshal) g_cclosure_marshal_VOID__POINTER,
+                                         G_TYPE_NONE,
+                                         G_TYPE_STRV,
+                                         G_TYPE_INVALID);
 
-          dbus_g_proxy_add_signal (thumbnailer->thumbnailer_proxy, "Finished", 
-                                   G_TYPE_UINT, G_TYPE_INVALID);
+      dbus_g_proxy_add_signal (thumbnailer->thumbnailer_proxy, "Error", 
+                               G_TYPE_UINT, G_TYPE_STRV, G_TYPE_UINT, G_TYPE_STRING, 
+                               G_TYPE_INVALID);
+      dbus_g_proxy_add_signal (thumbnailer->thumbnailer_proxy, "Finished", 
+                               G_TYPE_UINT, G_TYPE_INVALID);
+      dbus_g_proxy_add_signal (thumbnailer->thumbnailer_proxy, "Ready", 
+                               G_TYPE_STRV, G_TYPE_INVALID);
+      dbus_g_proxy_add_signal (thumbnailer->thumbnailer_proxy, "Started", 
+                               G_TYPE_UINT, G_TYPE_INVALID);
+    }
+  else
+    {
+      thumbnailer->thumbnailer_proxy = g_object_ref (thunar_thumbnailer_proxy);
+    }
 
-          dbus_g_proxy_add_signal (thumbnailer->thumbnailer_proxy, "Ready", 
-                                   G_TYPE_STRV, G_TYPE_INVALID);
+  dbus_g_proxy_connect_signal (thumbnailer->thumbnailer_proxy, "Error",
+                               G_CALLBACK (thunar_thumbnailer_thumbnailer_error), 
+                               thumbnailer, NULL);
+  dbus_g_proxy_connect_signal (thumbnailer->thumbnailer_proxy, "Finished",
+                               G_CALLBACK (thunar_thumbnailer_thumbnailer_finished), 
+                               thumbnailer, NULL);
+  dbus_g_proxy_connect_signal (thumbnailer->thumbnailer_proxy, "Ready",
+                               G_CALLBACK (thunar_thumbnailer_thumbnailer_ready), 
+                               thumbnailer, NULL);
+  dbus_g_proxy_connect_signal (thumbnailer->thumbnailer_proxy, "Started", 
+                               G_CALLBACK (thunar_thumbnailer_thumbnailer_started), 
+                               thumbnailer, NULL);
+}
 
-          dbus_g_proxy_add_signal (thumbnailer->thumbnailer_proxy, "Started", 
-                                   G_TYPE_UINT, G_TYPE_INVALID);
-        }
-      else
-        {
-          thumbnailer->thumbnailer_proxy = g_object_ref (thunar_thumbnailer_proxy);
-        }
 
-      dbus_g_proxy_connect_signal (thumbnailer->thumbnailer_proxy, "Error",
-                                   G_CALLBACK (thunar_thumbnailer_thumbnailer_error), 
-                                   thumbnailer, NULL);
 
-      dbus_g_proxy_connect_signal (thumbnailer->thumbnailer_proxy, "Finished",
-                                   G_CALLBACK (thunar_thumbnailer_thumbnailer_finished), 
-                                   thumbnailer, NULL);
+static void
+thunar_thumbnailer_init_manager_proxy (ThunarThumbnailer *thumbnailer,
+                                       DBusGConnection   *connection)
+{
+  if (connection == NULL)
+    {
+      thumbnailer->manager_proxy = NULL;
+      return;
+    }
 
-      dbus_g_proxy_connect_signal (thumbnailer->thumbnailer_proxy, "Ready",
-                                   G_CALLBACK (thunar_thumbnailer_thumbnailer_ready), 
-                                   thumbnailer, NULL);
+  if (thunar_manager_proxy == NULL)
+    {
+      thunar_thumbnailer_manager_proxy = 
+        dbus_g_proxy_new_for_name (connection, 
+                                   "org.freedesktop.thumbnails.Manager",
+                                   "/org/freedesktop/thumbnails/Manager",
+                                   "org.freedesktop.thumbnails.Manager");
 
-      dbus_g_proxy_connect_signal (thumbnailer->thumbnailer_proxy, "Started", 
-                                   G_CALLBACK (thunar_thumbnailer_thumbnailer_started), 
-                                   thumbnailer, NULL);
+      g_object_add_weak_pointer (G_OBJECT (thunar_thumbnailer_manager_proxy),
+                                 (gpointer) &thunar_thumbnailer_manager_proxy);
 
-      dbus_g_connection_unref (connection);
+      thumbnailer->manager_proxy = thunar_thumbnailer_manager_proxy;
     }
+  else
+    {
+      thumbnailer->manager_proxy = g_object_ref (thunar_thumbnailer_manager_proxy);
+    }
 }
 
 
@@ -242,6 +293,8 @@
       g_object_unref (thumbnailer->thumbnailer_proxy);
     }
 
+  g_strfreev (thumbnailer->supported_types);
+
   /* release the thumbnailer lock */
   g_mutex_unlock (thumbnailer->lock);
 
@@ -339,6 +392,7 @@
                                guint             *handle)
 {
   const gchar *mime_hints[2] = { NULL, NULL };
+  gboolean     supported = FALSE;
   gboolean     success = FALSE;
   gchar       *uris[2] = { NULL, NULL };
 
@@ -351,14 +405,21 @@
 
   if (thumbnailer->thumbnailer_proxy != NULL)
     {
-      uris[0] = thunar_file_dup_uri (file);
-      mime_hints[0] = thunar_file_get_content_type (file);
+      g_mutex_unlock (thumbnailer->lock);
+      supported = thunar_thumbnailer_file_is_supported (thumbnailer, file);
+      g_mutex_lock (thumbnailer->lock);
 
-      success =thunar_thumbnailer_proxy_queue (thumbnailer->thumbnailer_proxy,
-                                               (const gchar **)uris, 
-                                               mime_hints, 0, handle, NULL);
+      if (supported)
+        {
+          uris[0] = thunar_file_dup_uri (file);
+          mime_hints[0] = thunar_file_get_content_type (file);
 
-      g_free (uris[0]);
+          success =thunar_thumbnailer_proxy_queue (thumbnailer->thumbnailer_proxy,
+                                                   (const gchar **)uris, 
+                                                   mime_hints, 0, handle, NULL);
+
+          g_free (uris[0]);
+        }
     }
 
   /* release the thumbnailer lock */
@@ -377,6 +438,7 @@
   const gchar **mime_hints;
   gboolean      success = FALSE;
   GList        *lp;
+  GList        *supported_files = NULL;
   gchar       **uris;
   guint         n;
 
@@ -389,24 +451,37 @@
 
   if (thumbnailer->thumbnailer_proxy != NULL)
     {
-      uris = g_new0 (gchar *, g_list_length (files) + 1);
-      mime_hints = g_new0 (const gchar *, g_list_length (files) + 1);
+      g_mutex_unlock (thumbnailer->lock);
 
-      for (lp = g_list_last (files), n = 0; lp != NULL; lp = lp->prev, ++n)
+      for (lp = g_list_last (files); lp != NULL; lp = lp->prev)
+        if (thunar_thumbnailer_file_is_supported (thumbnailer, lp->data))
+          supported_files = g_list_prepend (supported_files, lp->data);
+
+      g_mutex_lock (thumbnailer->lock);
+
+      if (supported_files != NULL)
         {
-          uris[n] = thunar_file_dup_uri (lp->data);
-          mime_hints[n] = thunar_file_get_content_type (lp->data);
-        }
+          uris = g_new0 (gchar *, g_list_length (supported_files) + 1);
+          mime_hints = g_new0 (const gchar *, g_list_length (supported_files) + 1);
 
-      uris[n] = NULL;
-      mime_hints[n] = NULL;
-          
-      success = thunar_thumbnailer_proxy_queue (thumbnailer->thumbnailer_proxy, 
-                                                (const gchar **)uris, mime_hints, 
-                                                0, handle, NULL);
+          for (lp = supported_files, n = 0; lp != NULL; lp = lp->next, ++n)
+            {
+              uris[n] = thunar_file_dup_uri (lp->data);
+              mime_hints[n] = thunar_file_get_content_type (lp->data);
+            }
 
-      g_strfreev (uris);
-      g_free (mime_hints);
+          uris[n] = NULL;
+          mime_hints[n] = NULL;
+
+          g_list_free (supported_files);
+              
+          success = thunar_thumbnailer_proxy_queue (thumbnailer->thumbnailer_proxy, 
+                                                    (const gchar **)uris, mime_hints, 
+                                                    0, handle, NULL);
+
+          g_strfreev (uris);
+          g_free (mime_hints);
+        }
     }
 
   /* release the thumbnailer lock */
@@ -432,3 +507,50 @@
   /* release the thumbnailer lock */
   g_mutex_unlock (thumbnailer->lock);
 }
+
+
+
+gboolean
+thunar_thumbnailer_file_is_supported (ThunarThumbnailer *thumbnailer,
+                                      ThunarFile        *file)
+{
+  const gchar *content_type;
+  gboolean     supported = FALSE;
+  guint        n;
+
+  _thunar_return_val_if_fail (THUNAR_IS_THUMBNAILER (thumbnailer), FALSE);
+  _thunar_return_val_if_fail (THUNAR_IS_FILE (file), FALSE);
+
+  /* acquire the thumbnailer lock */
+  g_mutex_lock (thumbnailer->lock);
+
+  if (thumbnailer->manager_proxy == NULL)
+    {
+      /* release the thumbnailer lock */
+      g_mutex_unlock (thumbnailer->lock);
+      return TRUE;
+    }
+
+  if (thumbnailer->supported_types == NULL)
+    {
+      thunar_thumbnailer_manager_proxy_get_supported (thumbnailer->manager_proxy,
+                                                      &thumbnailer->supported_types, 
+                                                      NULL);
+    }
+
+  if (thumbnailer->supported_types != NULL)
+    {
+      for (n = 0; !supported && thumbnailer->supported_types[n] != NULL; ++n)
+        {
+          content_type = thunar_file_get_content_type (file);
+
+          if (g_content_type_is_a (content_type, thumbnailer->supported_types[n]))
+            supported = TRUE;
+        }
+    }
+
+  /* release the thumbnailer lock */
+  g_mutex_unlock (thumbnailer->lock);
+
+  return supported;
+}

Modified: thunar/branches/migration-to-gio/thunar/thunar-thumbnailer.h
===================================================================
--- thunar/branches/migration-to-gio/thunar/thunar-thumbnailer.h	2009-06-12 00:21:23 UTC (rev 30001)
+++ thunar/branches/migration-to-gio/thunar/thunar-thumbnailer.h	2009-06-12 01:09:47 UTC (rev 30002)
@@ -34,18 +34,20 @@
 #define THUNAR_IS_THUMBNAILER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), THUNAR_TYPE_THUMBNAILER))
 #define THUNAR_THUMBNAILER_GET_CLASS(obj)  (G_TYPE_INSTANCE_GET_CLASS ((obj), THUNAR_TYPE_THUMBNAILER, ThunarThumbnailerClass))
 
-GType              thunar_thumbnailer_get_type    (void) G_GNUC_CONST;
+GType              thunar_thumbnailer_get_type          (void) G_GNUC_CONST;
 
-ThunarThumbnailer *thunar_thumbnailer_new         (void) G_GNUC_MALLOC;
+ThunarThumbnailer *thunar_thumbnailer_new               (void) G_GNUC_MALLOC;
 
-gboolean           thunar_thumbnailer_queue_file  (ThunarThumbnailer *generator,
-                                                   ThunarFile        *file,
-                                                   guint             *handle);
-gboolean           thunar_thumbnailer_queue_files (ThunarThumbnailer *generator,
-                                                   GList             *files,
-                                                   guint             *handle);
-void               thunar_thumbnailer_unqueue     (ThunarThumbnailer *thumbnailer,
-                                                   guint              handle);
+gboolean           thunar_thumbnailer_queue_file        (ThunarThumbnailer *generator,
+                                                         ThunarFile        *file,
+                                                         guint             *handle);
+gboolean           thunar_thumbnailer_queue_files       (ThunarThumbnailer *generator,
+                                                         GList             *files,
+                                                         guint             *handle);
+void               thunar_thumbnailer_unqueue           (ThunarThumbnailer *thumbnailer,
+                                                         guint              handle);
+gboolean           thunar_thumbnailer_file_is_supported (ThunarThumbnailer *thumbnailer,
+                                                         ThunarFile        *file);
 
 G_END_DECLS;
 




More information about the Xfce4-commits mailing list