-
- def toSearchSubpage(self):
- self.pageContent.pageSelector.setCurrentIndex(1)
-
- def toSelectionSubpage(self):
- self.pageContent.pageSelector.setCurrentIndex(0)
-
- def doSearch(self):
- path = []
- if self.pageContent.pathBox.isChecked():
- path += bertos_utils.getSystemPath()
- if self.pageContent.customDirBox.isChecked():
- for element in range(self.pageContent.customDirList.count()):
- path += [unicode(self.pageContent.customDirList.item(element).data(Qt.UserRole).toString())]
- toolchains = bertos_utils.findToolchains(path)
- toolchains_stored = self._settingsRetrieve("toolchains").toList()
- toolchains += [unicode(toolchain.toString()) for toolchain in toolchains_stored]
- toolchains = set(toolchains)
- toolchains = list(toolchains)
- self._clearList()
- for toolchain in toolchains:
- item = QListWidgetItem(toolchain)
- item.setData(Qt.UserRole, QVariant(toolchain))
- self.pageContent.toolchainList.addItem(item)
- self._settingsStore("toolchains", toolchains)
- self.toSelectionSubpage()