aboutsummaryrefslogtreecommitdiff
path: root/lib/python/Screens
diff options
context:
space:
mode:
authorFelix Domke <tmbinc@elitedvb.net>2008-02-11 14:12:52 +0000
committerFelix Domke <tmbinc@elitedvb.net>2008-02-11 14:12:52 +0000
commit5bc8209d19e1d41f289cfe198e4e3a839adf894b (patch)
tree34a7906db00712fd20837887212223f50236979b /lib/python/Screens
parentb6748e04393c47c18453c2d2fda88e315aa9d55d (diff)
downloadenigma2-5bc8209d19e1d41f289cfe198e4e3a839adf894b.tar.gz
enigma2-5bc8209d19e1d41f289cfe198e4e3a839adf894b.zip
add a 'priority' for wizard screens to define the run order
Diffstat (limited to 'lib/python/Screens')
-rw-r--r--lib/python/Screens/ImageWizard.py2
-rw-r--r--lib/python/Screens/StartWizard.py5
-rw-r--r--lib/python/Screens/TutorialWizard.py2
-rw-r--r--lib/python/Screens/Wizard.py6
4 files changed, 7 insertions, 8 deletions
diff --git a/lib/python/Screens/ImageWizard.py b/lib/python/Screens/ImageWizard.py
index 148eba52..ad0640cf 100644
--- a/lib/python/Screens/ImageWizard.py
+++ b/lib/python/Screens/ImageWizard.py
@@ -34,7 +34,7 @@ class ImageWizard(Wizard):
def markDone(self):
pass
-wizardManager.registerWizard(ImageWizard, backupAvailable)
+wizardManager.registerWizard(ImageWizard, backupAvailable, priority = 10)
def doBackup(path):
os.system('tar cvpf ' + path + backupfile + ' /etc/enigma2')
diff --git a/lib/python/Screens/StartWizard.py b/lib/python/Screens/StartWizard.py
index 0424771a..a60e3d2a 100644
--- a/lib/python/Screens/StartWizard.py
+++ b/lib/python/Screens/StartWizard.py
@@ -41,7 +41,6 @@ class StartWizard(Wizard):
config.misc.firstrun.save()
configfile.save()
-wizardManager.registerWizard(LanguageSelection, config.misc.languageselected.value)
+wizardManager.registerWizard(LanguageSelection, config.misc.languageselected.value, priority = 5)
#wizardManager.registerWizard(DefaultWizard, config.misc.defaultchosen.value)
-wizardManager.registerWizard(StartWizard, config.misc.firstrun.value)
-
+wizardManager.registerWizard(StartWizard, config.misc.firstrun.value, priority = 20)
diff --git a/lib/python/Screens/TutorialWizard.py b/lib/python/Screens/TutorialWizard.py
index c90ed365..9e97b7e7 100644
--- a/lib/python/Screens/TutorialWizard.py
+++ b/lib/python/Screens/TutorialWizard.py
@@ -30,4 +30,4 @@ class TutorialWizard(Wizard):
config.misc.firstruntutorial.value = False
config.misc.firstruntutorial.save()
-#wizardManager.registerWizard(TutorialWizard, config.misc.firstruntutorial.value)
+#wizardManager.registerWizard(TutorialWizard, config.misc.firstruntutorial.value, priority = 30)
diff --git a/lib/python/Screens/Wizard.py b/lib/python/Screens/Wizard.py
index e574f861..1b133152 100644
--- a/lib/python/Screens/Wizard.py
+++ b/lib/python/Screens/Wizard.py
@@ -459,14 +459,14 @@ class WizardManager:
def __init__(self):
self.wizards = []
- def registerWizard(self, wizard, precondition):
- self.wizards.append((wizard, precondition))
+ def registerWizard(self, wizard, precondition, priority = 0):
+ self.wizards.append((wizard, precondition, priority))
def getWizards(self):
list = []
for x in self.wizards:
if x[1] == 1: # precondition
- list.append(x[0])
+ list.append((x[2], x[0]))
return list
wizardManager = WizardManager()