Profile a pixmap start event also when loading is asynchronous.
authorUlf Hermann <ulf.hermann@digia.com>
Tue, 3 Dec 2013 13:45:12 +0000 (14:45 +0100)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Fri, 6 Dec 2013 12:12:58 +0000 (13:12 +0100)
If those events aren't profiled we get unmatched events for finished
loading and errors.

Task-number: QTBUG-35337

Change-Id: I132638edf5625566e37ee06453484f80b2adb74a
Reviewed-by: Ulf Hermann <ulf.hermann@digia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
src/quick/util/qquickpixmapcache.cpp

index 26258fd..5bab131 100644 (file)
@@ -519,6 +519,9 @@ void QQuickPixmapReader::processJobs()
             runningJob->loading = true;
 
             QUrl url = runningJob->url;
+            QQmlPixmapProfiler pixmapProfiler;
+            pixmapProfiler.startLoading(url);
+
             QSize requestSize = runningJob->requestSize;
             locker.unlock();
             processJob(runningJob, url, requestSize);