aboutsummaryrefslogtreecommitdiff
path: root/launcher
diff options
context:
space:
mode:
authorSefa Eyeoglu <contact@scrumplex.net>2022-12-13 08:31:52 +0100
committerGitHub <noreply@github.com>2022-12-13 08:31:52 +0100
commit813663485d1443e6f2740857766efe88984a8487 (patch)
treebe2584eba850a81745a7036bf816df706f85e5f7 /launcher
parentaaef4489593e56cf2a8cbd94bb882c7114c93512 (diff)
parent83deccf26651ed7874d2fd8693fb1da661a1d62f (diff)
downloadPrismLauncher-813663485d1443e6f2740857766efe88984a8487.tar.gz
PrismLauncher-813663485d1443e6f2740857766efe88984a8487.tar.bz2
PrismLauncher-813663485d1443e6f2740857766efe88984a8487.zip
Merge pull request #604 from flowln/fix_crash_with_gtk2
fix: crash with GTK2 theme due to QProxyStyle in ManagedPackPage
Diffstat (limited to 'launcher')
-rw-r--r--launcher/ui/pages/instance/ManagedPackPage.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/launcher/ui/pages/instance/ManagedPackPage.cpp b/launcher/ui/pages/instance/ManagedPackPage.cpp
index 7a0d234c..7a823043 100644
--- a/launcher/ui/pages/instance/ManagedPackPage.cpp
+++ b/launcher/ui/pages/instance/ManagedPackPage.cpp
@@ -7,6 +7,7 @@
#include <QListView>
#include <QProxyStyle>
+#include <QStyleFactory>
#include <HoeDown.h>
@@ -60,7 +61,10 @@ ManagedPackPage::ManagedPackPage(BaseInstance* inst, InstanceWindow* instance_wi
ui->setupUi(this);
- ui->versionsComboBox->setStyle(new NoBigComboBoxStyle(ui->versionsComboBox->style()));
+ // NOTE: GTK2 themes crash with the proxy style.
+ // This seems like an upstream bug, so there's not much else that can be done.
+ if (!QStyleFactory::keys().contains("gtk2"))
+ ui->versionsComboBox->setStyle(new NoBigComboBoxStyle(ui->versionsComboBox->style()));
ui->reloadButton->setVisible(false);
connect(ui->reloadButton, &QPushButton::clicked, this, [this](bool){