CMakeProjectManager: Fix connection to save tools settings

Amends 4e23f2a6eb.

This should actually not be needed in the end, and rather steered
by the auto registration and settings page apply.

Change-Id: I7f94e776fec4394f539e32e5c527c367251654a8
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
This commit is contained in:
hjk
2023-08-23 10:16:28 +02:00
parent 6e6587c528
commit 55b5b8a975
4 changed files with 36 additions and 7 deletions

View File

@@ -1283,23 +1283,44 @@ KitAspect *CMakeConfigurationKitAspectFactory::createKitAspect(Kit *k) const
// Factory instances;
const CMakeKitAspectFactory theCMakeKitAspectFactory;
const CMakeGeneratorKitAspectFactory theCMakeGeneratorKitAspectFactory;
const CMakeConfigurationKitAspectFactory theCMakeConfigurationKitAspectFactory;
CMakeKitAspectFactory &cmakeKitAspectFactory()
{
static CMakeKitAspectFactory theCMakeKitAspectFactory;
return theCMakeKitAspectFactory;
}
CMakeGeneratorKitAspectFactory &cmakeGeneratorKitAspectFactory()
{
static CMakeGeneratorKitAspectFactory theCMakeGeneratorKitAspectFactory;
return theCMakeGeneratorKitAspectFactory;
}
static CMakeConfigurationKitAspectFactory &cmakeConfigurationKitAspectFactory()
{
static CMakeConfigurationKitAspectFactory theCMakeConfigurationKitAspectFactory;
return theCMakeConfigurationKitAspectFactory;
}
KitAspect *CMakeKitAspect::createKitAspect(Kit *k)
{
return theCMakeKitAspectFactory.createKitAspect(k);
return cmakeKitAspectFactory().createKitAspect(k);
}
KitAspect *CMakeGeneratorKitAspect::createKitAspect(Kit *k)
{
return theCMakeGeneratorKitAspectFactory.createKitAspect(k);
return cmakeGeneratorKitAspectFactory().createKitAspect(k);
}
KitAspect *CMakeConfigurationKitAspect::createKitAspect(Kit *k)
{
return theCMakeConfigurationKitAspectFactory.createKitAspect(k);
return cmakeConfigurationKitAspectFactory().createKitAspect(k);
}
void CMakeKitAspect::createFactories()
{
cmakeKitAspectFactory();
cmakeGeneratorKitAspectFactory();
cmakeConfigurationKitAspectFactory();
}
} // namespace CMakeProjectManager