changeset 7b1dfd3b79d5 in /home/hg/repos/gajim

branches: gajim_0.16
details:http://hg.gajim.org/gajim?cmd=changeset;node=7b1dfd3b79d5
description: [mrDoctorWhо and Darlan] Fix day and time in RTL message. see #7284

diffstat:

 src/conversation_textview.py |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (39 lines):

diff -r d3f08a194726 -r 7b1dfd3b79d5 src/conversation_textview.py
--- a/src/conversation_textview.py      Sun Aug 04 22:08:41 2013 +0400
+++ b/src/conversation_textview.py      Tue Aug 06 23:42:02 2013 +0400
@@ -1302,7 +1302,7 @@
         if kind == 'status':
             direction_mark = i18n.direction_mark
         if current_print_time == 'always' and kind != 'info' and not simple:
-            timestamp_str = self.get_time_to_show(tim)
+            timestamp_str = self.get_time_to_show(tim, direction_mark)
             timestamp = time.strftime(timestamp_str, tim)
             timestamp = direction_mark + timestamp
             buffer_.insert_with_tags_by_name(end_iter, timestamp,
@@ -1318,7 +1318,7 @@
                     ft = 
self.fc.fuzzy_time(gajim.config.get('print_time_fuzzy'), tim)
                     tim_format = ft.decode(locale.getpreferredencoding())
                 else:
-                    tim_format = self.get_time_to_show(tim)
+                    tim_format = self.get_time_to_show(tim, direction_mark)
                 buffer_.insert_with_tags_by_name(end_iter, tim_format + '\n',
                         'time_sometimes')
         # If there's a displaymarking, print it here.
@@ -1373,7 +1373,7 @@
         self.just_cleared = False
         buffer_.end_user_action()
 
-    def get_time_to_show(self, tim):
+    def get_time_to_show(self, tim, direction_mark=''):
         """
         Get the time, with the day before if needed and return it. It DOESN'T
         format a fuzzy time
@@ -1392,7 +1392,7 @@
                 '%(nb_days)i days ago', diff_day, {'nb_days': diff_day},
                 {'nb_days': diff_day})
         if day_str:
-            format_ += day_str + ' '
+            format_ += i18n.direction_mark + day_str + direction_mark + ' '
         timestamp_str = gajim.config.get('time_stamp')
         timestamp_str = helpers.from_one_line(timestamp_str)
         format_ += timestamp_str
_______________________________________________
Commits mailing list
[email protected]
http://lists.gajim.org/cgi-bin/listinfo/commits

Reply via email to