diff --git a/src/plugins/qmlprofiler/qmlprofilermodelmanager.cpp b/src/plugins/qmlprofiler/qmlprofilermodelmanager.cpp index 3940710e5a8..55a2cfea4b4 100644 --- a/src/plugins/qmlprofiler/qmlprofilermodelmanager.cpp +++ b/src/plugins/qmlprofiler/qmlprofilermodelmanager.cpp @@ -123,7 +123,7 @@ QmlProfilerModelManager::QmlProfilerModelManager(QObject *parent) : d->detailsRewriter = new Internal::QmlProfilerDetailsRewriter(this); connect(d->detailsRewriter, &Internal::QmlProfilerDetailsRewriter::rewriteDetailsString, - this, &QmlProfilerModelManager::typeDetailsChanged); + this, &QmlProfilerModelManager::setTypeDetails); connect(d->detailsRewriter, &Internal::QmlProfilerDetailsRewriter::eventDetailsChanged, this, &QmlProfilerModelManager::typeDetailsFinished); @@ -287,12 +287,13 @@ QString QmlProfilerModelManager::findLocalFile(const QString &remoteFile) return d->detailsRewriter->getLocalFile(remoteFile); } -void QmlProfilerModelManager::detailsChanged(int typeId, const QString &newString) +void QmlProfilerModelManager::setTypeDetails(int typeId, const QString &details) { QTC_ASSERT(typeId < numEventTypes(), return); QmlEventType type = eventType(typeId); - type.setData(newString); - setEventType(typeId, std::move(type)); + type.setData(details); + // Don't rewrite the details again, but directly push the type into the type storage. + Timeline::TimelineTraceManager::setEventType(typeId, std::move(type)); emit typeDetailsChanged(typeId); } diff --git a/src/plugins/qmlprofiler/qmlprofilermodelmanager.h b/src/plugins/qmlprofiler/qmlprofilermodelmanager.h index 6d73a08d516..3dd38c66e20 100644 --- a/src/plugins/qmlprofiler/qmlprofilermodelmanager.h +++ b/src/plugins/qmlprofiler/qmlprofilermodelmanager.h @@ -89,7 +89,7 @@ signals: void typeDetailsFinished(); private: - void detailsChanged(int typeId, const QString &newString); + void setTypeDetails(int typeId, const QString &details); void restrictByFilter(QmlEventFilter filter); void clearEventStorage() final;