forked from qt-creator/qt-creator
ProjectExplorer: Let RunConfiguration declare what nodes it belongs to
This feature in question is the availability of the "Run" button in the context menu of certain project nodes in the project tree to run something presumably related to/build from that (sub)project. Previously, the decision was made for certain qmake based projects (those targeting Desktop, iOS and VxWorks) by some indirection through the corresponding RunConfigurationFactories. The patch lets the RunConfigurations decide themselves directly and removes the indirection, potentially opening the feature for other qmake based RCs, as well as other combinations (e.g. PythonRunConfiguration could be associated with its .py file, without the need to have a dummy project) Change-Id: Ic489bd1dfa25fcd9102ffa4fa30125565dd2e40e Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
@@ -157,6 +157,11 @@ void IosRunConfiguration::updateEnabledState()
|
||||
return RunConfiguration::updateEnabledState();
|
||||
}
|
||||
|
||||
bool IosRunConfiguration::canRunForNode(const Node *node) const
|
||||
{
|
||||
return node->filePath() == m_profilePath;
|
||||
}
|
||||
|
||||
IosDeployStep *IosRunConfiguration::deployStep() const
|
||||
{
|
||||
DeployConfiguration *config = target()->activeDeployConfiguration();
|
||||
|
Reference in New Issue
Block a user