mirror of
https://invent.kde.org/plasma/plasma-desktop.git
synced 2026-11-03 22:59:45 -09:00
emojier: port away from deprecated invalidateFilter()
invalidateFilter() is deprecated and should be replaced by beginFilterChange() and endFilterChange().
This commit is contained in:
parent
0ce579dd90
commit
5f1564280c
1 changed files with 4 additions and 2 deletions
|
|
@ -284,8 +284,9 @@ QString CategoryModelFilter::category() const
|
|||
void CategoryModelFilter::setCategory(const QString &category)
|
||||
{
|
||||
if (m_category != category) {
|
||||
beginFilterChange();
|
||||
m_category = category;
|
||||
invalidateFilter();
|
||||
endFilterChange(QSortFilterProxyModel::Direction::Rows);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -301,8 +302,9 @@ QString SearchModelFilter::search() const
|
|||
void SearchModelFilter::setSearch(const QString &search)
|
||||
{
|
||||
if (m_search != search) {
|
||||
beginFilterChange();
|
||||
m_search = search;
|
||||
invalidateFilter();
|
||||
endFilterChange(QSortFilterProxyModel::Direction::Rows);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue