Use a scrollbar when there are too many drives

Closes #9
This commit is contained in:
spiros
2024-06-20 22:06:29 +03:00
parent 44209e3666
commit e558fda185
2 changed files with 34 additions and 2 deletions

View File

@@ -13,7 +13,10 @@ MainWindow::MainWindow(QWidget *parent)
buttonGroup = new QButtonGroup(this);
buttonGroup->setExclusive(true);
horizontalLayout = ui->horizontalLayout;
QWidget *containerWidget = ui->scrollAreaWidgetContents;
horizontalLayout = new QHBoxLayout(containerWidget);
horizontalLayout->setContentsMargins(0, 0, 0, 0);
ui->scrollArea->setWidget(containerWidget);
diskName = qobject_cast<QLabel *>(ui->centralwidget->findChild<QLabel*>("diskName"));
temperatureValue = qobject_cast<QLabel *>(ui->centralwidget->findChild<QLabel*>("temperatureValueLabel"));