Add scrollbar to Select filters dialog (#3737)

Co-authored-by: pajlada <rasmus.karlsson@pajlada.com>
This commit is contained in:
xel86
2022-05-28 06:25:58 -04:00
committed by GitHub
parent 7d0023cf73
commit 3e1e30e4c2
2 changed files with 11 additions and 1 deletions
@@ -5,6 +5,7 @@
#include <QCheckBox>
#include <QLabel>
#include <QPushButton>
#include <QScrollArea>
#include <QVBoxLayout>
namespace chatterino {
@@ -19,7 +20,15 @@ SelectChannelFiltersDialog::SelectChannelFiltersDialog(
auto okButton = new QPushButton("Ok");
auto cancelButton = new QPushButton("Cancel");
vbox->addLayout(itemVbox);
auto scrollAreaContent = new QWidget;
scrollAreaContent->setLayout(itemVbox);
auto scrollArea = new QScrollArea;
scrollArea->setWidgetResizable(true);
scrollArea->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
scrollArea->setWidget(scrollAreaContent);
vbox->addWidget(scrollArea);
vbox->addLayout(buttonBox);
buttonBox->addStretch(1);