Prettify Blinkenlights.sleep()
Prettify the function. Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
This commit is contained in:
parent
f6f8fc8528
commit
8195d1410f
@ -506,11 +506,11 @@ class Blinkenlights(UIBase, CursesUtil):
|
|||||||
# Trying to end sleep somewhere.
|
# Trying to end sleep somewhere.
|
||||||
self.getaccountframe(self.hotkeys[index]).syncnow()
|
self.getaccountframe(self.hotkeys[index]).syncnow()
|
||||||
|
|
||||||
def sleep(s, sleepsecs, account):
|
def sleep(self, sleepsecs, account):
|
||||||
s.gettf().setcolor('red')
|
self.gettf().setcolor('red')
|
||||||
s._msg("Next sync in %d:%02d" % (sleepsecs / 60, sleepsecs % 60))
|
self.info("Next sync in %d:%02d" % (sleepsecs / 60, sleepsecs % 60))
|
||||||
s.getaccountframe().startsleep(sleepsecs)
|
self.getaccountframe().startsleep(sleepsecs)
|
||||||
return UIBase.sleep(s, sleepsecs, account)
|
return super(Blinkenlights, self).sleep(sleepsecs, account)
|
||||||
|
|
||||||
def sleeping(self, sleepsecs, remainingsecs):
|
def sleeping(self, sleepsecs, remainingsecs):
|
||||||
if remainingsecs and s.gettf().getcolor() == 'black':
|
if remainingsecs and s.gettf().getcolor() == 'black':
|
||||||
|
Loading…
Reference in New Issue
Block a user