From: duplo Date: Thu, 8 Jan 2009 10:50:54 +0000 (+0000) Subject: Modify the timout of the validation process and the result rapresentation X-Git-Tag: 2.1.0~546 X-Git-Url: https://codewiz.org/gitweb?a=commitdiff_plain;h=595b7ac4403cebcc30244eebc14b31e487d1da16;p=bertos.git Modify the timout of the validation process and the result rapresentation git-svn-id: https://src.develer.com/svnoss/bertos/trunk@2136 38d2e660-2303-0410-9eaa-f027e97ec537 --- diff --git a/wizard/BToolchainPage.py b/wizard/BToolchainPage.py index 6c43ec10..567fbcee 100644 --- a/wizard/BToolchainPage.py +++ b/wizard/BToolchainPage.py @@ -71,12 +71,11 @@ class BToolchainPage(BWizardPage): def _validItem(self, index, infos): item = self.pageContent.toolchainList.item(index) needed = self._projectInfoRetrieve("CPU_INFOS") - if infos["target"].find(unicode(needed[QString("TOOLCHAIN")])) != -1: + if infos["target"].find(unicode(needed[QString("TOOLCHAIN")].toString())) != -1: item.setIcon(QIcon(":/images/ok.png")) else: item.setIcon(QIcon(":/images/warning.png")) - item.setToolTip("Version: " + infos["version"] + "
Target: " + infos["target"] + - "
Thread model: " + infos["thread"]) + item.setText(infos["version"] + " " + infos["target"]) def _invalidItem(self, index): item = self.pageContent.toolchainList.item(index) @@ -108,11 +107,11 @@ class BToolchainPage(BWizardPage): def validateToolchains(self): for i in range(self.pageContent.toolchainList.count()): - filename = self.pageContent.toolchainList.item(i).text() + filename = unicode(self.pageContent.toolchainList.item(i).data(Qt.UserRole).toString()) self._validationProcess = QProcess() self._validationProcess.start(filename, ["-v"]) - self._validationProcess.waitForStarted(10) - if self._validationProcess.waitForFinished(20): + self._validationProcess.waitForStarted(1000) + if self._validationProcess.waitForFinished(200): description = str(self._validationProcess.readAllStandardError()) infos = bertos_utils.getToolchainInfo(description) if len(infos.keys()) == 4: