diff options
author | Ulf Hermann <ulf.hermann@digia.com> | 2014-03-17 14:52:01 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-03-18 12:02:48 +0100 |
commit | d7ea461fde7a5d227313eda83b5af84ec9b0477b (patch) | |
tree | 4123a75392fa5ffb4fc0574c1e794bae311ad261 /tools/qmlprofiler/qmlprofilerclient.cpp | |
parent | 5977fbfd16f4d2d268dfecc48b1120a1f0dcf004 (diff) |
Save painting events in Qt5 style with thread ID from qmlprofiler
This is necessary to support https://codereview.qt-project.org/80391
and to make the trace files consistent with Qt Creator's.
Change-Id: I45490c33ae9bd8fbbb6bace08bdc2f44c76bf966
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Diffstat (limited to 'tools/qmlprofiler/qmlprofilerclient.cpp')
-rw-r--r-- | tools/qmlprofiler/qmlprofilerclient.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tools/qmlprofiler/qmlprofilerclient.cpp b/tools/qmlprofiler/qmlprofilerclient.cpp index 25557af77f..23a75d0576 100644 --- a/tools/qmlprofiler/qmlprofilerclient.cpp +++ b/tools/qmlprofiler/qmlprofilerclient.cpp @@ -174,8 +174,11 @@ void QmlProfilerClient::messageReceived(const QByteArray &data) d->maximumTime = qMax(time, d->maximumTime); } else if (event == QQmlProfilerService::AnimationFrame) { int frameRate, animationCount; + int threadId = 0; stream >> frameRate >> animationCount; - emit this->frame(time, frameRate, animationCount); + if (!stream.atEnd()) + stream >> threadId; + emit this->frame(time, frameRate, animationCount, threadId); d->maximumTime = qMax(time, d->maximumTime); } else if (event == QQmlProfilerService::StartTrace) { emit this->traceStarted(time); |