Make CMakeTool known to the Kits

This patch adds support for binding a specific CMakeTool to a Kit.
When creating a new Kit or loading a existing one without a valid
CMakeTool, the default CMakeTool will be set.

Change-Id: I28d0843a01c583c4b31fc680a0ec556b40cd9c0d
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
This commit is contained in:
Benjamin Zeller
2015-02-24 21:57:00 +01:00
parent 20a05c986c
commit 1e2d266541
20 changed files with 723 additions and 145 deletions

View File

@@ -27,6 +27,7 @@
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
**
****************************************************************************/
#include "cmakeprojectconstants.h"
#include "cmakesettingspage.h"
#include "cmaketoolmanager.h"
@@ -393,6 +394,7 @@ public:
m_makeDefButton = new QPushButton(tr("Make Default"), this);
m_makeDefButton->setEnabled(false);
m_makeDefButton->setToolTip(tr("Set as the default CMake Tool to use when creating a new Kit, or no value is set."));
m_preferNinjaCheckBox = new QCheckBox(tr("Prefer Ninja generator (CMake 2.8.9 or higher required)"));
m_preferNinjaCheckBox->setChecked(CMakeToolManager::preferNinja());
@@ -539,7 +541,7 @@ void CMakeToolConfigWidget::currentCMakeToolChanged(const QModelIndex &newCurren
CMakeSettingsPage::CMakeSettingsPage() : m_widget(0)
{
setId("Z.CMake");
setId(Constants::CMAKE_SETTINGSPAGE_ID);
setDisplayName(tr("CMake"));
setCategory(ProjectExplorer::Constants::PROJECTEXPLORER_SETTINGS_CATEGORY);
setDisplayCategory(QCoreApplication::translate("ProjectExplorer",