diff options
Diffstat (limited to 'qt-ui/models.cpp')
-rw-r--r-- | qt-ui/models.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/qt-ui/models.cpp b/qt-ui/models.cpp index 90143b912..68ab402cd 100644 --- a/qt-ui/models.cpp +++ b/qt-ui/models.cpp @@ -660,15 +660,14 @@ int DiveTripModel::rowCount(const QModelIndex& parent) const { TreeItemDT* parentItem; - if (parent.column() > 0) - return 0; - if (!parent.isValid()) parentItem = rootItem; else parentItem = static_cast<TreeItemDT*>(parent.internalPointer()); - return parentItem->childs.count(); + int amount = parentItem->childs.count(); + + return amount; } void DiveTripModel::setupModelData() |