X-Git-Url: https://codewiz.org/gitweb?a=blobdiff_plain;f=wizard%2FBCreationPage.py;h=c6c74a4e1f0b65e5e3287e72e433205fff15ec4a;hb=74787ad8b91866fea9188acfc63b4aa47140ac32;hp=e865a2cc2d89c757a7b41185f15c33a679a7dc5c;hpb=97903dc626136396587334b1d78f7623c91e9934;p=bertos.git diff --git a/wizard/BCreationPage.py b/wizard/BCreationPage.py index e865a2cc..c6c74a4e 100644 --- a/wizard/BCreationPage.py +++ b/wizard/BCreationPage.py @@ -4,7 +4,7 @@ # Copyright 2009 Develer S.r.l. (http://www.develer.com/) # All rights reserved. # -# $Id:$ +# $Id$ # # Author: Lorenzo Berni # @@ -50,10 +50,15 @@ class BCreationPage(BWizardPage): top_level.append(cpu_title) toolchain_title = QTreeWidgetItem(QStringList([self.tr("Toolchain")])) toolchain_info = self.projectInfo("TOOLCHAIN") - if "target" in toolchain_info.keys(): + if "target" in toolchain_info: toolchain_target = QTreeWidgetItem(toolchain_title, QStringList([self.tr("target: " + toolchain_info["target"])])) - if "version" in toolchain_info.keys(): - toolchain_target = QTreeWidgetItem(toolchain_title, QStringList([self.tr("version: " + "GCC " + toolchain_info["version"] + " (" + toolchain_info["build"] + ")")])) + version = "" + if "version" in toolchain_info: + version += "version: " + "GCC " + toolchain_info["version"] + " " + if "build" in toolchain_info: + version += "(" + toolchain_info["build"] + ")" + if "version" in toolchain_info: + toolchain_target = QTreeWidgetItem(toolchain_title, QStringList([version])) toolchain_path = QTreeWidgetItem(toolchain_title, QStringList([self.tr("path: " + os.path.normpath(toolchain_info["path"]))])) top_level.append(toolchain_title) module_title = QTreeWidgetItem(QStringList([self.tr("Modules")])) @@ -61,7 +66,7 @@ class BCreationPage(BWizardPage): module_categories = {} for module, information in self.projectInfo("MODULES").items(): if information["enabled"]: - if information["category"] not in module_categories.keys(): + if information["category"] not in module_categories: module_categories[information["category"]] = [] moduleItem = QTreeWidgetItem(QStringList([module + " - " + information["description"]])) module_categories[information["category"]].append(moduleItem)