forked from qt-creator/qt-creator
Add "Run" to projectexplorer context menu
Task-Nr: QTCREATORBUG-2166
This commit is contained in:
@@ -760,6 +760,11 @@ bool Qt4PriFileNode::deploysFolder(const QString &folder) const
|
||||
return false;
|
||||
}
|
||||
|
||||
QList<ProjectExplorer::RunConfiguration *> Qt4PriFileNode::runConfigurationsFor(Node *node)
|
||||
{
|
||||
return m_project->activeTarget()->runConfigurationsForNode(node);
|
||||
}
|
||||
|
||||
QList<ProjectNode::ProjectAction> Qt4PriFileNode::supportedActions(Node *node) const
|
||||
{
|
||||
QList<ProjectAction> actions;
|
||||
@@ -811,6 +816,9 @@ QList<ProjectNode::ProjectAction> Qt4PriFileNode::supportedActions(Node *node) c
|
||||
if (fileNode && fileNode->fileType() != ProjectExplorer::ProjectFileType)
|
||||
actions << Rename;
|
||||
|
||||
if (!m_project->activeTarget()->runConfigurationsForNode(node).isEmpty())
|
||||
actions << HasSubProjectRunConfigurations;
|
||||
|
||||
return actions;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user