forked from qt-creator/qt-creator
QmlProfiler: Move event handling into model manager
This is the logical place to do it. Adding the event first to the QML model and then passing it back to the manager in order to have it dispatched to the other models is somewhat backwards. Change-Id: I64b1cb38f97331b62d83fa5ae49b9b2690810d40 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
This commit is contained in:
@@ -48,10 +48,8 @@ DummyModel::DummyModel(QmlProfilerModelManager *manager) :
|
||||
|
||||
void DummyModel::loadData()
|
||||
{
|
||||
QmlProfilerDataModel *dataModel = modelManager()->qmlModel();
|
||||
QmlEventType type(MaximumMessage, Binding);
|
||||
|
||||
dataModel->addEventType(type);
|
||||
modelManager()->addEventType(type);
|
||||
|
||||
for (int i = 0; i < 10; ++i) {
|
||||
QmlEvent event(i, 0, {});
|
||||
|
||||
Reference in New Issue
Block a user