[gtk+/parasite2: 25/38] Add private api to load a single module



commit e28cc6e684657b19f18114b5e9e2ab64c626a7bf
Author: Matthias Clasen <mclasen redhat com>
Date:   Tue May 6 22:19:12 2014 -0400

    Add private api to load a single module
    
    In the following commits, this function will be used to load the
    gtkparasite module.

 gtk/gtkmodules.c        |    7 +++++++
 gtk/gtkmodules.h        |    1 -
 gtk/gtkmodulesprivate.h |    1 +
 3 files changed, 8 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkmodules.c b/gtk/gtkmodules.c
index 640be7b..87883e9 100644
--- a/gtk/gtkmodules.c
+++ b/gtk/gtkmodules.c
@@ -600,3 +600,10 @@ _gtk_module_has_mixed_deps (GModule *module_to_check)
 
   return result;
 }
+
+void
+_gtk_modules_load_module (const gchar *name)
+{
+  /* We leak the ref */
+  g_slist_free (load_modules (name));
+}
diff --git a/gtk/gtkmodules.h b/gtk/gtkmodules.h
index 29409b7..b5a756e 100644
--- a/gtk/gtkmodules.h
+++ b/gtk/gtkmodules.h
@@ -49,7 +49,6 @@ typedef void     (*GtkModuleInitFunc)        (gint        *argc,
  */
 typedef void     (*GtkModuleDisplayInitFunc) (GdkDisplay   *display);
 
-
 G_END_DECLS
 
 
diff --git a/gtk/gtkmodulesprivate.h b/gtk/gtkmodulesprivate.h
index 11dbebf..34c3073 100644
--- a/gtk/gtkmodulesprivate.h
+++ b/gtk/gtkmodulesprivate.h
@@ -38,6 +38,7 @@ void     _gtk_modules_init             (gint          *argc,
                                         const gchar   *gtk_modules_args);
 void     _gtk_modules_settings_changed (GtkSettings   *settings,
                                         const gchar   *modules);
+void     _gtk_modules_load_module      (const gchar   *name);
 
 gboolean _gtk_module_has_mixed_deps    (GModule       *module);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]