aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/qmlprofiler/qmlprofilerstatewidget.cpp
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@theqtcompany.com>2015-02-25 17:37:11 +0100
committerUlf Hermann <ulf.hermann@theqtcompany.com>2015-02-25 16:58:54 +0000
commitd2a3f3f2c7374fca918bf9fe42a64ff432b0d785 (patch)
treecfba4732fea824359561fd27a96cb5430be4819c /src/plugins/qmlprofiler/qmlprofilerstatewidget.cpp
parentad484b1c2fe9d64a7729bda0723cf26f16ea2ba0 (diff)
QmlProfiler: Don't re-estimate profiling time when not profiling
Change-Id: I2485aff4f1317a0bf194455969757da497c7e404 Task-number: QTCREATORBUG-14024 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Diffstat (limited to 'src/plugins/qmlprofiler/qmlprofilerstatewidget.cpp')
-rw-r--r--src/plugins/qmlprofiler/qmlprofilerstatewidget.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/plugins/qmlprofiler/qmlprofilerstatewidget.cpp b/src/plugins/qmlprofiler/qmlprofilerstatewidget.cpp
index 7789a778149..4fe735257ae 100644
--- a/src/plugins/qmlprofiler/qmlprofilerstatewidget.cpp
+++ b/src/plugins/qmlprofiler/qmlprofilerstatewidget.cpp
@@ -264,13 +264,14 @@ void QmlProfilerStateWidget::profilerStateChanged()
if (d->m_profilerState->currentState() == QmlProfilerStateManager::AppStarting)
d->appKilled = false;
- d->isRecording = d->m_profilerState->serverRecording();
- if (d->isRecording)
+ if (d->m_profilerState->serverRecording()) {
d->profilingTimer.start();
- else {
+ d->isRecording = true;
+ } else if (d->isRecording) {
// estimated time in ns
d->estimatedProfilingTime = d->profilingTimer.elapsed() * 1e6;
emit newTimeEstimation(d->estimatedProfilingTime);
+ d->isRecording = false;
}
updateDisplay();
}