From 3702a4c37e06a989cdd1cf19a26bc0d1c3fba07c Mon Sep 17 00:00:00 2001 From: Christian Ehrlicher Date: Sun, 8 Mar 2020 19:52:18 +0100 Subject: QSortFilterProxyModel doc: do not mention deprecated function reset() QSFPM::reset() is deprecated and begin/endResetModel() should be used. Therefore adjust the documentation to reflect this. Fixes: QTBUG-82470 Change-Id: I786b3f25e5674d97d0ef6a0c91342973d5e952e9 Reviewed-by: Sze Howe Koh Reviewed-by: Paul Wicking --- src/corelib/itemmodels/qsortfilterproxymodel.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/corelib/itemmodels/qsortfilterproxymodel.cpp b/src/corelib/itemmodels/qsortfilterproxymodel.cpp index 61d37d5062..122b95ed57 100644 --- a/src/corelib/itemmodels/qsortfilterproxymodel.cpp +++ b/src/corelib/itemmodels/qsortfilterproxymodel.cpp @@ -1949,8 +1949,9 @@ void QSortFilterProxyModelPrivate::_q_sourceColumnsMoved( example.) If you are working with large amounts of filtering and have to invoke - invalidateFilter() repeatedly, using reset() may be more efficient, - depending on the implementation of your model. However, reset() returns the + invalidateFilter() repeatedly, using beginResetModel() / endResetModel() may + be more efficient, depending on the implementation of your model. However, + beginResetModel() / endResetModel() returns the proxy model to its original state, losing selection information, and will cause the proxy model to be repopulated. -- cgit v1.2.3