PluginManager/PluginInfoDialog.py

changeset 6080
436ac20f7639
parent 6048
82ad8ec9548c
child 6645
ad476851d7e0
equal deleted inserted replaced
6079:1a6e142fb181 6080:436ac20f7639
66 66
67 def __createEntry(self, info): 67 def __createEntry(self, info):
68 """ 68 """
69 Private method to create a list entry based on the provided info. 69 Private method to create a list entry based on the provided info.
70 70
71 @param info tuple giving the info for the entry 71 @param info dictionary giving the info for the entry (as returned by
72 PluginManager.getPluginInfos())
73 @type dict
72 """ 74 """
73 infoList = [ 75 infoList = [
74 info[0], 76 info["module_name"],
75 info[1], 77 info["plugin_name"],
76 info[2], 78 info["version"],
77 (info[3] and self.tr("Yes") or self.tr("No")), 79 (info["auto_activate"] and self.tr("Yes") or self.tr("On-Demand")),
78 (info[4] and self.tr("Yes") or self.tr("No")), 80 (info["active"] and self.tr("Yes") or self.tr("No")),
79 info[5] 81 info["short_desc"]
80 ] 82 ]
81 itm = QTreeWidgetItem(self.pluginList, infoList) 83 itm = QTreeWidgetItem(self.pluginList, infoList)
82 if info[6]: 84 if info["error"]:
83 # plugin error 85 # plugin error
84 for col in range(self.pluginList.columnCount()): 86 for col in range(self.pluginList.columnCount()):
85 itm.setForeground(col, QBrush(Qt.red)) 87 itm.setForeground(col, QBrush(Qt.red))
86 itm.setTextAlignment(self.__autoActivateColumn, Qt.AlignHCenter) 88 itm.setTextAlignment(self.__autoActivateColumn, Qt.AlignHCenter)
87 itm.setTextAlignment(self.__activeColumn, Qt.AlignHCenter) 89 itm.setTextAlignment(self.__activeColumn, Qt.AlignHCenter)

eric ide

mercurial