Add infrastructure for non-linear Wizard.
authorduplo <duplo@38d2e660-2303-0410-9eaa-f027e97ec537>
Wed, 31 Mar 2010 09:43:22 +0000 (09:43 +0000)
committerduplo <duplo@38d2e660-2303-0410-9eaa-f027e97ec537>
Wed, 31 Mar 2010 09:43:22 +0000 (09:43 +0000)
git-svn-id: https://src.develer.com/svnoss/bertos/trunk@3338 38d2e660-2303-0410-9eaa-f027e97ec537

wizard/BWizard.py

index 096d071d877871d015a2cfada2a2f5f56e02d1e2..11a2dd263b8fc70d584e7f781fe4c4d88865e1bc 100644 (file)
@@ -69,8 +69,12 @@ class BWizard(QWizard):
         """
         Adds the pages in the wizard.
         """
-        for page in page_list:
-            self.addPage(page())
+        self._page_list = page_list
+        for i, page in enumerate(self._page_list):
+            self.setPage(i, page())
+
+    def pageIndex(self, page_class):
+        return self._page_list.index(page_class)
 
     def connectSignals(self):
         """