forked from qt-creator/qt-creator
QmlProfiler: Get rid of processing step
The child models are made aware of possible changes in the details strings, and in turn, we can do the finalization immediately after acquiring is done. Change-Id: Ibe57f158e64e5d01d4c97aa617c9b2bcc8e4e96e Task-number: QTCREATORBUG-20106 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
@@ -315,7 +315,6 @@ QmlProfilerTool::QmlProfilerTool()
|
||||
&& d->m_profilerState->currentState()
|
||||
!= QmlProfilerStateManager::AppDying);
|
||||
break;
|
||||
case QmlProfilerModelManager::ProcessingData:
|
||||
case QmlProfilerModelManager::ClearingData:
|
||||
d->m_recordButton->setEnabled(false);
|
||||
break;
|
||||
@@ -734,7 +733,7 @@ void QmlProfilerTool::clientsDisconnected()
|
||||
{
|
||||
if (d->m_profilerModelManager->state() == QmlProfilerModelManager::AcquiringData) {
|
||||
if (d->m_profilerModelManager->aggregateTraces()) {
|
||||
d->m_profilerModelManager->acquiringDone();
|
||||
d->m_profilerModelManager->finalize();
|
||||
} else {
|
||||
// If the application stopped by itself, check if we have all the data
|
||||
if (d->m_profilerState->currentState() == QmlProfilerStateManager::AppDying ||
|
||||
@@ -814,9 +813,6 @@ void QmlProfilerTool::profilerDataModelStateChanged()
|
||||
restoreFeatureVisibility();
|
||||
setButtonsEnabled(false); // Other buttons disabled
|
||||
break;
|
||||
case QmlProfilerModelManager::ProcessingData :
|
||||
setButtonsEnabled(false);
|
||||
break;
|
||||
case QmlProfilerModelManager::Done :
|
||||
showSaveOption();
|
||||
updateTimeDisplay();
|
||||
@@ -920,10 +916,10 @@ void QmlProfilerTool::serverRecordingChanged()
|
||||
} else {
|
||||
d->m_recordingTimer.stop();
|
||||
if (!d->m_profilerModelManager->aggregateTraces())
|
||||
d->m_profilerModelManager->acquiringDone();
|
||||
d->m_profilerModelManager->finalize();
|
||||
}
|
||||
} else if (d->m_profilerState->currentState() == QmlProfilerStateManager::AppStopRequested) {
|
||||
d->m_profilerModelManager->acquiringDone();
|
||||
d->m_profilerModelManager->finalize();
|
||||
d->m_profilerState->setCurrentState(QmlProfilerStateManager::Idle);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user