mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-05 15:12:32 -06:00
Make sure status filters height is correct when the visual style changes
This commit is contained in:
@@ -4,6 +4,7 @@
|
|||||||
- BUGFIX: Remove old folder when moving a torrent
|
- BUGFIX: Remove old folder when moving a torrent
|
||||||
- BUGFIX: Improved reliability of torrent moving
|
- BUGFIX: Improved reliability of torrent moving
|
||||||
- BUGFIX: Stop rechecking torrents when they are moved
|
- BUGFIX: Stop rechecking torrents when they are moved
|
||||||
|
- BUGFIX: Status filters height stays correct when the visual style changes
|
||||||
- I18N: Added Arabic translation
|
- I18N: Added Arabic translation
|
||||||
|
|
||||||
* Wed Apr 07 2010 - Christophe Dumez <chris@qbittorrent.org> - v2.2.5
|
* Wed Apr 07 2010 - Christophe Dumez <chris@qbittorrent.org> - v2.2.5
|
||||||
|
|||||||
@@ -144,12 +144,32 @@ protected:
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
class StatusFiltersWidget : public QListWidget {
|
||||||
|
public:
|
||||||
|
StatusFiltersWidget(QWidget *parent) : QListWidget(parent) {
|
||||||
|
setFixedHeight(100);
|
||||||
|
}
|
||||||
|
protected:
|
||||||
|
void changeEvent(QEvent *e) {
|
||||||
|
QListWidget::changeEvent(e);
|
||||||
|
switch (e->type()) {
|
||||||
|
case QEvent::StyleChange:
|
||||||
|
setSpacing(0);
|
||||||
|
setFixedHeight(100);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
class TransferListFiltersWidget: public QFrame {
|
class TransferListFiltersWidget: public QFrame {
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
private:
|
private:
|
||||||
QHash<QString, int> customLabels;
|
QHash<QString, int> customLabels;
|
||||||
QListWidget* statusFilters;
|
StatusFiltersWidget* statusFilters;
|
||||||
LabelFiltersList* labelFilters;
|
LabelFiltersList* labelFilters;
|
||||||
QVBoxLayout* vLayout;
|
QVBoxLayout* vLayout;
|
||||||
TransferListWidget *transferList;
|
TransferListWidget *transferList;
|
||||||
@@ -160,7 +180,7 @@ public:
|
|||||||
TransferListFiltersWidget(QWidget *parent, TransferListWidget *transferList): QFrame(parent), transferList(transferList), nb_labeled(0), nb_torrents(0) {
|
TransferListFiltersWidget(QWidget *parent, TransferListWidget *transferList): QFrame(parent), transferList(transferList), nb_labeled(0), nb_torrents(0) {
|
||||||
// Construct lists
|
// Construct lists
|
||||||
vLayout = new QVBoxLayout();
|
vLayout = new QVBoxLayout();
|
||||||
statusFilters = new QListWidget(this);
|
statusFilters = new StatusFiltersWidget(this);
|
||||||
vLayout->addWidget(statusFilters);
|
vLayout->addWidget(statusFilters);
|
||||||
labelFilters = new LabelFiltersList(this);
|
labelFilters = new LabelFiltersList(this);
|
||||||
vLayout->addWidget(labelFilters);
|
vLayout->addWidget(labelFilters);
|
||||||
|
|||||||
Reference in New Issue
Block a user