BuildConfigurationFactory: Refactor code

Refactor the code of the build configuration factories. The idea is to
generalize the code so much that we can allow plugins to install
custom build configuration factories for the platforms they support.

To support this use case the following changes where done here:
 * BuildInfo class was introduced to describe one build configuration that
   can be created by a factory.
 * Factories report a list of BuildInfo to describe what they can produce.
   This fixes the need for factories to implicitly create one buildconfiguration
   and then create another one 'officially' to support debug and release build
   configurations to be set up for projects.
 * Do no longer work around factories to create build configurations.

Change-Id: Ic372e4a9b5c582633b467d130538948472b89d91
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
This commit is contained in:
Tobias Hunger
2013-07-22 15:53:57 +02:00
parent ec436a6d64
commit d2adc30335
36 changed files with 620 additions and 306 deletions

View File

@@ -121,8 +121,9 @@ void CMakeManager::runCMake(ProjectExplorer::Project *project)
CMakeBuildConfiguration *bc
= static_cast<CMakeBuildConfiguration *>(cmakeProject->activeTarget()->activeBuildConfiguration());
CMakeOpenProjectWizard copw(this, CMakeOpenProjectWizard::WantToUpdate,
CMakeOpenProjectWizard::BuildInfo(bc));
CMakeBuildInfo info(bc);
CMakeOpenProjectWizard copw(this, CMakeOpenProjectWizard::WantToUpdate, &info);
if (copw.exec() == QDialog::Accepted)
cmakeProject->parseCMakeLists();
}