| 439 | } |
| 440 | |
| 441 | QVariant FolderModel::headerData(int section, |
| 442 | Qt::Orientation orientation, |
| 443 | int role) const |
| 444 | { |
| 445 | if (rootItem == nullptr) { |
| 446 | return QVariant(); |
| 447 | } |
| 448 | |
| 449 | if (orientation == Qt::Horizontal && role == Qt::DisplayRole) |
| 450 | return rootItem->data(section); |
| 451 | |
| 452 | return QVariant(); |
| 453 | } |
| 454 | |
| 455 | QModelIndex FolderModel::index(int row, int column, const QModelIndex &parent) |
| 456 | const |