Welcome to mirror list, hosted at ThFree Co, Russian Federation.

dev.gajim.org/gajim/gajim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYann Leboulanger <asterix@lagaule.org>2008-08-14 21:19:21 +0400
committerYann Leboulanger <asterix@lagaule.org>2008-08-14 21:19:21 +0400
commit7efaecc5d84e8b177b0f9228f5d52271a8de7de1 (patch)
treebfd4f833da17ff43ac35d139ec33fdb7cdf1c5f1
parent4e52e954d0e08c7537f66c259a36f99061e9a7fb (diff)
make a string translatable. Fixes #4203
-rw-r--r--src/chat_control.py21
1 files changed, 12 insertions, 9 deletions
diff --git a/src/chat_control.py b/src/chat_control.py
index 897567c46..1830aa1a1 100644
--- a/src/chat_control.py
+++ b/src/chat_control.py
@@ -1552,21 +1552,24 @@ class ChatControl(ChatControlBase):
def _show_lock_image(self, visible, enc_type = '', enc_enabled = False, chat_logged = False, authenticated = False):
'''Set lock icon visibility and create tooltip'''
- # TODO: Make translatable
- status_string = enc_enabled and 'is' or 'is NOT'
- logged_string = chat_logged and 'will' or 'will NOT'
+ #encryption %s active
+ status_string = enc_enabled and _('is') or _('is NOT')
+ #chat session %s be logged
+ logged_string = chat_logged and _('will') or _('will NOT')
if authenticated:
- authenticated_string = ' and authenticated'
+ #About encrypted chat session
+ authenticated_string = _('and authenticated')
self.lock_image.set_from_file(os.path.join(gajim.DATA_DIR, 'pixmaps', 'security-high.png'))
else:
- authenticated_string = ' and NOT authenticated'
+ #About encrypted chat session
+ authenticated_string = _('and NOT authenticated')
self.lock_image.set_from_file(os.path.join(gajim.DATA_DIR, 'pixmaps', 'security-low.png'))
- tooltip = '%s encryption %s active%s.\n' \
- 'Your chat session %s be logged.' % \
- (enc_type, status_string, authenticated_string,
- logged_string)
+ tooltip = _('%(type)s encryption %(status)s active %(authenticated)s.\n'
+ 'Your chat session %(logged)s be logged.'\
+ % {'type': enc_type, 'status': status_string,
+ 'authenticated': authenticated_string, 'logged': logged_string)
self.lock_tooltip.set_tip(self.authentication_button, tooltip)
self.widget_set_visible(self.authentication_button, not visible)