[gimp/gtk3-port] SQUASH INTO 36b4fa31d0bf99b61c80862cdba9132ade9a32e0



commit 55f80a55b3986685563ec6d798564047bfffceaa
Author: Michael Natterer <mitch gimp org>
Date:   Sun May 6 21:13:14 2018 +0200

    SQUASH INTO 36b4fa31d0bf99b61c80862cdba9132ade9a32e0

 app/core/gimp-modules.c      |    6 +-----
 libgimpmodule/gimpmoduledb.c |   36 ++++++++++++++++++++++++++++++++++++
 libgimpmodule/gimpmoduledb.h |    4 ++++
 3 files changed, 41 insertions(+), 5 deletions(-)
---
diff --git a/app/core/gimp-modules.c b/app/core/gimp-modules.c
index a733919..6a7fb3e 100644
--- a/app/core/gimp-modules.c
+++ b/app/core/gimp-modules.c
@@ -68,11 +68,7 @@ gimp_modules_load (Gimp *gimp)
   if (gimp->no_interface)
     return;
 
-#warning "this is a quick fix to get gimp to compile again"
-#if 0
-  /* FIXME, gimp->be_verbose is not yet initialized in init() */
-  gimp->module_db->verbose = gimp->be_verbose;
-#endif
+  gimp_module_db_set_verbose (gimp->module_db, gimp->be_verbose);
 
   file = gimp_directory_file ("modulerc", NULL);
 
diff --git a/libgimpmodule/gimpmoduledb.c b/libgimpmodule/gimpmoduledb.c
index b1e3b4e..e6bed3a 100644
--- a/libgimpmodule/gimpmoduledb.c
+++ b/libgimpmodule/gimpmoduledb.c
@@ -211,6 +211,42 @@ gimp_module_db_get_modules (GimpModuleDB *db)
   return GET_PRIVATE (db)->modules;
 }
 
+/**
+ * gimp_module_db_set_verbose:
+ * @db:      A #GimpModuleDB.
+ * @verbose: the new 'verbose' setting
+ *
+ * Sets the 'verbose' setting of @db.
+ *
+ * Since: 3.0
+ **/
+void
+gimp_module_db_set_verbose (GimpModuleDB *db,
+                            gboolean      verbose)
+{
+  g_return_if_fail (GIMP_IS_MODULE_DB (db));
+
+  GET_PRIVATE (db)->verbose = verbose ? TRUE : FALSE;
+}
+
+/**
+ * gimp_module_db_get_verbose:
+ * @db: A #GimpModuleDB.
+ *
+ * Returns the 'verbose' setting of @db.
+ *
+ * Return value: the 'verbose' setting.
+ *
+ * Since: 3.0
+ **/
+gboolean
+gimp_module_db_get_verbose (GimpModuleDB *db)
+{
+  g_return_val_if_fail (GIMP_IS_MODULE_DB (db), FALSE);
+
+  return GET_PRIVATE (db)->verbose;
+}
+
 static gboolean
 is_in_inhibit_list (const gchar *filename,
                     const gchar *inhibit_list)
diff --git a/libgimpmodule/gimpmoduledb.h b/libgimpmodule/gimpmoduledb.h
index 5654363..3e82775 100644
--- a/libgimpmodule/gimpmoduledb.h
+++ b/libgimpmodule/gimpmoduledb.h
@@ -72,6 +72,10 @@ GimpModuleDB * gimp_module_db_new              (gboolean      verbose);
 
 GList        * gimp_module_db_get_modules      (GimpModuleDB *db);
 
+void           gimp_module_db_set_verbose      (GimpModuleDB *db,
+                                                gboolean      verbose);
+gboolean       gimp_module_db_get_verbose      (GimpModuleDB *db);
+
 void           gimp_module_db_set_load_inhibit (GimpModuleDB *db,
                                                 const gchar  *load_inhibit);
 const gchar  * gimp_module_db_get_load_inhibit (GimpModuleDB *db);


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