From d1eee777aa2740463cf72fd171fba29e2fa09aee Mon Sep 17 00:00:00 2001 From: Cacodemon345 Date: Wed, 27 Apr 2022 22:09:57 +0600 Subject: [PATCH 1/2] Fix accidental changes --- src/qt/qt_settings.cpp | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/src/qt/qt_settings.cpp b/src/qt/qt_settings.cpp index 1a5b3fdc7..cab7cffbb 100644 --- a/src/qt/qt_settings.cpp +++ b/src/qt/qt_settings.cpp @@ -43,6 +43,8 @@ extern "C" #include #include #include +#include +#include class SettingsModel : public QAbstractListModel { public: @@ -104,13 +106,6 @@ Settings::Settings(QWidget *parent) : { ui->setupUi(this); - ui->listView->setModel(new SettingsModel(this)); - ui->listView->setFlow(QListView::TopToBottom); - ui->listView->setWrapping(false); - ui->listView->setWordWrap(true); - ui->listView->setItemAlignment(Qt::AlignmentFlag::AlignHCenter); - ui->listView->setUniformItemSizes(true); - Harddrives::busTrackClass = new SettingsBusTracking; machine = new SettingsMachine(this); display = new SettingsDisplay(this); @@ -147,6 +142,8 @@ Settings::Settings(QWidget *parent) : ui->stackedWidget->setCurrentIndex(current.row()); }); + ui->listView->setMaximumWidth(ui->listView->sizeHintForColumn(0) + qApp->style()->pixelMetric(QStyle::PM_ScrollBarExtent)); + Settings::settings = this; } From 13ce39bd4679a1f71b9867ef12ca101967506ee8 Mon Sep 17 00:00:00 2001 From: Cacodemon345 Date: Wed, 27 Apr 2022 22:34:07 +0600 Subject: [PATCH 2/2] Part 2 --- src/qt/qt_settings.ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qt/qt_settings.ui b/src/qt/qt_settings.ui index a5774a8d3..ec3198ebe 100644 --- a/src/qt/qt_settings.ui +++ b/src/qt/qt_settings.ui @@ -32,7 +32,7 @@ - QListView::IconMode + QListView::ListMode