CMakePM: Save initial configuration changes on "exit"

Previously the changes to "Initial Configuration" would be done only
after pressing "Re-configure with Initial Parameters".

Now the settings are saved when the widget is closed:
- a different kit is selected
- a different build type is selected
- project is closed
- switch between build and run settings

This way the changes are not lost.

Change-Id: Ia2c1c10c59bfa101332066205f98684843266f94
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
This commit is contained in:
Cristian Adam
2022-01-28 16:44:05 +01:00
parent a7d3f9fdba
commit d5eed0480d

View File

@@ -480,12 +480,14 @@ CMakeBuildSettingsWidget::CMakeBuildSettingsWidget(CMakeBuildConfiguration *bc)
if (m_buildConfiguration->isEnabled())
setError(QString());
});
connect(this, &QObject::destroyed, this, [this](const QObject *obj) {
updateInitialCMakeArguments();
});
updateSelection();
updateConfigurationStateSelection();
}
void CMakeBuildSettingsWidget::batchEditConfiguration()
{
auto dialog = new QDialog(this);