diff options
| author | Felix Domke <tmbinc@elitedvb.net> | 2006-07-30 23:21:55 +0000 |
|---|---|---|
| committer | Felix Domke <tmbinc@elitedvb.net> | 2006-07-30 23:21:55 +0000 |
| commit | ddb050fe8357a01b1fc52070ee9f87450c407c1c (patch) | |
| tree | 39a1774f394d9651cc9a4bbf646ab852779cd7e0 /lib/python/Components/Sources | |
| parent | 1557c715e461d5a7deb04bb008c6497441351bbe (diff) | |
| download | enigma2-ddb050fe8357a01b1fc52070ee9f87450c407c1c.tar.gz enigma2-ddb050fe8357a01b1fc52070ee9f87450c407c1c.zip | |
suspend timers when all renders are hidden
Diffstat (limited to 'lib/python/Components/Sources')
| -rw-r--r-- | lib/python/Components/Sources/Clock.py | 8 | ||||
| -rw-r--r-- | lib/python/Components/Sources/FrontendStatus.py | 7 |
2 files changed, 15 insertions, 0 deletions
diff --git a/lib/python/Components/Sources/Clock.py b/lib/python/Components/Sources/Clock.py index e2d7faa7..7f1a8d7f 100644 --- a/lib/python/Components/Sources/Clock.py +++ b/lib/python/Components/Sources/Clock.py @@ -18,3 +18,11 @@ class Clock(Source): def poll(self): self.changed((self.CHANGED_POLL,)) + + def doSuspend(self, suspended): + if suspended: + self.clock_timer.stop() + else: + self.clock_timer.start(1000) + self.poll() + diff --git a/lib/python/Components/Sources/FrontendStatus.py b/lib/python/Components/Sources/FrontendStatus.py index f1402f11..352b9fdc 100644 --- a/lib/python/Components/Sources/FrontendStatus.py +++ b/lib/python/Components/Sources/FrontendStatus.py @@ -37,3 +37,10 @@ class FrontendStatus(Source): return service and service.frontendInfo() else: return None + + def doSuspend(self, suspended): + if suspended: + self.poll_timer.stop() + else: + self.poll_timer.start(1000) + |
