mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-05 07:02:31 -06:00
Simplify natural sort classes interface
Now the comparison function/class should be constructed before usage. This change also make it easier to plug in into various containers which will require a compare function type (such as std::set).
This commit is contained in:
@@ -31,6 +31,8 @@
|
||||
#include <QSortFilterProxyModel>
|
||||
#include <QStringList>
|
||||
|
||||
#include "base/utils/compare.h"
|
||||
|
||||
class SearchSortModel final : public QSortFilterProxyModel
|
||||
{
|
||||
using base = QSortFilterProxyModel;
|
||||
@@ -94,4 +96,6 @@ private:
|
||||
int m_minSeeds, m_maxSeeds;
|
||||
int m_minLeeches, m_maxLeeches;
|
||||
qint64 m_minSize, m_maxSize;
|
||||
|
||||
Utils::Compare::NaturalLessThan<Qt::CaseInsensitive> m_naturalLessThan;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user