From 3ad63c0c2737cc280ac361052e6762eecb7b2d22 Mon Sep 17 00:00:00 2001 From: Nikos Kouremenos Date: Sat, 21 May 2005 13:19:42 +0000 Subject: [PATCH] add show texts to be translated --- src/common/helpers.py | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/src/common/helpers.py b/src/common/helpers.py index 8173b198c..98973adfb 100644 --- a/src/common/helpers.py +++ b/src/common/helpers.py @@ -17,15 +17,24 @@ ## GNU General Public License for more details. ## +from common import i18n +_ = i18n._ + def get_uf_show(show): '''returns a userfriendly string for dnd/xa/chat and capitalize()s the rest''' if show == 'dnd': - uf_show = 'Busy' + uf_show = _('Busy') elif show == 'xa': - uf_show = 'Not Available' + uf_show = _('Not Available') elif show == 'chat': - uf_show = 'Free for Chat' - else: - uf_show = show.capitalize() + uf_show = _('Free for Chat') + elif show == 'online': + uf_show = _('Online') + elif show == 'connecting': + uf_show = _('Connecting') + elif show == 'away': + uf_show = _('Away') + elif show == 'away': + uf_show = _('Away') return uf_show