? gnome-desktop-i18n.patch
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/gnome-desktop/libgnome-desktop/ChangeLog,v
retrieving revision 1.190
diff -u -p -r1.190 ChangeLog
--- ChangeLog	13 Apr 2005 08:49:38 -0000	1.190
+++ ChangeLog	29 Apr 2005 16:58:39 -0000
@@ -1,3 +1,10 @@
+2005-04-29  Frederic Crozat  <fcrozat@mandriva.com>
+
+	* gnome-desktop-item.c: (gnome_desktop_item_new):
+	* gnome-ditem-edit.c: (gnome_ditem_edit_class_init):
+	Initialize i18n before using it, remove textdomain
+	call, it is evil in a library.
+
 ==================== 2.10.1 ====================
 
 2005-04-13  Mark McLoughlin  <mark@skynet.ie>
Index: gnome-desktop-item.c
===================================================================
RCS file: /cvs/gnome/gnome-desktop/libgnome-desktop/gnome-desktop-item.c,v
retrieving revision 1.141
diff -u -p -r1.141 gnome-desktop-item.c
--- gnome-desktop-item.c	30 Jan 2005 17:17:49 -0000	1.141
+++ gnome-desktop-item.c	29 Apr 2005 16:58:39 -0000
@@ -38,7 +38,7 @@
 #include <unistd.h>
 #include <time.h>
 #include <string.h>
-#include <glib/gi18n.h>
+#include <glib/gi18n-lib.h>
 #include <libgnome/gnome-util.h>
 #include <libgnome/gnome-exec.h>
 #include <libgnome/gnome-url.h>
@@ -348,6 +348,17 @@ GnomeDesktopItem *
 gnome_desktop_item_new (void)
 {
 	GnomeDesktopItem *retval;
+
+	static gboolean _gnome_desktop_i18n_initialized = FALSE;
+
+	/* initialize i18n if needed */
+	if (!_gnome_desktop_i18n_initialized) {
+		bindtextdomain (GETTEXT_PACKAGE, GNOMELOCALEDIR);
+#    ifdef HAVE_BIND_TEXTDOMAIN_CODESET
+		bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
+#    endif
+		_gnome_desktop_i18n_initialized = TRUE;
+	}
 
 	retval = g_new0 (GnomeDesktopItem, 1);
 
Index: gnome-ditem-edit.c
===================================================================
RCS file: /cvs/gnome/gnome-desktop/libgnome-desktop/gnome-ditem-edit.c,v
retrieving revision 1.79
diff -u -p -r1.79 gnome-ditem-edit.c
--- gnome-ditem-edit.c	13 Apr 2005 07:40:05 -0000	1.79
+++ gnome-ditem-edit.c	29 Apr 2005 16:58:39 -0000
@@ -28,7 +28,7 @@
 #include <stdio.h>
 #include <ctype.h>
 #include <string.h>
-#include <glib/gi18n.h>
+#include <glib/gi18n-lib.h>
 #include <gtk/gtk.h>
 
 #include <libgnome/gnome-macros.h>
@@ -125,8 +125,9 @@ gnome_ditem_edit_class_init (GnomeDItemE
         gobject_class = (GObjectClass*) klass;
 
         bindtextdomain (GETTEXT_PACKAGE, GNOMELOCALEDIR);
+#    ifdef HAVE_BIND_TEXTDOMAIN_CODESET
         bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
-        textdomain (GETTEXT_PACKAGE);
+#    endif
 
         ditem_edit_signals[CHANGED] =
                 g_signal_new ("changed",
