2 from Screens.Screen import Screen
3 from Screens.MessageBox import MessageBox
4 from Components.ActionMap import ActionMap
5 from Components.Label import Label
11 <screen position="100,100" size="550,400" title="IPKG upgrade..." >
12 <widget name="text" position="0,0" size="550,400" font="Regular;15" />
15 def __init__(self, session):
16 self.skin = Example.skin
17 Screen.__init__(self, session)
19 self["text"] = Label(_("Please press OK!"))
21 self["actions"] = ActionMap(["WizardActions"],
28 self.delayTimer = eTimer()
29 self.delayTimer.timeout.get().append(self.doUpdateDelay)
33 self.session.openWithCallback(self.doUpdate, MessageBox, _("Do you want to update your Dreambox?\nAfter pressing OK, please wait!"))
37 def doUpdateDelay(self):
38 lines = os.popen("ipkg update && ipkg upgrade", "r").readlines()
42 self["text"].setText(_("Updating finished. Here is the result:") + "\n\n" + string)
46 def doUpdate(self, val = False):
48 self["text"].setText(_("Updating... Please wait... This can take some minutes..."))
49 self.delayTimer.start(0, 1)
59 return "/usr/lib/enigma2/python/Plugins/update.png"
62 return "Softwareupdate"