Commit 7188689e authored by Christian Kandeler's avatar Christian Kandeler

QbsProjectManager: Fix Per-product build.

We compared the display name to the unique product name to look up
the product to build, but these two are typically not the same.

Change-Id: I82d1433c5c830a38c55f6b8827a5137ff31fd859
Task-number: QBS-705
Reviewed-by: default avatarTobias Hunger <tobias.hunger@theqtcompany.com>
parent 275eff97
......@@ -373,7 +373,11 @@ void QbsProjectManagerPlugin::buildProductContextMenu()
QTC_ASSERT(m_selectedNode, return);
QTC_ASSERT(m_selectedProject, return);
buildProducts(m_selectedProject, QStringList(m_selectedNode->displayName()));
const QbsProductNode * const productNode = qobject_cast<QbsProductNode *>(m_selectedNode);
QTC_ASSERT(productNode, return);
buildProducts(m_selectedProject,
QStringList(QbsProject::uniqueProductName(productNode->qbsProductData())));
}
void QbsProjectManagerPlugin::buildProduct()
......@@ -386,7 +390,8 @@ void QbsProjectManagerPlugin::buildProduct()
if (!product)
return;
buildProducts(m_editorProject, QStringList(product->displayName()));
buildProducts(m_editorProject,
QStringList(QbsProject::uniqueProductName(product->qbsProductData())));
}
void QbsProjectManagerPlugin::buildSubprojectContextMenu()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment