aboutsummaryrefslogtreecommitdiff
path: root/lib/python/Screens
diff options
context:
space:
mode:
authorAndreas Monzner <andreas.monzner@multimedia-labs.de>2006-12-31 16:54:51 +0000
committerAndreas Monzner <andreas.monzner@multimedia-labs.de>2006-12-31 16:54:51 +0000
commitbfa525d0451df77a28db6ce21ec45f00b89661a8 (patch)
treee41e618bc2e9ef678922c01ceb375d803aca10f8 /lib/python/Screens
parent672bbfc3e8a1d063ad3d96be1711bddf5ca66249 (diff)
downloadenigma2-bfa525d0451df77a28db6ce21ec45f00b89661a8.tar.gz
enigma2-bfa525d0451df77a28db6ce21ec45f00b89661a8.zip
nicer code
Diffstat (limited to 'lib/python/Screens')
-rw-r--r--lib/python/Screens/InfoBarGenerics.py17
1 files changed, 10 insertions, 7 deletions
diff --git a/lib/python/Screens/InfoBarGenerics.py b/lib/python/Screens/InfoBarGenerics.py
index c8c9f30d..9b3c5cf4 100644
--- a/lib/python/Screens/InfoBarGenerics.py
+++ b/lib/python/Screens/InfoBarGenerics.py
@@ -860,25 +860,28 @@ class InfoBarSeek:
from Screens.PVRState import PVRState, TimeshiftState
class InfoBarPVRState:
- def __init__(self, screen=PVRState, show_always_in_timeshift=False):
- self.show_always_in_timeshift = show_always_in_timeshift
+ def __init__(self, screen=PVRState):
self.onPlayStateChanged.append(self.__playStateChanged)
self.pvrStateDialog = self.session.instantiateDialog(screen)
- self.onShow.append(self.__mayShow)
+ self.onShow.append(self._mayShow)
self.onHide.append(self.pvrStateDialog.hide)
- def __mayShow(self):
- if self.execing and ((self.show_always_in_timeshift and self.timeshift_enabled) or self.seekstate != self.SEEK_STATE_PLAY):
+ def _mayShow(self):
+ if self.execing and self.seekstate != self.SEEK_STATE_PLAY:
self.pvrStateDialog.show()
def __playStateChanged(self, state):
playstateString = state[3]
self.pvrStateDialog["state"].setText(playstateString)
- self.__mayShow()
+ self._mayShow()
class InfoBarTimeshiftState(InfoBarPVRState):
def __init__(self):
- InfoBarPVRState.__init__(self, screen=TimeshiftState, show_always_in_timeshift=True)
+ InfoBarPVRState.__init__(self, screen=TimeshiftState)
+
+ def _mayShow(self):
+ if self.execing and self.timeshift_enabled:
+ self.pvrStateDialog.show()
class InfoBarShowMovies: