Save project config on close

This commit is contained in:
GriffinR 2024-07-24 12:00:34 -04:00
parent 0012ea83e6
commit 80497805a1
2 changed files with 2 additions and 2 deletions

View file

@ -81,6 +81,7 @@ void Editor::saveUiFields() {
void Editor::closeProject() { void Editor::closeProject() {
if (!this->project) if (!this->project)
return; return;
this->project->saveConfig();
Scripting::cb_ProjectClosed(this->project->root); Scripting::cb_ProjectClosed(this->project->root);
Scripting::stop(); Scripting::stop();
clearMap(); clearMap();

View file

@ -571,8 +571,7 @@ bool MainWindow::openProject(QString dir, bool initial) {
} }
// Only create the config files once the project has opened successfully in case the user selected an invalid directory // Only create the config files once the project has opened successfully in case the user selected an invalid directory
userConfig.save(); this->editor->project->saveConfig();
projectConfig.save();
showWindowTitle(); showWindowTitle();
this->statusBar()->showMessage(QString("Opened %1").arg(projectString)); this->statusBar()->showMessage(QString("Opened %1").arg(projectString));