From 1ddc1613b03c97b8ef84c4657c5fbc82e86fa32b Mon Sep 17 00:00:00 2001 From: duplo Date: Mon, 14 Jun 2010 08:54:40 +0000 Subject: [PATCH] Fix ticket #97. Now when a module is automatically unselected the font is reverted to normal (not bold). git-svn-id: https://src.develer.com/svnoss/bertos/trunk@3923 38d2e660-2303-0410-9eaa-f027e97ec537 --- wizard/BModulePage.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/wizard/BModulePage.py b/wizard/BModulePage.py index 6e40c7f1..72b0f9da 100644 --- a/wizard/BModulePage.py +++ b/wizard/BModulePage.py @@ -410,6 +410,9 @@ class BModulePage(BWizardPage): item.setFont(0, font) self.pageContent.moduleTree.blockSignals(False) + def isBold(self, item): + return item.font(0).bold() + def moduleSelected(self, selectedModule): """ Resolves the selection dependencies. @@ -473,9 +476,14 @@ class BModulePage(BWizardPage): modules[module]["enabled"] = False for category in range(self.pageContent.moduleTree.topLevelItemCount()): item = self.pageContent.moduleTree.topLevelItem(category) + self.setBold(item, False) for child in range(item.childCount()): if unicode(item.child(child).text(0)) in unsatisfied: + self.setBold(item.child(child), False) item.child(child).setCheckState(0, Qt.Unchecked) + else: + if self.isBold(item.child(child)): + self.setBold(item, True) for module, param in unsatisfied_params: configuration_file = self.projectInfo("MODULES")[module]["configuration"] configurations = self.projectInfo("CONFIGURATIONS") -- 2.25.1