Change return type of qHash with Qt 6 to size_t
This commit is contained in:
@@ -84,7 +84,11 @@ bool PlaylistFilter::filterAcceptsRow(int row, const QModelIndex &parent) const
|
||||
QString filter = filterRegExp().pattern();
|
||||
#endif
|
||||
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
|
||||
size_t hash = qHash(filter);
|
||||
#else
|
||||
uint hash = qHash(filter);
|
||||
#endif
|
||||
if (hash != query_hash_) {
|
||||
// Parse the query
|
||||
FilterParser p(filter, column_names_, numerical_columns_);
|
||||
|
||||
@@ -47,10 +47,14 @@ class PlaylistFilter : public QSortFilterProxyModel {
|
||||
// public so Playlist::NextVirtualIndex and friends can get at it
|
||||
bool filterAcceptsRow(int source_row, const QModelIndex &source_parent) const override;
|
||||
|
||||
private:
|
||||
private:
|
||||
// Mutable because they're modified from filterAcceptsRow() const
|
||||
mutable QScopedPointer<FilterTree> filter_tree_;
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
|
||||
mutable size_t query_hash_;
|
||||
#else
|
||||
mutable uint query_hash_;
|
||||
#endif
|
||||
|
||||
QMap<QString, int> column_names_;
|
||||
QSet<int> numerical_columns_;
|
||||
|
||||
Reference in New Issue
Block a user