set default standby-brightness to 0
[enigma2.git] / lib / python / Components / EpgList.py
1 from HTMLComponent import *
2 from GUIComponent import *
3
4 from enigma import *
5
6 class EPGList(HTMLComponent, GUIComponent):
7         def __init__(self):
8                 GUIComponent.__init__(self)
9                 self.l = eListboxEPGContent()
10
11         def getCurrent(self):
12                 evt = self.l.getCurrent()
13                 return evt
14
15         def moveUp(self):
16                 self.instance.moveSelection(self.instance.moveUp)
17
18         def moveDown(self):
19                 self.instance.moveSelection(self.instance.moveDown)
20
21         def GUIcreate(self, parent):
22                 self.instance = eListbox(parent)
23                 self.instance.setContent(self.l)
24
25         def GUIdelete(self):
26                 self.instance = None
27
28         def setRoot(self, root):
29                 self.l.setRoot(root)
30                 self.l.sort()
31
32 #       def setMode(self, mode):
33 #               if mode == self.MODE_NORMAL:
34 #                       self.instance.setItemHeight(20)
35 #                       self.l.setVisualMode(eListboxServiceContent.visModeSimple)
36 #               else:
37 #                       self.instance.setItemHeight(40)
38 #                       self.l.setElementFont(self.l.celServiceName, gFont("Arial", 30))
39 #                       self.l.setElementPosition(self.l.celServiceName, eRect(40, 0, self.instance.size().width(), 40))
40 #                       self.l.setElementFont(self.l.celServiceNumber, gFont("Arial", 20))
41 #                       self.l.setElementPosition(self.l.celServiceNumber, eRect(0, 10, 40, 30))
42 #
43 #                       self.l.setVisualMode(eListboxServiceContent.visModeComplex)