Exemplo n.º 1
0
 def data(self, index, role):
     if role == Qt.DecorationRole:
         w = self.widgets[index.row()]
         if w.ICON:
             return QVariant(QIcon(w.ICON))
     return QStringListModel.data(self, index, role)
Exemplo n.º 2
0
 def data(self, index, role):
     if role == Qt.DecorationRole:
         w = self.widgets[index.row()]
         if w.ICON:
             return QVariant(QIcon(w.ICON))
     return QStringListModel.data(self, index, role)