[gnome-control-center] shell: ensure translations are enabled
- From: Thomas Wood <thos src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-control-center] shell: ensure translations are enabled
- Date: Mon, 24 May 2010 22:21:56 +0000 (UTC)
commit 8a9c632975afbe64ffdabc20c43a2b356724415b
Author: Thomas Wood <thomas wood intel com>
Date: Mon May 24 22:48:34 2010 +0100
shell: ensure translations are enabled
Make sure gettext is initialised correctly and make sure strings in the
GtkBuilder file are marked for translation.
shell/control-center.c | 8 ++++++++
shell/shell.ui | 2 +-
2 files changed, 9 insertions(+), 1 deletions(-)
---
diff --git a/shell/control-center.c b/shell/control-center.c
index e000058..1451e0a 100644
--- a/shell/control-center.c
+++ b/shell/control-center.c
@@ -21,6 +21,8 @@
#include "config.h"
+#include <glib/gi18n.h>
+
#include "gnome-control-center.h"
#include <gtk/gtk.h>
@@ -75,9 +77,15 @@ main (int argc, char **argv)
GnomeControlCenter *shell;
UniqueApp *unique;
+ bindtextdomain (GETTEXT_PACKAGE, GNOMELOCALEDIR);
+ bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
+ textdomain (GETTEXT_PACKAGE);
+
+
g_thread_init (NULL);
gtk_init (&argc, &argv);
+
/* use Unique to enforce single instance of this application */
unique = unique_app_new_with_commands ("org.gnome.ControlCenter",
NULL,
diff --git a/shell/shell.ui b/shell/shell.ui
index 57ce5f9..3bbb891 100644
--- a/shell/shell.ui
+++ b/shell/shell.ui
@@ -23,7 +23,7 @@
<property name="border_width">5</property>
<child>
<object class="GtkButton" id="home-button">
- <property name="label">_All Settings</property>
+ <property name="label" translatable="yes">_All Settings</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="no_show_all">True</property>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]