def cancelClick(self):
self.close(False)
+class SilentBouquetSelector:
+ def __init__(self, bouquets, enableWrapAround=False, current=0):
+ self.bouquets = [b[1] for b in bouquets]
+ self.pos = current
+ self.count = len(bouquets)
+ self.enableWrapAround = enableWrapAround
+
+ def up(self):
+ if self.pos > 0 or self.enableWrapAround:
+ self.pos = (self.pos - 1) % self.count
+
+ def down(self):
+ if self.pos < (self.count - 1) or self.enableWrapAround:
+ self.pos = (self.pos + 1) % self.count
+
+ def getCurrent(self):
+ return self.bouquets[self.pos]
+
# csel.bouquet_mark_edit values
OFF = 0
EDIT_BOUQUET = 1
if self.session.pipshown:
del self.session.pip
self.session.pip = self.session.instantiateDialog(PictureInPicture)
+ self.session.pip.setAnimationMode(0)
self.session.pip.show()
newservice = self.csel.servicelist.getCurrent()
if self.session.pip.playService(newservice):
self.servicelist.moveToChar(charstr[0])
def keyAsciiCode(self):
- unichar = unichr(getPrevAsciiCode())
+ #unichar = unichr(getPrevAsciiCode())
+ from Components.config import getCharValue
+ unichar = getCharValue(getPrevAsciiCode())
+ if unichar is None:
+ return
+ if len(str(unichar)) > 1:
+ return
charstr = unichar.encode("utf-8")
if len(charstr) == 1:
self.servicelist.moveToChar(charstr[0])
self.onLayoutFinish.append(self.onCreate)
self.info = session.instantiateDialog(RadioInfoBar) # our simple infobar
+ self.info.setAnimationMode(0)
self["actions"] = ActionMap(["OkCancelActions", "TvRadioActions"],
{