aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorleo78913 <leo3758@riseup.net>2022-12-15 16:34:52 -0300
committerleo78913 <leo3758@riseup.net>2022-12-15 16:34:52 -0300
commitc8d8dda79a8ac184c98922372ef7c3531f897486 (patch)
treeeb3a3634bc052e8eb73ba9f5c1f96e2566e610a1
parentaaef4489593e56cf2a8cbd94bb882c7114c93512 (diff)
downloadPrismLauncher-c8d8dda79a8ac184c98922372ef7c3531f897486.tar.gz
PrismLauncher-c8d8dda79a8ac184c98922372ef7c3531f897486.tar.bz2
PrismLauncher-c8d8dda79a8ac184c98922372ef7c3531f897486.zip
fix: only show scrollbars when needed
Signed-off-by: leo78913 <leo3758@riseup.net>
-rw-r--r--launcher/ui/dialogs/IconPickerDialog.cpp1
-rw-r--r--launcher/ui/dialogs/ImportResourcePackDialog.cpp1
-rw-r--r--launcher/ui/pages/instance/NotesPage.ui3
-rw-r--r--launcher/ui/pages/instance/OtherLogsPage.ui3
-rw-r--r--launcher/ui/pages/instance/VersionPage.ui3
-rw-r--r--launcher/ui/widgets/ModListView.cpp1
6 files changed, 0 insertions, 12 deletions
diff --git a/launcher/ui/dialogs/IconPickerDialog.cpp b/launcher/ui/dialogs/IconPickerDialog.cpp
index fcb645db..6fa26508 100644
--- a/launcher/ui/dialogs/IconPickerDialog.cpp
+++ b/launcher/ui/dialogs/IconPickerDialog.cpp
@@ -47,7 +47,6 @@ IconPickerDialog::IconPickerDialog(QWidget *parent)
contentsWidget->setUniformItemSizes(true);
contentsWidget->setTextElideMode(Qt::ElideRight);
contentsWidget->setVerticalScrollMode(QAbstractItemView::ScrollPerPixel);
- contentsWidget->setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOn);
contentsWidget->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
contentsWidget->setItemDelegate(new ListViewDelegate());
diff --git a/launcher/ui/dialogs/ImportResourcePackDialog.cpp b/launcher/ui/dialogs/ImportResourcePackDialog.cpp
index e807e926..e8902656 100644
--- a/launcher/ui/dialogs/ImportResourcePackDialog.cpp
+++ b/launcher/ui/dialogs/ImportResourcePackDialog.cpp
@@ -29,7 +29,6 @@ ImportResourcePackDialog::ImportResourcePackDialog(QWidget* parent) : QDialog(pa
// NOTE: We can't have uniform sizes because the text may wrap if it's too long. If we set this, it will cut off the wrapped text.
contentsWidget->setUniformItemSizes(false);
contentsWidget->setVerticalScrollMode(QAbstractItemView::ScrollPerPixel);
- contentsWidget->setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOn);
contentsWidget->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
contentsWidget->setItemDelegate(new ListViewDelegate());
diff --git a/launcher/ui/pages/instance/NotesPage.ui b/launcher/ui/pages/instance/NotesPage.ui
index 67cb261c..5f1984ad 100644
--- a/launcher/ui/pages/instance/NotesPage.ui
+++ b/launcher/ui/pages/instance/NotesPage.ui
@@ -25,9 +25,6 @@
</property>
<item>
<widget class="QTextEdit" name="noteEditor">
- <property name="verticalScrollBarPolicy">
- <enum>Qt::ScrollBarAlwaysOn</enum>
- </property>
<property name="tabChangesFocus">
<bool>true</bool>
</property>
diff --git a/launcher/ui/pages/instance/OtherLogsPage.ui b/launcher/ui/pages/instance/OtherLogsPage.ui
index 77f3e647..3fdb023f 100644
--- a/launcher/ui/pages/instance/OtherLogsPage.ui
+++ b/launcher/ui/pages/instance/OtherLogsPage.ui
@@ -48,9 +48,6 @@
<property name="enabled">
<bool>false</bool>
</property>
- <property name="verticalScrollBarPolicy">
- <enum>Qt::ScrollBarAlwaysOn</enum>
- </property>
<property name="readOnly">
<bool>true</bool>
</property>
diff --git a/launcher/ui/pages/instance/VersionPage.ui b/launcher/ui/pages/instance/VersionPage.ui
index 74b9568a..4cd50885 100644
--- a/launcher/ui/pages/instance/VersionPage.ui
+++ b/launcher/ui/pages/instance/VersionPage.ui
@@ -28,9 +28,6 @@
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="ModListView" name="packageView">
- <property name="verticalScrollBarPolicy">
- <enum>Qt::ScrollBarAlwaysOn</enum>
- </property>
<property name="horizontalScrollBarPolicy">
<enum>Qt::ScrollBarAlwaysOff</enum>
</property>
diff --git a/launcher/ui/widgets/ModListView.cpp b/launcher/ui/widgets/ModListView.cpp
index c8ccd292..d1860f57 100644
--- a/launcher/ui/widgets/ModListView.cpp
+++ b/launcher/ui/widgets/ModListView.cpp
@@ -31,7 +31,6 @@ ModListView::ModListView ( QWidget* parent )
setSelectionMode ( QAbstractItemView::ExtendedSelection );
setHeaderHidden ( false );
setSelectionBehavior(QAbstractItemView::SelectRows);
- setVerticalScrollBarPolicy ( Qt::ScrollBarAlwaysOn );
setHorizontalScrollBarPolicy ( Qt::ScrollBarAsNeeded );
setDropIndicatorShown(true);
setDragEnabled(true);