[network-manager-vpnc/NM_0_8] ui: fix gtk_builder_set_translation_domain() calling
- From: Dan Williams <dcbw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [network-manager-vpnc/NM_0_8] ui: fix gtk_builder_set_translation_domain() calling
- Date: Fri, 19 Aug 2011 20:49:33 +0000 (UTC)
commit ec17645cb11a7c84739107a57e01b4a3c06778d9
Author: Ozan ÃaÄlayan <ozan pardus org tr>
Date: Wed Aug 17 14:31:00 2011 +0300
ui: fix gtk_builder_set_translation_domain() calling
gtk_builder_set_translation_domain() should be called before
gtk_builder_add_from_file(). This fixes UI messages always in English
problem.
properties/nm-vpnc.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/properties/nm-vpnc.c b/properties/nm-vpnc.c
index 32f1e60..1393d34 100644
--- a/properties/nm-vpnc.c
+++ b/properties/nm-vpnc.c
@@ -986,6 +986,8 @@ nm_vpn_plugin_ui_widget_interface_new (NMConnection *connection, GError **error)
ui_file = g_strdup_printf ("%s/%s", UIDIR, "nm-vpnc-dialog.ui");
priv->builder = gtk_builder_new ();
+ gtk_builder_set_translation_domain (priv->builder, GETTEXT_PACKAGE);
+
if (!gtk_builder_add_from_file (priv->builder, ui_file, error)) {
g_warning ("Couldn't load builder file: %s",
error && *error ? (*error)->message : "(unknown)");
@@ -998,8 +1000,6 @@ nm_vpn_plugin_ui_widget_interface_new (NMConnection *connection, GError **error)
}
g_free (ui_file);
- gtk_builder_set_translation_domain (priv->builder, GETTEXT_PACKAGE);
-
priv->widget = GTK_WIDGET (gtk_builder_get_object (priv->builder, "vpnc-vbox"));
if (!priv->widget) {
g_set_error (error, VPNC_PLUGIN_UI_ERROR, 0, "could not load UI widget");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]