Details
-
Bug
-
Resolution: Out of scope
-
P2: Important
-
None
-
5.2.0, 5.5.0 Beta
Description
void check(const QModelIndex &idx, QAbstractItemModel *model) { const bool hasChildren = model->hasChildren(idx); const int rowCount = model->rowCount(idx); if (hasChildren) { Q_ASSERT(rowCount > 0); QModelIndex ni = model->index(0, 0, idx); Q_ASSERT(ni.isValid()); check(ni, model); } else { Q_ASSERT(rowCount == 0); } } int main(int argc, char **argv) { QApplication app(argc, argv); QFileSystemModel model; model.setRootPath(QDir::currentPath()); check(QModelIndex(), &model); app.exec(); }
Attachments
Issue Links
- relates to
-
QTBUG-47531 QTreeView on a QFileSystemModel shows children indicators even on empty directories
- Reported
-
QTCREATORBUG-26886 Bugs when creating new folder from File System View
- Closed