fix: replace deprecated invalidateFilter in Qt6.10#798
Open
uqlidi wants to merge 1 commit into
Open
Conversation
hebasto
reviewed
Jul 18, 2026
Member
There was a problem hiding this comment.
Approach ACK b1d9377.
The testing code seems to require patching as well:
/home/hebasto/dev/bitcoin-qml/test/qml/qml_tests_main.cpp:2923:25: warning: ‘void QSortFilterProxyModel::invalidateFilter()’ is deprecated: Use begin/endFilterChange() instead [-Wdeprecated-declarations]
2923 | invalidateFilter();
| ~~~~~~~~~~~~~~~~^~
In file included from /usr/include/qt6/QtCore/QSortFilterProxyModel:1,
from /home/hebasto/dev/bitcoin-qml/test/qml/qml_tests_main.cpp:15:
/usr/include/qt6/QtCore/qsortfilterproxymodel.h:128:10: note: declared here
128 | void invalidateFilter();
| ^~~~~~~~~~~~~~~~
/home/hebasto/dev/bitcoin-qml/test/qml/qml_tests_main.cpp: In member function ‘void MockActivityFilterProxyModel::setDateFilter(DateFilter)’:
/home/hebasto/dev/bitcoin-qml/test/qml/qml_tests_main.cpp:2933:25: warning: ‘void QSortFilterProxyModel::invalidateFilter()’ is deprecated: Use begin/endFilterChange() instead [-Wdeprecated-declarations]
2933 | invalidateFilter();
| ~~~~~~~~~~~~~~~~^~
/usr/include/qt6/QtCore/qsortfilterproxymodel.h:128:10: note: declared here
128 | void invalidateFilter();
| ^~~~~~~~~~~~~~~~
/home/hebasto/dev/bitcoin-qml/test/qml/qml_tests_main.cpp: In member function ‘void MockActivityFilterProxyModel::setTypeFilter(TypeFilter)’:
/home/hebasto/dev/bitcoin-qml/test/qml/qml_tests_main.cpp:2943:25: warning: ‘void QSortFilterProxyModel::invalidateFilter()’ is deprecated: Use begin/endFilterChange() instead [-Wdeprecated-declarations]
2943 | invalidateFilter();
| ~~~~~~~~~~~~~~~~^~
/usr/include/qt6/QtCore/qsortfilterproxymodel.h:128:10: note: declared here
128 | void invalidateFilter();
| ^~~~~~~~~~~~~~~~
Also feel free to pick ea12a28 from #795 to ensure the CI tests Qt 6.10.
| #else | ||
| invalidateFilter(); | ||
| #endif | ||
|
|
Member
There was a problem hiding this comment.
style nit: Drop this empty line?
| #endif | ||
|
|
||
| m_date_filter = date_filter; | ||
| #if QT_VERSION >= QT_VERSION_CHECK(6, 10, 0) |
Member
There was a problem hiding this comment.
style nit: Add an empty line above for consistency with other similar places?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
replace deprecated
invalidateFilterwithbeginFilterChangeandendFilterChangein >=Qt6.10same solution in bitcoin-core/gui#899
fix #776 #740