forked from qt-creator/qt-creator
CMakePM: Don't show anything but CMake Preset Kits during initial configure
This is for projects that use CMake Presets, and matches the expectations of the users using CMake Presets.
The user can still enable a Kit from the left list of Kits, which is not filtered.
Amends 87c67fc6d7
Task-number: QTCREATORBUG-29535
Change-Id: If97eef867a687c877b1cbd08cd4537fe6459136f
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
This commit is contained in:
@@ -201,8 +201,6 @@ FilePaths CMakeProjectImporter::presetCandidates()
|
||||
}
|
||||
}
|
||||
|
||||
m_hasCMakePresets = !candidates.isEmpty();
|
||||
|
||||
return candidates;
|
||||
}
|
||||
|
||||
@@ -223,7 +221,7 @@ Target *CMakeProjectImporter::preferredTarget(const QList<Target *> &possibleTar
|
||||
|
||||
bool CMakeProjectImporter::filter(ProjectExplorer::Kit *k) const
|
||||
{
|
||||
if (!m_hasCMakePresets)
|
||||
if (!m_project->presetsData().havePresets)
|
||||
return true;
|
||||
|
||||
const auto presetConfigItem = CMakeConfigurationKitAspect::cmakePresetConfigItem(k);
|
||||
|
||||
Reference in New Issue
Block a user