MCPcopy Create free account
hub / github.com/YACReader/yacreader / rowCount

Method rowCount

YACReaderLibrary/db/folder_model.cpp:509–525  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

507}
508
509int FolderModel::rowCount(const QModelIndex &parent) const
510{
511 FolderItem *parentItem;
512 if (parent.column() > 0)
513 return 0;
514
515 if (!parent.isValid()) {
516 if (rootItem == nullptr) {
517 return 0;
518 }
519 parentItem = rootItem;
520 } else {
521 parentItem = static_cast<FolderItem *>(parent.internalPointer());
522 }
523
524 return parentItem->childCount();
525}
526
527void FolderModel::setupModelData(QString path)
528{

Callers

nothing calls this directly

Calls 2

isValidMethod · 0.45
childCountMethod · 0.45

Tested by

no test coverage detected