diff options
author | Ted Gould <ted@gould.cx> | 2010-03-25 09:26:32 -0500 |
---|---|---|
committer | Ted Gould <ted@gould.cx> | 2010-03-25 09:26:32 -0500 |
commit | c310593fc483084ab8f05e66f931b93de0ea0c74 (patch) | |
tree | 73351055e7a4ebd22d6f60278897d38e8ebe54dc | |
parent | 9abd35df0f4194a06d5005009ed888f80938fc8c (diff) | |
parent | 14f57ce5b136d74c53974137264d363a6baa03b7 (diff) | |
download | ayatana-indicator-session-c310593fc483084ab8f05e66f931b93de0ea0c74.tar.gz ayatana-indicator-session-c310593fc483084ab8f05e66f931b93de0ea0c74.tar.bz2 ayatana-indicator-session-c310593fc483084ab8f05e66f931b93de0ea0c74.zip |
* Upstream Merge
* Adding a switch for translators if the "Switch From"
translation doesn't make sense (LP: #545893)
-rw-r--r-- | debian/changelog | 8 | ||||
-rw-r--r-- | src/indicator-session.c | 11 |
2 files changed, 18 insertions, 1 deletions
diff --git a/debian/changelog b/debian/changelog index e64fa59..43f6ffa 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +indicator-session (0.2.6-0ubuntu3~ppa3) UNRELEASED; urgency=low + + * Upstream Merge + * Adding a switch for translators if the "Switch From" + translation doesn't make sense (LP: #545893) + + -- Ted Gould <ted@ubuntu.com> Thu, 25 Mar 2010 09:24:15 -0500 + indicator-session (0.2.6-0ubuntu3~ppa2) lucid; urgency=low * Upstream Merge diff --git a/src/indicator-session.c b/src/indicator-session.c index 57ead25..dc23139 100644 --- a/src/indicator-session.c +++ b/src/indicator-session.c @@ -314,11 +314,20 @@ switch_property_change (DbusmenuMenuitem * item, const gchar * property, const G GtkMenuItem * gmi = dbusmenu_gtkclient_menuitem_get(DBUSMENU_GTKCLIENT(user_data), item); gchar * finalstring = NULL; gboolean set_ellipsize = FALSE; + gboolean no_name_in_lang = FALSE; + + /* TRANSLATORS: Translate the '1' below into anything other than + '1' if "Switch From %s..." doesn't make sense in your language. + Instead, the string "Switch User..." will be used. */ + const gchar * translate = C_("session_menu:switchfrom", "1"); + if (g_strcmp0(translate, "1") != 0) { + no_name_in_lang = TRUE; + } /* If there's a NULL string of some type, then we want to go back to our old 'Switch User' which isn't great but eh, this error condition should never happen. */ - if (value == NULL || g_value_get_string(value) == NULL || g_value_get_string(value)[0] == '\0') { + if (value == NULL || g_value_get_string(value) == NULL || g_value_get_string(value)[0] == '\0' || no_name_in_lang) { finalstring = _("Switch User..."); set_ellipsize = FALSE; } |