summaryrefslogtreecommitdiffstats
path: root/src/corelib/itemmodels/qabstractitemmodel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/corelib/itemmodels/qabstractitemmodel.cpp')
-rw-r--r--src/corelib/itemmodels/qabstractitemmodel.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/corelib/itemmodels/qabstractitemmodel.cpp b/src/corelib/itemmodels/qabstractitemmodel.cpp
index 989456efbb..f152dec5e6 100644
--- a/src/corelib/itemmodels/qabstractitemmodel.cpp
+++ b/src/corelib/itemmodels/qabstractitemmodel.cpp
@@ -1679,6 +1679,9 @@ bool QAbstractItemModel::hasIndex(int row, int column, const QModelIndex &parent
Use rowCount() on the parent to find out the number of children.
+ Note that it is undefined behavior to report that a particular index hasChildren
+ with this method if the same index has the flag Qt::ItemNeverHasChildren set.
+
\sa parent(), index()
*/
bool QAbstractItemModel::hasChildren(const QModelIndex &parent) const
@@ -2109,9 +2112,8 @@ void QAbstractItemModel::fetchMore(const QModelIndex &)
The default implementation always returns false.
- If canFetchMore() returns true, QAbstractItemView will call fetchMore().
- However, the fetchMore() function is only called when the model is being
- populated incrementally.
+ If canFetchMore() returns true, the fetchMore() function should
+ be called. This is the behavior of QAbstractItemView, for example.
\sa fetchMore()
*/