diff options
author | Christian Ehrlicher <ch.ehrlicher@gmx.de> | 2020-03-08 19:52:18 +0100 |
---|---|---|
committer | Christian Ehrlicher <ch.ehrlicher@gmx.de> | 2020-03-09 06:29:25 +0100 |
commit | 3702a4c37e06a989cdd1cf19a26bc0d1c3fba07c (patch) | |
tree | b45eba708f79c5977639b75556d8174967c48296 | |
parent | c1bb6285720513b9b22b552ca30af3c1501a7761 (diff) |
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 <szehowe.koh@gmail.com>
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
-rw-r--r-- | src/corelib/itemmodels/qsortfilterproxymodel.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
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. |