summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2018-01-03 12:42:09 +0100
committerUlf Hermann <ulf.hermann@qt.io>2018-01-03 11:54:23 +0000
commit359e4c88c929980344180eb07bbb262707b768cb (patch)
treeec2a709dd5e38fe8623b3940ffa20101131554ab
parent0ebdeccb83d882d4ee10521b630a67d0e62d686e (diff)
downloadqt-creator-359e4c88c929980344180eb07bbb262707b768cb.tar.gz
QmlProfiler: Stop run control if connection to external app closes
We don't have control over the application's life cycle in this case, so we need to use the debug connection as indicator. Change-Id: I3f30194e12c10c6585a58133c5148dbea9e6761f Task-number: QTCREATORBUG-19496 Reviewed-by: hjk <hjk@qt.io>
-rw-r--r--src/plugins/qmlprofiler/qmlprofilertool.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/plugins/qmlprofiler/qmlprofilertool.cpp b/src/plugins/qmlprofiler/qmlprofilertool.cpp
index 8e6b0014bb..9966b2132d 100644
--- a/src/plugins/qmlprofiler/qmlprofilertool.cpp
+++ b/src/plugins/qmlprofiler/qmlprofilertool.cpp
@@ -562,6 +562,8 @@ void QmlProfilerTool::attachToWaitingApplication()
auto profiler = new QmlProfilerRunner(runControl);
profiler->setServerUrl(serverUrl);
+ connect(d->m_profilerConnections, &QmlProfilerClientManager::connectionClosed,
+ runControl, &RunControl::initiateStop);
ProjectExplorerPlugin::startRunControl(runControl);
}