~gmb/gwibber/dbus-hang-bug-326694

« back to all changes in this revision

Viewing changes to gwibber/client.py

  • Committer: Greg Grossmeier
  • Date: 2009-02-05 05:04:54 UTC
  • Revision ID: greg.grossmeier@gmail.com-20090205050454-9ch38n0h50dh4spa
Used the built in python time and date functions that display the 
correct localized version of their values.  See: 
http://docs.python.org/library/time.html#time.strftime

Thanks to Bruno Bord for the patch: 
lp:~brunobord/gwibber/dates-and-locales

Show diffs side-by-side

added added

removed removed

Lines of Context:
101
101
    self.message_target = None
102
102
    
103
103
    self.errors = table.generate([
104
 
      ["date", lambda t: t.time.strftime(_("%Y-%m-%d"))],
105
 
      ["time", lambda t: t.time.strftime(_("%I:%M:%S %p"))],
 
104
      ["date", lambda t: t.time.strftime("%x")],
 
105
      ["time", lambda t: t.time.strftime("%X")],
106
106
      ["username"],
107
107
      ["protocol"],
108
108
      ["message", (gtk.CellRendererText(), {
917
917
        gtk.gdk.threads_leave()
918
918
 
919
919
        self.statusbar.pop(0)
920
 
        self.statusbar.push(0, _("Last update: %s") % time.strftime(_("%I:%M:%S %p")))
 
920
        self.statusbar.push(0, _("Last update: %s") % time.strftime("%X"))
921
921
        self.last_update = next_update
922
922
        
923
923
      finally: gobject.idle_add(self.throbber.clear)