diff options
author | Vikas Pachdha <vikas.pachdha@qt.io> | 2018-01-10 12:22:00 +0100 |
---|---|---|
committer | Vikas Pachdha <vikas.pachdha@qt.io> | 2018-01-10 11:37:57 +0000 |
commit | 45d6a34f1e7500a5caa2eaadfdc000837c415b05 (patch) | |
tree | 0b8ec9d76535e3a3dd3bf48c28cc4cea7c20d571 /src/plugins/projectexplorer/buildconfiguration.cpp | |
parent | 2549b9237e8284ef343e0fe450024ece585eb964 (diff) | |
download | qt-creator-45d6a34f1e7500a5caa2eaadfdc000837c415b05.tar.gz |
Android: Fix BuilConfiguration priority calculation
Check the supported devices and return the base priority set by the
factory implementation
Task-number: QTCREATORBUG-19573
Change-Id: Ieae68a618d625b3f16f205e544f4626e6a410b91
Reviewed-by: hjk <hjk@qt.io>
Diffstat (limited to 'src/plugins/projectexplorer/buildconfiguration.cpp')
-rw-r--r-- | src/plugins/projectexplorer/buildconfiguration.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/plugins/projectexplorer/buildconfiguration.cpp b/src/plugins/projectexplorer/buildconfiguration.cpp index b661a1cfda..a550d49a4e 100644 --- a/src/plugins/projectexplorer/buildconfiguration.cpp +++ b/src/plugins/projectexplorer/buildconfiguration.cpp @@ -338,8 +338,10 @@ int IBuildConfigurationFactory::priority(const Target *parent) const int IBuildConfigurationFactory::priority(const Kit *k, const QString &projectPath) const { QTC_ASSERT(!m_supportedProjectMimeTypeName.isEmpty(), return -1); - if (k && Utils::mimeTypeForFile(projectPath).matchesName(m_supportedProjectMimeTypeName)) - return 0; + if (k && Utils::mimeTypeForFile(projectPath).matchesName(m_supportedProjectMimeTypeName) && + m_supportedTargetDeviceTypes.contains(DeviceTypeKitInformation::deviceTypeId(k))) { + return m_basePriority; + } return -1; } |