X-Git-Url: https://git.cweiske.de/enigma2.git/blobdiff_plain/d04d03175ca6e6df022b09b0b8e068355626b5dd..cf81c9acef45dc09976065bb4e7ad9b4818c5aa6:/lib/python/Screens/Ci.py diff --git a/lib/python/Screens/Ci.py b/lib/python/Screens/Ci.py index e95672d6..8443079e 100644 --- a/lib/python/Screens/Ci.py +++ b/lib/python/Screens/Ci.py @@ -57,7 +57,10 @@ class CiMmi(Screen): if entry[0] == "TEXT": #handle every item (text / pin only?) list.append( (entry[1], index) ) if entry[0] == "PIN": - x = configElement_nonSave("", configSequence, [1234], configsequencearg.get("INTEGER", (0, ((10**entry[1])-1)))) + # masked pins: + x = configElement_nonSave("", configSequence, [1234], configsequencearg.get("PINCODE", (entry[1], "-"))) + # unmasked pins: + # x = configElement_nonSave("", configSequence, [1234], configsequencearg.get("PINCODE", (entry[1], ""))) list.append( getConfigListEntry(entry[2],x) ) def okbuttonClick(self): @@ -110,17 +113,26 @@ class CiMmi(Screen): "0": self.keyNumberGlobal }, -1) -#just for testing - we need an cimanager? (or not?) class CiSelection(Screen): def okbuttonClick(self): - #generate menu / list - list = [ ] - list.append( ("TEXT", "CA-Info") ) - list.append( ("TEXT", "Card Status") ) - list.append( ("PIN", 6, "Card Pin") ) - self.session.open(CiMmi, 0, "Wichtiges CI", "Mainmenu", "Footer", list) + + if self["entries"].getCurrent()[1] == 0: #reset + print "ci reset requested" + pass + if self["entries"].getCurrent()[1] == 1: #init + print "ci init requested" + pass + if self["entries"].getCurrent()[1] == 2: #mmi open + #ci->getInstance().mmiOpen() and wait for list of elments ??? + #generate menu / list + list = [ ] + list.append( ("TEXT", "CA-Info") ) + list.append( ("TEXT", "Card Status") ) + list.append( ("PIN", 6, "Card Pin") ) + self.session.open(CiMmi, 0, "Wichtiges CI", "Mainmenu", "Footer", list) def __init__(self, session): + #FIXME support for one ci only Screen.__init__(self, session) self["actions"] = ActionMap(["OkCancelActions"], @@ -128,3 +140,10 @@ class CiSelection(Screen): "ok": self.okbuttonClick, "cancel": self.close }) + + list = [ ] + list.append( ("Reset", 0) ) + list.append( ("Init", 1) ) + #add timer for "app-manager name" ? + list.append( ("Irdeto Blasel SE", 2) ) + self["entries"] = CiEntryList(list)