| 184 | } |
| 185 | |
| 186 | QVariant DeviceModel::data(const QModelIndex &index, int role) const { |
| 187 | if (!index.isValid()) |
| 188 | return {}; |
| 189 | Node *n = nodeFor(index); |
| 190 | if (role == Qt::DisplayRole) |
| 191 | return n->label; |
| 192 | if (role == Qt::DecorationRole) |
| 193 | return resolveIcon(n->iconName); |
| 194 | return {}; |
| 195 | } |
| 196 | |
| 197 | QVariant DeviceModel::headerData(int, Qt::Orientation, int) const { |
| 198 | return {}; |
no test coverage detected