1
0
Fork 0

Do not override the user's appearance settings on startup

Closes #2912
This commit is contained in:
Duncan Ogilvie 2022-07-20 01:04:22 +02:00
parent 5dcfd11928
commit 524c124dfd
2 changed files with 4 additions and 2 deletions

View File

@ -526,6 +526,7 @@ void MainWindow::loadSelectedTheme(bool reloadOnlyStyleCss)
{
BridgeSettingSet("Theme", "Selected", appsUseLightTheme ? "Default" : "Dark");
BridgeSettingSetUint("Theme", "AppsUseLightTheme", appsUseLightTheme);
reloadOnlyStyleCss = false;
}
}
@ -615,6 +616,7 @@ void MainWindow::loadSelectedTheme(bool reloadOnlyStyleCss)
}
// Skip changing the settings when only reloading the CSS
// On startup we want to preserve the user's appearance
if(reloadOnlyStyleCss)
return;

View File

@ -181,8 +181,8 @@ int main(int argc, char* argv[])
appPalette.setColor(QPalette::Link, ConfigColor("LinkColor"));
application.setPalette(appPalette);
// Load the selected style
MainWindow::loadSelectedTheme();
// Load the selected theme
MainWindow::loadSelectedTheme(true);
// Register custom data types
qRegisterMetaType<dsint>("dsint");