summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorNicolas Werner <nicolas.werner@hotmail.de>2023-06-02 02:51:37 +0200
committerNicolas Werner <nicolas.werner@hotmail.de>2023-06-08 22:32:09 +0200
commite09188c4d08e46bd51aac21701f97ddcd6e0629a (patch)
tree2536dc45385ce5ce28173a3ef919af39dea69302 /src
parentFix message height (diff)
downloadnheko-e09188c4d08e46bd51aac21701f97ddcd6e0629a.tar.xz
Remove style sheets
Diffstat (limited to 'src')
-rw-r--r--src/UserSettingsPage.cpp17
1 files changed, 2 insertions, 15 deletions
diff --git a/src/UserSettingsPage.cpp b/src/UserSettingsPage.cpp
index 7e7cead3..84453962 100644
--- a/src/UserSettingsPage.cpp
+++ b/src/UserSettingsPage.cpp
@@ -852,21 +852,8 @@ UserSettings::setOpenVideoExternal(bool state)
 void
 UserSettings::applyTheme()
 {
-    QFile stylefile;
-
-    if (this->theme() == QLatin1String("light")) {
-        stylefile.setFileName(QStringLiteral(":/styles/styles/nheko.qss"));
-    } else if (this->theme() == QLatin1String("dark")) {
-        stylefile.setFileName(QStringLiteral(":/styles/styles/nheko-dark.qss"));
-    } else {
-        stylefile.setFileName(QStringLiteral(":/styles/styles/system.qss"));
-    }
-    QApplication::setPalette(Theme::paletteFromTheme(this->theme()));
-
-    stylefile.open(QFile::ReadOnly);
-    QString stylesheet = QString(stylefile.readAll());
-
-    qobject_cast<QApplication *>(QApplication::instance())->setStyleSheet(stylesheet);
+  QGuiApplication::setPalette(Theme::paletteFromTheme(this->theme()));
+  QApplication::setPalette(Theme::paletteFromTheme(this->theme()));
 }
 
 void