fix: reset style when changed from darkmode to normal

This commit is contained in:
Xiao YiFang 2022-12-13 20:01:18 +08:00
parent d809ca0e2d
commit 99bfb1c965

View file

@ -63,6 +63,7 @@
#include <QWebEngineSettings> #include <QWebEngineSettings>
#include <QWebEngineProfile> #include <QWebEngineProfile>
#include <QProxyStyle>
#ifdef HAVE_X11 #ifdef HAVE_X11
#if (QT_VERSION >= QT_VERSION_CHECK(6,0,0)) #if (QT_VERSION >= QT_VERSION_CHECK(6,0,0))
@ -1208,9 +1209,9 @@ void MainWindow::applyQtStyleSheet( QString const & displayStyle, QString const
} }
else else
{ {
// #ifdef Q_OS_WIN32 #ifdef Q_OS_WIN32
// qApp->setStyle( QStyleFactory::create( "Windows" ) ); qApp->setStyle( new QProxyStyle() );
// #endif #endif
qApp->setPalette( QPalette() ); qApp->setPalette( QPalette() );
} }