[gimp] libgimp, libgimpbase: rename gimp_base_compat_enum_init()



commit d14f6647ad4a6d1360efd043b5bd611300036d08
Author: Michael Natterer <mitch gimp org>
Date:   Sun Oct 29 18:37:18 2017 +0100

    libgimp, libgimpbase: rename gimp_base_compat_enum_init()
    
    to gimp_base_compat_enums_init() and move its prototype from
    gimputils.h to gimpbase-private.h; it's not supposed to be
    public API even though it's callable from the outside.

 libgimp/Makefile.am            |    2 +-
 libgimp/gimpenums.c.tail       |    2 +-
 libgimpbase/gimpbase-private.c |    5 ++---
 libgimpbase/gimpbase-private.h |    3 ++-
 libgimpbase/gimpbase.def       |    2 +-
 libgimpbase/gimputils.h        |    2 --
 tools/pdbgen/enumcode.pl       |    2 +-
 7 files changed, 8 insertions(+), 10 deletions(-)
---
diff --git a/libgimp/Makefile.am b/libgimp/Makefile.am
index 6fd9c9b..9049944 100644
--- a/libgimp/Makefile.am
+++ b/libgimp/Makefile.am
@@ -445,7 +445,7 @@ CLEANFILES = $(gen_sources)
 
 gimpenums.c: $(srcdir)/gimpenums.h $(srcdir)/gimpenums.c.tail $(GIMP_MKENUMS) Makefile.am
        $(AM_V_GEN) $(GIMP_MKENUMS) \
-               --fhead "#include \"config.h\"\n#include <gio/gio.h>\n#undef 
GIMP_DISABLE_DEPRECATED\n#include \"libgimpbase/gimpbase.h\"\n#include 
\"libgimpconfig/gimpconfigenums.h\"\n#include \"gimpenums.h\"" \
+               --fhead "#include \"config.h\"\n#include <gio/gio.h>\n#undef 
GIMP_DISABLE_DEPRECATED\n#include \"libgimpbase/gimpbase.h\"\n#include 
\"libgimpbase/gimpbase-private.h\"\n#include \"libgimpconfig/gimpconfigenums.h\"\n#include \"gimpenums.h\"" \
                --fprod "\n/* enumerations from \"@filename@\" */" \
                --vhead "GType\n@enum_name@_get_type (void)\n{\n  static const G@Type@Value values[] =\n  {" \
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
diff --git a/libgimp/gimpenums.c.tail b/libgimp/gimpenums.c.tail
index 45ea762..ac40359 100644
--- a/libgimp/gimpenums.c.tail
+++ b/libgimp/gimpenums.c.tail
@@ -174,7 +174,7 @@ gimp_enums_init (void)
   g_type_set_qdata (GIMP_TYPE_LAYER_MODE, quark,
                    (gpointer) gimp_layer_mode_effects_get_type ());
 
-  gimp_base_compat_enum_init ();
+  gimp_base_compat_enums_init ();
 
   enums_initialized = TRUE;
 }
diff --git a/libgimpbase/gimpbase-private.c b/libgimpbase/gimpbase-private.c
index 5e27152..a5ad747 100644
--- a/libgimpbase/gimpbase-private.c
+++ b/libgimpbase/gimpbase-private.c
@@ -27,7 +27,6 @@
 
 #include "gimpbase-private.h"
 #include "gimpcompatenums.h"
-#include "gimputils.h"
 
 
 GimpUnitVtable _gimp_unit_vtable = { NULL, };
@@ -45,13 +44,13 @@ gimp_base_init (GimpUnitVtable *vtable)
 
   _gimp_unit_vtable = *vtable;
 
-  gimp_base_compat_enum_init ();
+  gimp_base_compat_enums_init ();
 
   gimp_base_initialized = TRUE;
 }
 
 void
-gimp_base_compat_enum_init (void)
+gimp_base_compat_enums_init (void)
 {
   static gboolean gimp_base_compat_initialized = FALSE;
   GQuark          quark;
diff --git a/libgimpbase/gimpbase-private.h b/libgimpbase/gimpbase-private.h
index 9caf7fb..6b11ebc 100644
--- a/libgimpbase/gimpbase-private.h
+++ b/libgimpbase/gimpbase-private.h
@@ -61,7 +61,8 @@ extern GimpUnitVtable _gimp_unit_vtable;
 
 G_BEGIN_DECLS
 
-void  gimp_base_init (GimpUnitVtable *vtable);
+void   gimp_base_init              (GimpUnitVtable *vtable);
+void   gimp_base_compat_enums_init (void);
 
 G_END_DECLS
 
diff --git a/libgimpbase/gimpbase.def b/libgimpbase/gimpbase.def
index 26b75be..f230293 100644
--- a/libgimpbase/gimpbase.def
+++ b/libgimpbase/gimpbase.def
@@ -2,7 +2,7 @@ EXPORTS
        gimp_add_mask_type_compat_get_type
        gimp_add_mask_type_get_type
        gimp_any_to_utf8
-       gimp_base_compat_enum_init
+       gimp_base_compat_enums_init
        gimp_base_init
        gimp_blend_mode_compat_get_type
        gimp_blend_mode_get_type
diff --git a/libgimpbase/gimputils.h b/libgimpbase/gimputils.h
index a877472..c7cea29 100644
--- a/libgimpbase/gimputils.h
+++ b/libgimpbase/gimputils.h
@@ -70,8 +70,6 @@ const gchar   * gimp_flags_value_get_desc      (GFlagsClass  *flags_class,
                                                 GFlagsValue  *flags_value);
 const gchar   * gimp_flags_value_get_help      (GFlagsClass  *flags_class,
                                                 GFlagsValue  *flags_value);
-void            gimp_base_compat_enum_init     (void);
-
 
 
 G_END_DECLS
diff --git a/tools/pdbgen/enumcode.pl b/tools/pdbgen/enumcode.pl
index 600ca3e..dc9fff6 100755
--- a/tools/pdbgen/enumcode.pl
+++ b/tools/pdbgen/enumcode.pl
@@ -201,7 +201,7 @@ gimp_enums_init (void)
   g_type_set_qdata (GIMP_TYPE_LAYER_MODE, quark,
                    (gpointer) gimp_layer_mode_effects_get_type ());
 
-  gimp_base_compat_enum_init ();
+  gimp_base_compat_enums_init ();
 
   enums_initialized = TRUE;
 }


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