Updating branch refs/heads/stephan/gtk3
         to 34b853c61739c2c626020b80cb0db4307e74fb38 (commit)
       from 939d11425642cab7c6222de31c2dda2e731664ac (commit)

commit 34b853c61739c2c626020b80cb0db4307e74fb38
Author: Nick Schermer <n...@xfce.org>
Date:   Sat May 5 16:28:10 2012 +0200

    Remove the exo-gio-modules.
    
    Not required now we always use glib >= 2.30.

 Makefile.am                 |    5 +-
 configure.in.in             |    9 --
 exo-gio-module/Makefile.am  |   50 -----------
 exo-gio-module/exo-module.c |  198 -------------------------------------------
 4 files changed, 1 insertions(+), 261 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index 0ab3853..572e111 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -2,7 +2,6 @@ SUBDIRS =                                                       
        \
        exo                                                             \
        exo-csource                                                     \
        exo-desktop-item-edit                                           \
-       exo-gio-module                                                  \
        exo-helper                                                      \
        exo-open                                                        \
        docs                                                            \
@@ -52,8 +51,6 @@ DISTCLEANFILES =                                              
        \
        intltool-update
 
 DISTCHECK_CONFIGURE_FLAGS =                                            \
-       --enable-gtk-doc                                                \
-       --enable-gen-doc                                                \
-       --with-gio-module-dir=distcheck
+       --enable-gtk-doc
 
 # vi:set ts=8 sw=8 noet ai nocindent:
diff --git a/configure.in.in b/configure.in.in
index ab56027..acea09f 100644
--- a/configure.in.in
+++ b/configure.in.in
@@ -234,7 +234,6 @@ exo/exo-1.pc
 exo/exo-config.h
 exo-csource/Makefile
 exo-desktop-item-edit/Makefile
-exo-gio-module/Makefile
 exo-helper/Makefile
 exo-helper/helpers/Makefile
 exo-open/Makefile
@@ -253,14 +252,6 @@ dnl ***************************
 echo
 echo "Build Configuration:"
 echo
-if test x"$BUILD_GIOMODULE" = x"no"; then
-echo "* Build GIO module:     no (not needed after glib 2.27)"
-elif test x"$GIO_UNIX_FOUND" = x"yes"; then
-echo "* Build GIO module:     yes"
-echo "  - GIO Module Dir:     $GIOMODULEDIR"
-else
-echo "* Build GIO module:     no"
-fi
 echo "* Debug Support:        $enable_debug"
 echo "* GNU Visibility:       $have_gnuc_visibility"
 echo
diff --git a/exo-gio-module/Makefile.am b/exo-gio-module/Makefile.am
deleted file mode 100644
index b0a9946..0000000
--- a/exo-gio-module/Makefile.am
+++ /dev/null
@@ -1,50 +0,0 @@
-
-INCLUDES =                                                             \
-       -I$(top_srcdir)                                                 \
-       -DG_LOG_DOMAIN=\"exo-gio-module\"                               \
-       -DHELPERDIR=\"$(HELPER_PATH_PREFIX)/xfce4/exo-$(LIBEXO_VERSION_API)\"   
\
-       -DPACKAGE_LOCALE_DIR=\"$(localedir)\"                           \
-       -DLIBEXO_VERSION_API=\"$(LIBEXO_VERSION_API)\"
-
-if BUILD_GIOMODULE
-
-if HAVE_GIOMODULEDIR
-exomoduledir =                                                         \
-       $(GIOMODULEDIR)
-else
-exomoduledir =                                                         \
-       $(libdir)/gio/modules
-endif
-
-exomodule_LTLIBRARIES =                                                        
\
-       libexo-module-1.la
-
-libexo_module_1_la_SOURCES =                                           \
-       exo-module.c
-
-libexo_module_1_la_CFLAGS =                                            \
-       $(GIO_CFLAGS)                                                   \
-       $(GIO_UNIX_CFLAGS) \
-       $(GTK_CFLAGS)                                                   \
-       $(LIBXFCE4UTIL_CFLAGS)
-
-libexo_module_1_la_LDFLAGS =                                           \
-       -export_dynamic                                                 \
-       -avoid-version                                                  \
-       -module                                                         \
-       -no-undefined                                                   \
-       -export-symbols-regex '^g_io_module_(load|unload|query)'
-
-libexo_module_1_la_DEPENDENCIES =                                      \
-       $(top_builddir)/exo/libexo-$(LIBEXO_VERSION_API).la
-
-libexo_module_1_la_LIBADD =                                            \
-       $(GIO_LIBS)                                                     \
-       $(GIO_UNIX_LIBS) \
-       $(GTK_LIBS)                                                     \
-       $(LIBXFCE4UTIL_LIBS)                                            \
-       $(top_builddir)/exo/libexo-$(LIBEXO_VERSION_API).la
-
-endif
-
-# vi:set ts=8 sw=8 noet ai nocindent syntax=automake:
diff --git a/exo-gio-module/exo-module.c b/exo-gio-module/exo-module.c
deleted file mode 100644
index 638cf67..0000000
--- a/exo-gio-module/exo-module.c
+++ /dev/null
@@ -1,198 +0,0 @@
-/*
- * Copyright (c) 2009 Nick Schermer <n...@xfce.org>.
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library 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
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301 USA
- */
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <exo/exo.h>
-#include <gio/gio.h>
-#include <gio/gdesktopappinfo.h>
-
-#define EXO_HELPER_LAUNCH HELPERDIR G_DIR_SEPARATOR_S "exo-helper-" 
LIBEXO_VERSION_API " --launch "
-
-
-
-
-#define EXO_TYPE_GIO_MODULE        (exo_gio_module_get_type ())
-#define EXO_GIO_MODULE(o)          (G_TYPE_CHECK_INSTANCE_CAST ((o), 
G_TYPE_GIO_MODULE, ExoGioModule))
-#define EXO_GIO_MODULE_CLASS(k)    (G_TYPE_CHECK_CLASS_CAST ((k), 
G_TYPE_GIO_MODULE, ExoGioModuleClass))
-#define EXO_IS_GIO_MODULE(o)       (G_TYPE_CHECK_INSTANCE_TYPE ((o), 
G_TYPE_GIO_MODULE))
-#define EXO_IS_GIO_MODULE_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), 
G_TYPE_GIO_MODULE))
-
-
-
-GType            exo_gio_module_get_type                   (void);
-static void      exo_gio_module_app_info_lookup_iface_init 
(GDesktopAppInfoLookupIface *iface);
-static GAppInfo *exo_gio_module_get_default_for_uri_scheme 
(GDesktopAppInfoLookup      *lookup,
-                                                            const gchar        
        *uri_scheme);
-
-
-
-typedef struct _ExoGioModuleClass ExoGioModuleClass;
-typedef struct _ExoGioModule      ExoGioModule;
-typedef struct _KnownSchemes      KnownSchemes;
-
-struct _ExoGioModuleClass
-{
-  GObjectClass __parent__;
-};
-
-struct _ExoGioModule
-{
-  GObject __parent__;
-};
-
-struct _KnownSchemes
-{
-  const gchar *pattern;
-  const gchar *category;
-  const gchar *app_name; /* name of the desktop files we use after gio 2.27 
for thunar */
-};
-
-static KnownSchemes known_schemes[] =
-{
-  { "^(https?|ftps?|gopher)$", "WebBrowser",  "exo-web-browser" },
-  { "^mailto$",                "MailReader",  "exo-mail-reader" },
-  { "^(file|trash|ssh)$",      "FileManager", "exo-file-manager" }
-};
-
-
-
-#define _G_IMPLEMENT_INTERFACE_DYNAMIC(TYPE_IFACE, iface_init) \
-{ \
-  const GInterfaceInfo g_implement_interface_info = { \
-    (GInterfaceInitFunc) iface_init, NULL, NULL \
-  }; \
-  g_type_module_add_interface (type_module, g_define_type_id, \
-                               TYPE_IFACE, &g_implement_interface_info); \
-}
-
-
-
-G_DEFINE_DYNAMIC_TYPE_EXTENDED (ExoGioModule, exo_gio_module, G_TYPE_OBJECT, 0,
-    _G_IMPLEMENT_INTERFACE_DYNAMIC (G_TYPE_DESKTOP_APP_INFO_LOOKUP,
-                                    exo_gio_module_app_info_lookup_iface_init))
-
-
-
-static void
-exo_gio_module_class_init (ExoGioModuleClass *klass)
-{
-}
-
-
-
-static void
-exo_gio_module_init (ExoGioModule *module)
-{
-}
-
-
-
-static void
-exo_gio_module_class_finalize (ExoGioModuleClass *klass)
-{
-}
-
-
-
-static void
-exo_gio_module_app_info_lookup_iface_init (GDesktopAppInfoLookupIface *iface)
-{
-  iface->get_default_for_uri_scheme = 
exo_gio_module_get_default_for_uri_scheme;
-}
-
-
-
-static GAppInfo *
-exo_gio_module_get_default_for_uri_scheme (GDesktopAppInfoLookup *lookup,
-                                           const gchar           *uri_scheme)
-{
-  GAppInfo *info = NULL;
-  GError   *error = NULL;
-  gchar    *command;
-  gboolean  found;
-  guint     i;
-
-  /* do nothing when there is no scheme defined */
-  if (G_UNLIKELY (uri_scheme == NULL))
-    return NULL;
-
-  for (i = 0, found = FALSE; !found && i < G_N_ELEMENTS (known_schemes); i++)
-    {
-      /* see if the scheme matches */
-      found = g_regex_match_simple (known_schemes[i].pattern, uri_scheme, 
G_REGEX_CASELESS, 0);
-      if (found)
-        {
-          /* use the exo-helper directly here to avoid possible roundtrips 
with exo-open */
-          command = g_strconcat (EXO_HELPER_LAUNCH, known_schemes[i].category, 
NULL);
-          info = g_app_info_create_from_commandline (command, 
known_schemes[i].app_name, 
-                                                     
G_APP_INFO_CREATE_SUPPORTS_URIS, &error);
-          if (G_UNLIKELY (info == NULL))
-            {
-              /* show error */
-              g_critical ("Failed to create GAppInfo from \"%s\" for 
URI-scheme \"%s\": %s.",
-                          command, uri_scheme, error->message);
-              g_error_free (error);
-            }
-
-          /* cleanup */
-          g_free (command);
-        }
-    }
-
-#ifndef NDEBUG
-  /* print debug message if scheme is not recognized by exo */
-  if (!found)
-    g_debug ("Unknown URI-scheme \"%s\".", uri_scheme);
-#endif
-
-  return info;
-}
-
-
-
-G_MODULE_EXPORT void
-g_io_module_load (GIOModule *module)
-{
-  exo_gio_module_register_type (G_TYPE_MODULE (module));
-  g_io_extension_point_implement 
(G_DESKTOP_APP_INFO_LOOKUP_EXTENSION_POINT_NAME,
-                                  EXO_TYPE_GIO_MODULE, "ExoGioModule", 15);
-}
-
-
-
-G_MODULE_EXPORT void
-g_io_module_unload (GIOModule *module)
-{
-}
-
-
-#if GLIB_CHECK_VERSION (2, 24, 0)
-G_MODULE_EXPORT gchar **
-g_io_module_query (void)
-{
-  gchar *eps[] = {
-    G_DESKTOP_APP_INFO_LOOKUP_EXTENSION_POINT_NAME,
-    NULL
-  };
-  return g_strdupv (eps);
-}
-#endif
_______________________________________________
Xfce4-commits mailing list
Xfce4-commits@xfce.org
https://mail.xfce.org/mailman/listinfo/xfce4-commits

Reply via email to