Add the cpus in the cpu list
authorduplo <duplo@38d2e660-2303-0410-9eaa-f027e97ec537>
Fri, 19 Dec 2008 09:43:30 +0000 (09:43 +0000)
committerduplo <duplo@38d2e660-2303-0410-9eaa-f027e97ec537>
Fri, 19 Dec 2008 09:43:30 +0000 (09:43 +0000)
git-svn-id: https://src.develer.com/svnoss/bertos/trunk@2098 38d2e660-2303-0410-9eaa-f027e97ec537

wizard/BCpuPage.py
wizard/bertos_utils.py

index 03ef2cc05242e4ad9437c587a0af7235fd6c1a7b..3a526f9ca16bfa22c6430cbff81a617350c8a4db 100644 (file)
@@ -20,9 +20,9 @@ class BCpuPage(BWizardPage):
         self.setTitle(self.tr("Select the CPU"))
     
     def _populateCpuList(self):
-        cpus = bertos_utils.findDefinitions("cdef", self._projectInfoRetrieve("SOURCES_PATH"))
-        for cpu in cpus.keys():
-            self.pageContent.cpuList.addItem(QListWidgetItem(cpu))
+        infos = bertos_utils.loadCpuInfos(self._projectInfoRetrieve("SOURCES_PATH"))
+        for cpu in infos:
+            self.pageContent.cpuList.addItem(QListWidgetItem(cpu["CORE_CPU"]))
     
     def reloadData(self):
         self._populateCpuList()
index fd199632dfb416c1d8a912c91187d14fa51c0e35..b927ec48e1e46906c77b730a0f2e7f5fafef638d 100644 (file)
@@ -36,7 +36,7 @@ def loadCpuInfos(path):
         D = {}
         def include(filename, dict = D, directory=definition[1]):
             execfile(directory + "/" + filename, {}, D)
-        d["include"] = include
+        D["include"] = include
         include(definition[0], D)
         cpuInfos.append(D)
     return cpuInfos