QmlProfiler: Remove QmlProfilerBaseModel

Now that the V8 model is gone we don't need a base model anymore.

Change-Id: I35aee0627f78f417ec9c971e1c7bbf70adfc7b27
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
This commit is contained in:
Ulf Hermann
2015-09-10 16:03:21 +02:00
parent f388882995
commit 6f8acae62d
10 changed files with 72 additions and 261 deletions

View File

@@ -653,7 +653,7 @@ void QmlProfilerEventsMainView::parseModelProxy()
}
if (d->m_fieldShown[TotalTime]) {
newRow << new EventsViewItem(QmlProfilerBaseModel::formatTime(stats.duration));
newRow << new EventsViewItem(QmlProfilerDataModel::formatTime(stats.duration));
newRow.last()->setData(QVariant(stats.duration));
}
@@ -663,22 +663,22 @@ void QmlProfilerEventsMainView::parseModelProxy()
}
if (d->m_fieldShown[TimePerCall]) {
newRow << new EventsViewItem(QmlProfilerBaseModel::formatTime(stats.timePerCall));
newRow << new EventsViewItem(QmlProfilerDataModel::formatTime(stats.timePerCall));
newRow.last()->setData(QVariant(stats.timePerCall));
}
if (d->m_fieldShown[MedianTime]) {
newRow << new EventsViewItem(QmlProfilerBaseModel::formatTime(stats.medianTime));
newRow << new EventsViewItem(QmlProfilerDataModel::formatTime(stats.medianTime));
newRow.last()->setData(QVariant(stats.medianTime));
}
if (d->m_fieldShown[MaxTime]) {
newRow << new EventsViewItem(QmlProfilerBaseModel::formatTime(stats.maxTime));
newRow << new EventsViewItem(QmlProfilerDataModel::formatTime(stats.maxTime));
newRow.last()->setData(QVariant(stats.maxTime));
}
if (d->m_fieldShown[MinTime]) {
newRow << new EventsViewItem(QmlProfilerBaseModel::formatTime(stats.minTime));
newRow << new EventsViewItem(QmlProfilerDataModel::formatTime(stats.minTime));
newRow.last()->setData(QVariant(stats.minTime));
}
@@ -938,7 +938,7 @@ void QmlProfilerEventRelativesView::rebuildTree(
newRow << new EventsViewItem(type.displayName.isEmpty() ? tr("<bytecode>") :
type.displayName);
newRow << new EventsViewItem(QmlProfilerEventsMainView::nameForType(type.rangeType));
newRow << new EventsViewItem(QmlProfilerBaseModel::formatTime(event.duration));
newRow << new EventsViewItem(QmlProfilerDataModel::formatTime(event.duration));
newRow << new EventsViewItem(QString::number(event.calls));
newRow << new EventsViewItem(type.data.isEmpty() ? tr("Source code not available") :
type.data);