Add the isComplete implementation for the second page
authorduplo <duplo@38d2e660-2303-0410-9eaa-f027e97ec537>
Tue, 16 Dec 2008 09:34:10 +0000 (09:34 +0000)
committerduplo <duplo@38d2e660-2303-0410-9eaa-f027e97ec537>
Tue, 16 Dec 2008 09:34:10 +0000 (09:34 +0000)
git-svn-id: https://src.develer.com/svnoss/bertos/trunk@2035 38d2e660-2303-0410-9eaa-f027e97ec537

wizard/BVersionPage.py

index a98beca17d5c3930d00fc0144123d6593c737d87..f5e9099d5a1cd53609700a4e489242d0f965b77e 100644 (file)
@@ -58,20 +58,25 @@ class BVersionPage(BWizardPage):
         for directory in versions:
             self._insertListElement(directory.toString())
 
+    def isComplete(self):
+        return self.pageContent.versionList.currentRow() != -1
+    
     def addVersion(self):
         directory = QFileDialog.getExistingDirectory(self, self.tr("Choose a directory"), "", QFileDialog.ShowDirsOnly | QFileDialog.DontResolveSymlinks)
         if not directory.isEmpty():
             self._storeVersion(directory)
             self.pageContent.versionList.clear()
             self._fillVersionList()
+            self.emit(SIGNAL("completeChanged()"))
     
     def removeVersion(self):
         item = self.pageContent.versionList.takeItem(self.pageContent.versionList.currentRow())
         self._deleteVersion(item.data(Qt.UserRole).toString())
+        self.emit(SIGNAL("completeChanged()"))
     
     def updateClicked(self):
         print "fake update checking"
     
     def itemClicked(self, item):
-        print "clicked", repr(item)
+        self.emit(SIGNAL("completeChanged()"))
     
\ No newline at end of file