Do not fsize co...
Content-type: text/plain

Author: andar

Revision: 5087

Log:
        Re-add input string during refresh
Do not fsize config values

Diff:
Modified: trunk/deluge/ui/console/screen.py
===================================================================
--- trunk/deluge/ui/console/screen.py   2009-04-18 18:28:35 UTC (rev 5086)
+++ trunk/deluge/ui/console/screen.py   2009-04-18 18:46:01 UTC (rev 5087)
@@ -167,6 +167,9 @@
         for index, line in enumerate(lines):
             self.add_string(index + 1, line)
 
+        # Add the input string
+        self.add_string(self.rows - 1, self.input)
+
         # Move the cursor
         self.stdscr.move(self.rows - 1, self.input_cursor)
         self.stdscr.refresh()
@@ -252,7 +255,6 @@
                 self.input_cursor += 1
 
         # Update the input string on the screen
-        #self.stdscr.addstr(self.rows - 1, 0, self.input + " " * (self.cols - 
len(self.input) - 2), curses.color_pair(1))
         self.add_string(self.rows - 1, self.input)
         self.stdscr.move(self.rows - 1, self.input_cursor)
         self.stdscr.refresh()

Modified: trunk/deluge/ui/console/statusbars.py
===================================================================
--- trunk/deluge/ui/console/statusbars.py       2009-04-18 18:28:35 UTC (rev 
5086)
+++ trunk/deluge/ui/console/statusbars.py       2009-04-18 18:46:01 UTC (rev 
5087)
@@ -39,12 +39,14 @@
         self.upload = ""
         self.dht = 0
 
+        # This lets us know when the CoreConfig component is ready
+        self.__core_config_ready = False
+
     def start(self):
         def on_coreconfig_ready(result):
             self.__core_config_ready = True
             self.update()
 
-        self.__core_config_ready = False
         # We need to add a callback to wait for the CoreConfig to be ready
         self.config.start_defer.addCallback(on_coreconfig_ready)
 
@@ -89,12 +91,12 @@
         self.screen.bottombar += " D: %s/s" % self.download
 
         if self.config["max_download_speed"] > -1:
-            self.screen.bottombar += " (%s/s)" % 
deluge.common.fsize(self.config["max_download_speed"])
+            self.screen.bottombar += " (%s/s)" % 
self.config["max_download_speed"]
 
         self.screen.bottombar += " U: %s/s" % self.upload
 
         if self.config["max_upload_speed"] > -1:
-            self.screen.bottombar += " (%s/s)" % 
deluge.common.fsize(self.config["max_upload_speed"])
+            self.screen.bottombar += " (%s/s)" % 
self.config["max_upload_speed"]
 
         if self.config["dht"]:
             self.screen.bottombar += " DHT: %s" % self.dht



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"deluge-commit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/deluge-commit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to