gimp r25492 - in branches/gimp-2-4: . app/config
- From: neo svn gnome org
- To: svn-commits-list gnome org
- Subject: gimp r25492 - in branches/gimp-2-4: . app/config
- Date: Wed, 16 Apr 2008 11:36:58 +0100 (BST)
Author: neo
Date: Wed Apr 16 11:36:58 2008
New Revision: 25492
URL: http://svn.gnome.org/viewvc/gimp?rev=25492&view=rev
Log:
2008-04-16 Sven Neumann <sven gimp org>
Merged from trunk:
* app/config/test-config.c: initialize the units vtable in
libgimpbase instead of trying to override symbols from it.
Fixes bug #528160.
Modified:
branches/gimp-2-4/ChangeLog
branches/gimp-2-4/app/config/test-config.c
Modified: branches/gimp-2-4/app/config/test-config.c
==============================================================================
--- branches/gimp-2-4/app/config/test-config.c (original)
+++ branches/gimp-2-4/app/config/test-config.c Wed Apr 16 11:36:58 2008
@@ -27,6 +27,7 @@
#include <glib-object.h>
#include "libgimpbase/gimpbase.h"
+#include "libgimpbase/gimpbase-private.h"
#include "libgimpconfig/gimpconfig.h"
#include "core/core-types.h"
@@ -41,6 +42,8 @@
const gchar *value,
gpointer data);
+static void units_init (void);
+
int
main (int argc,
@@ -69,6 +72,8 @@
g_type_init ();
+ units_init ();
+
g_print ("\nTesting GimpConfig ...\n");
g_print (" Creating a new Grid object ...");
@@ -236,10 +241,10 @@
}
-/* some dummy funcs so we can properly link this beast */
+/* minimal dummy units implementation */
-const gchar *
-gimp_unit_get_identifier (GimpUnit unit)
+static const gchar *
+unit_get_identifier (GimpUnit unit)
{
switch (unit)
{
@@ -258,8 +263,19 @@
}
}
-gint
-gimp_unit_get_number_of_units (void)
+static gint
+unit_get_number_of_units (void)
{
return GIMP_UNIT_END;
}
+
+static void
+units_init (void)
+{
+ GimpUnitVtable vtable;
+
+ vtable.unit_get_number_of_units = unit_get_number_of_units;
+ vtable.unit_get_identifier = unit_get_identifier;
+
+ gimp_base_init (&vtable);
+}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]