1
0
mirror of https://github.com/gryf/wicd.git synced 2026-02-02 22:25:50 +01:00

Modified 1.6-urwid-0.9.9-compat to be compatible with 0.9.8.4.

This should be compatible with 0.9.9 as well.
This commit is contained in:
Andrew Psaltis
2009-08-06 23:58:13 -04:00
parent 6d70e917ad
commit 1930680787
2 changed files with 8 additions and 12 deletions

View File

@@ -204,7 +204,8 @@ class TabColumns(urwid.WidgetWrap):
])
if not firstrun:
self.frame.set_body(self.pile)
self._set_w(self.frame)
self._w = self.frame
self._invalidate()
def selectable(self):
return True
@@ -375,7 +376,8 @@ class ComboBox(urwid.WidgetWrap):
self.overlay = self.ComboSpace(self.list,parent,ui,self.focus,
pos=(0,row))
self._set_w(w)
self._w = w
self._invalidate()
self.parent = parent
self.ui = ui
self.row = row

View File

@@ -919,14 +919,7 @@ class appGUI():
def update_ui(self,from_key=True,from_alarm=False):
#self.update_status()
canvas = self.frame.render( (self.size),True )
### GRRRRRRRRRRRRRRRRRRRRR ->^^^^
# It looks like if I want to get the statusbar to update itself
# continuously, I would have to use overlay the canvasses and redirect
# the input. I'll try to get that working at a later time, if people
# want that "feature".
#canvaso = urwid.CanvasOverlay(self.dialog.render( (80,20),True),canvas,0,1)
# If the screen is turned off for some reason, don't even try to do the
# rest of the stuff.
if not ui._started:
return False
# Update the screen
@@ -940,10 +933,11 @@ class appGUI():
if self.update_tag != None:
gobject.source_remove(self.update_tag)
if max_wait == None:
max_wait = 100
max_wait = 25
else:
max_wait *= 1000
max_wait *= 100
max_wait = int(max_wait)
self.update_tag = gobject.timeout_add(max_wait, \
self.update_ui,False,True)
#print keys