X-Git-Url: https://codewiz.org/gitweb?a=blobdiff_plain;f=wizard%2FBVersionPage.py;h=0db1bd6217662a475cb3a5ea3c1df1e1f58b5d91;hb=d16b0a0095e469436014c2b647f0531cc0ed1d06;hp=e4cb8d2ca90a2b52779ba56f3c0ebca2d04bc10f;hpb=107cf69bcaae23a972ff33a805c60a37bd0a1238;p=bertos.git diff --git a/wizard/BVersionPage.py b/wizard/BVersionPage.py index e4cb8d2c..0db1bd62 100644 --- a/wizard/BVersionPage.py +++ b/wizard/BVersionPage.py @@ -4,7 +4,7 @@ # Copyright 2008 Develer S.r.l. (http://www.develer.com/) # All rights reserved. # -# $Id:$ +# $Id$ # # Author: Lorenzo Berni # @@ -26,7 +26,8 @@ class BVersionPage(BWizardPage): def __init__(self): BWizardPage.__init__(self, UI_LOCATION + "/bertos_versions.ui") - self.setTitle(self.tr("Select the BeRTOS version needed")) + self.setTitle(self.tr("Select the BeRTOS directory")) + self.setSubTitle(self.tr("The project created will be based on the BeRTOS version found")) ## Overloaded QWizardPage methods ## @@ -36,7 +37,7 @@ class BVersionPage(BWizardPage): """ if self.pageContent.versionList.currentRow() != -1: sources_path = qvariant_converter.getString(self.pageContent.versionList.currentItem().data(Qt.UserRole)) - ## Remove the trailing slash + # Remove the trailing slash if sources_path.endswith(os.sep): sources_path = sources_path[:-1] self.setProjectInfo("SOURCES_PATH", sources_path) @@ -62,9 +63,16 @@ class BVersionPage(BWizardPage): """ Overload of the BWizardPage reloadData method. """ + self.resetVersionList() self.pageContent.versionList.setCurrentRow(-1) self.fillVersionList() + def setupUi(self): + """ + Overload of the BWizardPage setupUi method. + """ + self.pageContent.updateButton.setVisible(False) + #### ## Slots ## @@ -118,7 +126,13 @@ class BVersionPage(BWizardPage): versions = self.versions() versions.remove(directory) self.setVersions(versions) - + + def resetVersionList(self): + """ + Remove all the version entries from the list. + """ + self.pageContent.versionList.clear() + def insertListElement(self, directory): """ Inserts the given directory in the version list and returns the