summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/downloadlist.cpp2
-rw-r--r--src/downloadlist.h4
-rw-r--r--src/downloadstab.cpp2
3 files changed, 5 insertions, 3 deletions
diff --git a/src/downloadlist.cpp b/src/downloadlist.cpp
index 3cfc1fea..a5c284e6 100644
--- a/src/downloadlist.cpp
+++ b/src/downloadlist.cpp
@@ -209,7 +209,7 @@ void DownloadList::update(int row)
log::error("invalid row {} in download list, update failed", row);
}
-bool DownloadList::lessThan(const QModelIndex &left, const QModelIndex &right)
+bool DownloadList::lessThanPredicate(const QModelIndex &left, const QModelIndex &right)
{
int leftIndex = left.row();
int rightIndex = right.row();
diff --git a/src/downloadlist.h b/src/downloadlist.h
index c40bbac5..2171c013 100644
--- a/src/downloadlist.h
+++ b/src/downloadlist.h
@@ -85,7 +85,9 @@ public:
**/
virtual QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const;
- bool lessThan(const QModelIndex &left, const QModelIndex &right);
+ // used in DownloadsTab as the sorting predicate for the filter widget
+ //
+ bool lessThanPredicate(const QModelIndex &left, const QModelIndex &right);
public slots:
diff --git a/src/downloadstab.cpp b/src/downloadstab.cpp
index f5258724..a0602ede 100644
--- a/src/downloadstab.cpp
+++ b/src/downloadstab.cpp
@@ -22,7 +22,7 @@ DownloadsTab::DownloadsTab(OrganizerCore& core, Ui::MainWindow* mwui)
m_filter.setEdit(ui.filter);
m_filter.setList(ui.list);
m_filter.setSortPredicate([sourceModel](auto&& left, auto&& right) {
- return sourceModel->lessThan(left, right);
+ return sourceModel->lessThanPredicate(left, right);
});
connect(ui.refresh, &QPushButton::clicked, [&]{ refresh(); });