[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [arm/master] Display placementLabel instead of timestamp for circuit lines.



commit 473a6b53d584108492b3a21cc0036117cc02b9b4
Author: Kamran Riaz Khan <krkhan@xxxxxxxxxxxxxx>
Date:   Wed Jul 13 14:44:13 2011 +0500

    Display placementLabel instead of timestamp for circuit lines.
---
 src/gui/connections/circEntry.py |    3 +--
 src/gui/connections/connPanel.py |    5 +++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/gui/connections/circEntry.py b/src/gui/connections/circEntry.py
index 11876f8..deb720a 100644
--- a/src/gui/connections/circEntry.py
+++ b/src/gui/connections/circEntry.py
@@ -35,8 +35,7 @@ class CircLine(circEntry.CircLine, connEntry.ConnectionLine):
       dst = self.getDestinationLabel(100, includeLocale=True)
       etc = self.foreign.getNickname()
 
-    timeLabel = uiTools.getTimeLabel(time.time() - self.startTime)
     theme = gtkTools.Theme()
 
-    return (dst, etc, timeLabel, self.getType(), theme.colors['insensitive'])
+    return (dst, etc, self.placementLabel, self.getType(), theme.colors['insensitive'])
 
diff --git a/src/gui/connections/connPanel.py b/src/gui/connections/connPanel.py
index 3b980e1..e6a7c5b 100644
--- a/src/gui/connections/connPanel.py
+++ b/src/gui/connections/connPanel.py
@@ -69,8 +69,9 @@ class ConnectionPanel(CliConnectionPanel):
       cacheKey = calculateCacheKey(line)
 
       if self.cache.has_key(cacheKey):
-        timeLabel = "%d s" % (time.time() - line.startTime)
-        treestore.set_value(self.cache[cacheKey], 2, timeLabel)
+        if not isinstance(line, circEntry.CircLine):
+          timeLabel = "%d s" % (time.time() - line.startTime)
+          treestore.set_value(self.cache[cacheKey], 2, timeLabel)
       else:
         break
 



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits