From 837793b255d1b057d2144906b60f49c32ded8e20 Mon Sep 17 00:00:00 2001 From: Gabriel Burt Date: Sun, 7 Dec 2008 18:45:44 -0600 Subject: [PATCH] Set translation domain so translations actually used, improve the wording of a few things --- configure.ac | 5 ++++ po/ChangeLog | 4 +++ po/es.po | 78 +++++++++++++++++++++++++++++---------------------------- src/Makefile.am | 1 + src/sipe.c | 20 +++++++++++++-- 5 files changed, 68 insertions(+), 40 deletions(-) diff --git a/configure.ac b/configure.ac index 1479246f..7e9c9eef 100644 --- a/configure.ac +++ b/configure.ac @@ -103,6 +103,11 @@ AC_ARG_ENABLE(static-sipe, AM_CONDITIONAL(SIPE_STATIC, test $sipe_static = yes) +AC_MSG_CHECKING([locale_CPPFLAGS]) +LOCALE_CPPFLAGS='-DLOCALEDIR=\"$(prefix)/$(DATADIRNAME)/locale\"' +AC_SUBST([LOCALE_CPPFLAGS]) +AC_MSG_RESULT([$LOCALE_CPPFLAGS]) + dnl i18n GETTEXT_PACKAGE=$PACKAGE AC_SUBST(GETTEXT_PACKAGE) diff --git a/po/ChangeLog b/po/ChangeLog index e69de29b..feebde1c 100644 --- a/po/ChangeLog +++ b/po/ChangeLog @@ -0,0 +1,4 @@ +2008-12-07 Gabriel Burt + + * es.po: Nearly-empty Spanish translation to help prove the app is + translatable diff --git a/po/es.po b/po/es.po index a93dfeaf..db247ffd 100644 --- a/po/es.po +++ b/po/es.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2008-12-07 17:52-0600\n" +"POT-Creation-Date: 2008-12-07 18:43-0600\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -17,81 +17,82 @@ msgstr "" "Plural-Forms: nplurals=2; plural=(n != 1);\n" #. TODO: do we really want to disconnect on a failure to write? -#: ../src/sipe.c:514 ../src/sipe.c:544 +#: ../src/sipe.c:522 ../src/sipe.c:552 msgid "Could not write" msgstr "" -#: ../src/sipe.c:567 ../src/sipe.c:2834 +#: ../src/sipe.c:575 ../src/sipe.c:2843 msgid "Could not connect" msgstr "" -#: ../src/sipe.c:625 ../src/sipe.c:2993 +#: ../src/sipe.c:633 ../src/sipe.c:3002 msgid "Couldn't create socket" msgstr "" -#: ../src/sipe.c:1376 ../src/sipe.c:1383 ../src/sipe.c:1390 +#. Translators: noun +#: ../src/sipe.c:1385 ../src/sipe.c:1392 ../src/sipe.c:1399 msgid "Message" msgstr "" -#: ../src/sipe.c:1389 +#: ../src/sipe.c:1398 msgid "Busy" msgstr "" -#: ../src/sipe.c:2071 +#: ../src/sipe.c:2080 msgid "Wrong Password" msgstr "" -#: ../src/sipe.c:2100 +#: ../src/sipe.c:2109 msgid "You have been rejected by the server" msgstr "" -#: ../src/sipe.c:2686 +#: ../src/sipe.c:2695 msgid "Invalid message signature received" msgstr "" -#: ../src/sipe.c:2734 +#: ../src/sipe.c:2743 msgid "Connection not found; Please try to connect again.\n" msgstr "" -#: ../src/sipe.c:2758 +#: ../src/sipe.c:2767 msgid "Server has disconnected" msgstr "" -#: ../src/sipe.c:2896 ../src/sipe.c:2939 ../src/sipe.c:2977 ../src/sipe.c:3050 +#: ../src/sipe.c:2905 ../src/sipe.c:2948 ../src/sipe.c:2986 ../src/sipe.c:3059 msgid "Could not create listen socket" msgstr "" -#: ../src/sipe.c:2920 +#: ../src/sipe.c:2929 msgid "Couldn't resolve host" msgstr "" -#: ../src/sipe.c:2959 +#: ../src/sipe.c:2968 msgid "Connection Failed" msgstr "" -#: ../src/sipe.c:2962 +#: ../src/sipe.c:2971 msgid "SSL Handshake Failed" msgstr "" -#: ../src/sipe.c:3024 +#: ../src/sipe.c:3033 msgid "" -"SSL support is needed for SSL/TLS support. Please install a supported SSL " -"library." +"SSL support is not installed. Either install SSL support or configure a " +"different connection type in the account editor." msgstr "" -#: ../src/sipe.c:3032 +#: ../src/sipe.c:3041 msgid "Could not create SSL context" msgstr "" -#: ../src/sipe.c:3041 +#: ../src/sipe.c:3050 msgid "Could not resolve hostname" msgstr "" -#: ../src/sipe.c:3146 +#: ../src/sipe.c:3155 msgid "SIP Exchange usernames may not contain whitespaces" msgstr "" -#: ../src/sipe.c:3164 +#: ../src/sipe.c:3173 msgid "Connecting" msgstr "" @@ -103,54 +104,55 @@ msgstr "" #. *< id #. *< name #. *< version -#: ../src/sipe.c:3379 +#: ../src/sipe.c:3388 msgid "SIP/SIMPLE OCS/LCS Protocol Plugin" msgstr "" #. * summary -#: ../src/sipe.c:3380 +#: ../src/sipe.c:3389 msgid "The SIP/SIMPLE LCS/OCS Protocol Plugin" msgstr "" -#: ../src/sipe.c:3405 +#: ../src/sipe.c:3420 msgid "Use proxy" msgstr "" -#: ../src/sipe.c:3407 +#: ../src/sipe.c:3422 msgid "Proxy Server" msgstr "" -#: ../src/sipe.c:3410 +#: ../src/sipe.c:3425 msgid "Use non-standard port" msgstr "" -#: ../src/sipe.c:3412 +#. Translators: noun (networking port) +#: ../src/sipe.c:3428 msgid "Port" msgstr "" -#: ../src/sipe.c:3415 -msgid "Transport" -msgstr "" +#: ../src/sipe.c:3431 +msgid "Connection Type" +msgstr "Tipo de conexión" -#: ../src/sipe.c:3416 +#: ../src/sipe.c:3432 msgid "Auto" msgstr "" -#: ../src/sipe.c:3417 +#: ../src/sipe.c:3433 msgid "SSL/TLS" msgstr "" -#: ../src/sipe.c:3418 +#: ../src/sipe.c:3434 msgid "TCP" msgstr "" -#: ../src/sipe.c:3419 +#: ../src/sipe.c:3435 msgid "UDP" msgstr "" #. option = purple_account_option_bool_new(_("Publish status (note: everyone may watch you)"), "doservice", TRUE); #. prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option); -#: ../src/sipe.c:3425 +#: ../src/sipe.c:3441 msgid "User Agent" msgstr "" @@ -162,10 +164,10 @@ msgstr "" #. option = purple_account_option_string_new(_("Kerberos Realm"), "krb5_realm", ""); #. prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option); #. -#: ../src/sipe.c:3437 +#: ../src/sipe.c:3453 msgid "Auth User" msgstr "" -#: ../src/sipe.c:3439 +#: ../src/sipe.c:3455 msgid "Auth Domain" msgstr "" diff --git a/src/Makefile.am b/src/Makefile.am index 8f0ed741..099d1858 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -28,6 +28,7 @@ libsipe_la_CFLAGS = \ $(DEBUG_CFLAGS) \ $(GLIB_CFLAGS) \ $(PIDGIN_CFLAGS) \ + $(LOCALE_CPPFLAGS) \ $(KRB5_CFLAGS) libsipe_la_LDFLAGS = \ diff --git a/src/sipe.c b/src/sipe.c index d343c95f..d223a4c9 100644 --- a/src/sipe.c +++ b/src/sipe.c @@ -41,6 +41,14 @@ #include "internal.h" #endif /* _WIN32 */ +#include + +#ifdef ENABLE_NLS +# include +#else +# define _(String) ((const char *) (String)) +#endif /* ENABLE_NLS */ + #include "accountopt.h" #include "blist.h" #include "conversation.h" @@ -1373,6 +1381,7 @@ static GList *sipe_status_types(PurpleAccount *acc) // Available type = purple_status_type_new_with_attrs( PURPLE_STATUS_AVAILABLE, NULL, NULL, TRUE, TRUE, FALSE, + // Translators: noun "message", _("Message"), purple_value_new(PURPLE_TYPE_STRING), NULL); types = g_list_append(types, type); @@ -3021,7 +3030,7 @@ static void create_connection(struct sipe_account_data *sip, gchar *hostname, in /* SSL case */ if (!purple_ssl_is_supported()) { gc->wants_to_die = TRUE; - purple_connection_error(gc, _("SSL support is needed for SSL/TLS support. Please install a supported SSL library.")); + purple_connection_error(gc, _("SSL support is not installed. Either install SSL support or configure a different connection type in the account editor.")); return; } @@ -3400,6 +3409,12 @@ static void init_plugin(PurplePlugin *plugin) PurpleAccountOption *option; PurpleKeyValuePair *kvp; +#ifdef ENABLE_NLS + purple_debug_info(PACKAGE, "bindtextdomain = %s", bindtextdomain(GETTEXT_PACKAGE, LOCALEDIR)); + purple_debug_info(PACKAGE, "bind_textdomain_codeset = %s", + bind_textdomain_codeset(GETTEXT_PACKAGE, "UTF-8")); +#endif + purple_plugin_register(plugin); option = purple_account_option_bool_new(_("Use proxy"), "useproxy", FALSE); @@ -3409,10 +3424,11 @@ static void init_plugin(PurplePlugin *plugin) option = purple_account_option_bool_new(_("Use non-standard port"), "useport", FALSE); prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option); + // Translators: noun (networking port) option = purple_account_option_int_new(_("Port"), "port", 5061); prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option); - option = purple_account_option_list_new(_("Transport"), "transport", NULL); + option = purple_account_option_list_new(_("Connection Type"), "transport", NULL); purple_account_option_add_list_item(option, _("Auto"), "auto"); purple_account_option_add_list_item(option, _("SSL/TLS"), "tls"); purple_account_option_add_list_item(option, _("TCP"), "tcp"); -- 2.11.4.GIT