Add api to get running run controls pids

That’s needed for GammaRay integration.

Change-Id: Ia3f4300299cd8792ec0a370f7ab3e30c9ad634bc
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
Filipe Azevedo
2017-01-13 13:16:32 +01:00
parent 23a2eff60d
commit 6bcc657adb
2 changed files with 12 additions and 0 deletions

View File

@@ -2558,6 +2558,16 @@ void ProjectExplorerPlugin::runRunConfiguration(RunConfiguration *rc,
emit m_instance->updateRunActions();
}
QList<QPair<Runnable, ProcessHandle>> ProjectExplorerPlugin::runningRunControlProcesses()
{
QList<QPair<Runnable, ProcessHandle>> processes;
foreach (RunControl *rc, dd->m_outputPane->allRunControls()) {
if (rc->isRunning())
processes << qMakePair(rc->runnable(), rc->applicationProcessHandle());
}
return processes;
}
void ProjectExplorerPluginPrivate::projectAdded(Project *pro)
{
if (m_projectsMode)

View File

@@ -52,6 +52,7 @@ class Project;
class Node;
class FolderNode;
class FileNode;
class ProcessHandle;
namespace Internal { class ProjectExplorerSettings; }
@@ -139,6 +140,7 @@ public:
static void runStartupProject(Core::Id runMode, bool forceSkipDeploy = false);
static void runRunConfiguration(RunConfiguration *rc, Core::Id runMode,
const bool forceSkipDeploy = false);
static QList<QPair<Runnable, ProcessHandle>> runningRunControlProcesses();
static void addExistingFiles(FolderNode *folderNode, const QStringList &filePaths);