diff options
author | Gabor Kelemen <kelemeng@gnome.hu> | 2012-05-03 03:31:41 +0800 |
---|---|---|
committer | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2012-05-03 17:50:07 +0800 |
commit | 9923159863e58051f64cc7a60b3fa16184526db8 (patch) | |
tree | 9b49946aab72391b6d306a1bfce34dbb2f42476c /src | |
parent | 5deac54272ed93cf9811af2dc79658b21bb8c705 (diff) | |
download | gsoc2013-empathy-9923159863e58051f64cc7a60b3fa16184526db8.tar gsoc2013-empathy-9923159863e58051f64cc7a60b3fa16184526db8.tar.gz gsoc2013-empathy-9923159863e58051f64cc7a60b3fa16184526db8.tar.bz2 gsoc2013-empathy-9923159863e58051f64cc7a60b3fa16184526db8.tar.lz gsoc2013-empathy-9923159863e58051f64cc7a60b3fa16184526db8.tar.xz gsoc2013-empathy-9923159863e58051f64cc7a60b3fa16184526db8.tar.zst gsoc2013-empathy-9923159863e58051f64cc7a60b3fa16184526db8.zip |
Fix localization of --help outputs and application names
https://bugzilla.gnome.org/show_bug.cgi?id=675246
Diffstat (limited to 'src')
-rw-r--r-- | src/empathy-accounts.c | 3 | ||||
-rw-r--r-- | src/empathy-call.c | 3 | ||||
-rw-r--r-- | src/empathy-chat.c | 1 | ||||
-rw-r--r-- | src/empathy-debugger.c | 4 | ||||
-rw-r--r-- | src/empathy.c | 3 |
5 files changed, 9 insertions, 5 deletions
diff --git a/src/empathy-accounts.c b/src/empathy-accounts.c index 7b2964c4b..8feb346e5 100644 --- a/src/empathy-accounts.c +++ b/src/empathy-accounts.c @@ -195,6 +195,7 @@ local_cmdline (GApplication *app, optcontext = g_option_context_new (N_("- Empathy Accounts")); g_option_context_add_group (optcontext, gtk_get_option_group (TRUE)); g_option_context_add_main_entries (optcontext, options, GETTEXT_PACKAGE); + g_option_context_set_translation_domain (optcontext, GETTEXT_PACKAGE); argv = *arguments; for (i = 0; argv[i] != NULL; i++) @@ -223,6 +224,7 @@ main (int argc, char *argv[]) gint retval; empathy_init (); + textdomain (GETTEXT_PACKAGE); gtk_init (&argc, &argv); empathy_gtk_init (); @@ -232,7 +234,6 @@ main (int argc, char *argv[]) /* Make empathy and empathy-accounts appear as the same app in gnome-shell */ gdk_set_program_class ("Empathy"); gtk_window_set_default_icon_name ("empathy"); - textdomain (GETTEXT_PACKAGE); app = gtk_application_new (EMPATHY_ACCOUNTS_DBUS_NAME, G_APPLICATION_HANDLES_COMMAND_LINE); diff --git a/src/empathy-call.c b/src/empathy-call.c index 5c3633be5..e19b1d05f 100644 --- a/src/empathy-call.c +++ b/src/empathy-call.c @@ -203,6 +203,7 @@ main (int argc, clutter_get_option_group_without_init ()); g_option_context_add_group (optcontext, gtk_clutter_get_option_group ()); g_option_context_add_main_entries (optcontext, options, GETTEXT_PACKAGE); + g_option_context_set_translation_domain (optcontext, GETTEXT_PACKAGE); if (!g_option_context_parse (optcontext, &argc, &argv, &error)) { g_print ("%s\nRun '%s --help' to see a full list of available command " @@ -217,12 +218,12 @@ main (int argc, clutter_gst_init (&argc, &argv); empathy_gtk_init (); + textdomain (GETTEXT_PACKAGE); g_set_application_name (_("Empathy Audio/Video Client")); /* Make empathy and empathy-call appear as the same app in gnome-shell */ gdk_set_program_class ("Empathy"); gtk_window_set_default_icon_name ("empathy"); - textdomain (GETTEXT_PACKAGE); gtk_settings = gtk_settings_get_default (); g_object_set (G_OBJECT (gtk_settings), "gtk-application-prefer-dark-theme", diff --git a/src/empathy-chat.c b/src/empathy-chat.c index 66ad346e7..3094b5137 100644 --- a/src/empathy-chat.c +++ b/src/empathy-chat.c @@ -106,6 +106,7 @@ main (int argc, optcontext = g_option_context_new (N_("- Empathy Chat Client")); g_option_context_add_group (optcontext, gtk_get_option_group (TRUE)); g_option_context_add_main_entries (optcontext, options, GETTEXT_PACKAGE); + g_option_context_set_translation_domain (optcontext, GETTEXT_PACKAGE); if (!g_option_context_parse (optcontext, &argc, &argv, &error)) { diff --git a/src/empathy-debugger.c b/src/empathy-debugger.c index c63a5b57b..d4ce3273a 100644 --- a/src/empathy-debugger.c +++ b/src/empathy-debugger.c @@ -74,7 +74,7 @@ command_line_cb (GApplication *application, optcontext = g_option_context_new (N_("- Empathy Debugger")); g_option_context_add_group (optcontext, gtk_get_option_group (TRUE)); g_option_context_add_main_entries (optcontext, options, GETTEXT_PACKAGE); - + g_option_context_set_translation_domain (optcontext, GETTEXT_PACKAGE); argv = g_application_command_line_get_arguments (command_line, &argc); if (!g_option_context_parse (optcontext, &argc, &argv, &error)) @@ -103,6 +103,7 @@ main (int argc, gtk_init (&argc, &argv); empathy_gtk_init (); + textdomain (GETTEXT_PACKAGE); app = gtk_application_new (EMPATHY_DEBUGGER_DBUS_NAME, G_APPLICATION_HANDLES_COMMAND_LINE); @@ -114,7 +115,6 @@ main (int argc, /* Make empathy and empathy-debugger appear as the same app in gnome-shell */ gdk_set_program_class ("Empathy"); gtk_window_set_default_icon_name ("empathy"); - textdomain (GETTEXT_PACKAGE); retval = g_application_run (G_APPLICATION (app), argc, argv); diff --git a/src/empathy.c b/src/empathy.c index 4db2cbb62..548a5e79f 100644 --- a/src/empathy.c +++ b/src/empathy.c @@ -439,6 +439,7 @@ empathy_app_local_command_line (GApplication *app, /* We create a group so that GOptionArgFuncs get the user data */ group = g_option_group_new ("empathy", NULL, NULL, app, NULL); + g_option_group_set_translation_domain (group, GETTEXT_PACKAGE); g_option_group_add_entries (group, options); optcontext = g_option_context_new (N_("- Empathy IM Client")); @@ -734,10 +735,10 @@ empathy_app_constructed (GObject *object) EmpathyApp *self = (EmpathyApp *) object; gboolean chatroom_manager_ready; + textdomain (GETTEXT_PACKAGE); g_set_application_name (_(PACKAGE_NAME)); gtk_window_set_default_icon_name ("empathy"); - textdomain (GETTEXT_PACKAGE); #ifdef ENABLE_DEBUG /* Set up debug sender */ |