CppTools: Add target information to ProjectPart

This is important to be able to map sources to actual things that are
going to be built.

Change-Id: I1aef940767d60192642ed79a1703cff8dfdad9e1
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
Tobias Hunger
2017-02-27 14:46:45 +01:00
committed by Christian Stenger
parent 831864c56c
commit 802eff3485
9 changed files with 17 additions and 0 deletions

View File

@@ -1779,12 +1779,16 @@ void CppCodeModelInspectorDialog::updateProjectPartData(const ProjectPart::Ptr &
}
const QString callGroupId = part->callGroupId.isEmpty() ? QString::fromLatin1("<None>")
: part->callGroupId;
const QString buildSystemTarget
= part->buildSystemTarget.isEmpty() ? QString::fromLatin1("<None>")
: part->buildSystemTarget;
KeyValueModel::Table table = KeyValueModel::Table()
<< qMakePair(QString::fromLatin1("Project Part Name"), part->displayName)
<< qMakePair(QString::fromLatin1("Project Part File"), part->projectFileLocation())
<< qMakePair(QString::fromLatin1("Project Name"), projectName)
<< qMakePair(QString::fromLatin1("Project File"), projectFilePath)
<< qMakePair(QString::fromLatin1("Buildsystem Target"), buildSystemTarget)
<< qMakePair(QString::fromLatin1("Callgroup Id"), callGroupId)
<< qMakePair(QString::fromLatin1("Selected For Building"),
CMI::Utils::toString(part->selectedForBuilding))