#6345 Let Mainwindow save settings before program quits

# Conflicts:
#	src/gui/src/main.cpp
This commit is contained in:
XinyuHou 2016-11-23 15:10:42 +00:00 committed by Nick Bolton
parent 7da1d4f9cc
commit 46a5b7f9ae
1 changed files with 4 additions and 0 deletions

View File

@ -97,6 +97,10 @@ int main(int argc, char* argv[])
app.switchTranslator(appConfig.language()); app.switchTranslator(appConfig.language());
MainWindow mainWindow(settings, appConfig, licenseManager); MainWindow mainWindow(settings, appConfig, licenseManager);
QObject::connect(dynamic_cast<QObject*>(&app), SIGNAL(aboutToQuit()),
&mainWindow, SLOT(saveSettings()));
SetupWizard setupWizard(mainWindow, true); SetupWizard setupWizard(mainWindow, true);
if (appConfig.wizardShouldRun()) if (appConfig.wizardShouldRun())