Mercurial > minori
comparison src/gui/pages/torrents.cc @ 250:c130f47f6f48
*: many many changes
e.g. the search page is actually implemented now!
| author | Paper <paper@paper.us.eu.org> |
|---|---|
| date | Sun, 04 Feb 2024 21:17:17 -0500 |
| parents | 4d461ef7d424 |
| children | 862d0d8619f6 |
comparison
equal
deleted
inserted
replaced
| 249:6b2441c776dd | 250:c130f47f6f48 |
|---|---|
| 4 #include "core/session.h" | 4 #include "core/session.h" |
| 5 #include "core/filesystem.h" | 5 #include "core/filesystem.h" |
| 6 #include "gui/widgets/text.h" | 6 #include "gui/widgets/text.h" |
| 7 #include "track/media.h" | 7 #include "track/media.h" |
| 8 | 8 |
| 9 #include <QHeaderView> | |
| 9 #include <QVBoxLayout> | 10 #include <QVBoxLayout> |
| 10 #include <QToolBar> | 11 #include <QToolBar> |
| 11 #include <QTreeView> | 12 #include <QTreeView> |
| 12 #include <QMainWindow> | |
| 13 #include <QByteArray> | 13 #include <QByteArray> |
| 14 #include <QDataStream> | 14 #include <QDataStream> |
| 15 #include <QThread> | 15 #include <QThread> |
| 16 #include <QDebug> | 16 #include <QDebug> |
| 17 | 17 |
| 22 | 22 |
| 23 #include "pugixml.hpp" | 23 #include "pugixml.hpp" |
| 24 #include "anitomy/anitomy.h" | 24 #include "anitomy/anitomy.h" |
| 25 | 25 |
| 26 /* This file is very, very similar to the anime list page. | 26 /* This file is very, very similar to the anime list page. |
| 27 | 27 * |
| 28 It differs from Taiga in that it uses tabs instead of | 28 * It differs from Taiga in that it uses tabs instead of |
| 29 those "groups", but those are custom painted and a pain in the ass to | 29 * those "groups", but those are custom painted and a pain in the ass to |
| 30 maintain over multiple platforms. */ | 30 * maintain over multiple platforms. |
| 31 */ | |
| 31 | 32 |
| 32 TorrentsPageListSortFilter::TorrentsPageListSortFilter(QObject* parent) : QSortFilterProxyModel(parent) { | 33 TorrentsPageListSortFilter::TorrentsPageListSortFilter(QObject* parent) : QSortFilterProxyModel(parent) { |
| 33 } | 34 } |
| 34 | 35 |
| 35 bool TorrentsPageListSortFilter::lessThan(const QModelIndex& l, const QModelIndex& r) const { | 36 bool TorrentsPageListSortFilter::lessThan(const QModelIndex& l, const QModelIndex& r) const { |
| 396 treeview->setColumnWidth(TorrentsPageListModel::TL_DOWNLOADS, 20); | 397 treeview->setColumnWidth(TorrentsPageListModel::TL_DOWNLOADS, 20); |
| 397 treeview->setColumnWidth(TorrentsPageListModel::TL_DESCRIPTION, 200); | 398 treeview->setColumnWidth(TorrentsPageListModel::TL_DESCRIPTION, 200); |
| 398 treeview->setColumnWidth(TorrentsPageListModel::TL_FILENAME, 200); | 399 treeview->setColumnWidth(TorrentsPageListModel::TL_FILENAME, 200); |
| 399 treeview->setColumnWidth(TorrentsPageListModel::TL_RELEASEDATE, 190); | 400 treeview->setColumnWidth(TorrentsPageListModel::TL_RELEASEDATE, 190); |
| 400 | 401 |
| 402 treeview->header()->setStretchLastSection(false); | |
| 403 | |
| 401 layout->addWidget(treeview); | 404 layout->addWidget(treeview); |
| 402 } | 405 } |
| 403 } | 406 } |
| 404 | 407 |
| 405 void TorrentsPage::DownloadSelection() { | 408 void TorrentsPage::DownloadSelection() { |
