forked from qt-creator/qt-creator
Debugger: State machine cosmetics
Remove one unused notification, rename notifyInferiorUnrunnable. Change-Id: I585d3a8606585fbdd8ad48e5eeecf629542bd93c Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
This commit is contained in:
@@ -812,7 +812,7 @@ void CdbEngine::runEngine()
|
||||
}
|
||||
if (startParameters().startMode == AttachCore) {
|
||||
QTC_ASSERT(!m_coreStopReason.isNull(), return; );
|
||||
notifyInferiorUnrunnable();
|
||||
notifyEngineRunOkAndInferiorUnrunnable();
|
||||
processStop(*m_coreStopReason, false);
|
||||
} else {
|
||||
doContinueInferior();
|
||||
|
@@ -825,7 +825,7 @@ void DebuggerEnginePrivate::doRunEngine()
|
||||
m_engine->runEngine();
|
||||
}
|
||||
|
||||
void DebuggerEngine::notifyInferiorUnrunnable()
|
||||
void DebuggerEngine::notifyEngineRunOkAndInferiorUnrunnable()
|
||||
{
|
||||
showMessage(_("NOTE: INFERIOR UNRUNNABLE"));
|
||||
d->m_progress.setProgressValue(1000);
|
||||
@@ -904,16 +904,6 @@ void DebuggerEngine::notifyEngineRemoteSetupFinished(const RemoteSetupResult &re
|
||||
}
|
||||
}
|
||||
|
||||
void DebuggerEngine::notifyEngineRunOkAndInferiorRunRequested()
|
||||
{
|
||||
showMessage(_("NOTE: ENGINE RUN OK AND INFERIOR RUN REQUESTED"));
|
||||
d->m_progress.setProgressValue(1000);
|
||||
d->m_progress.reportFinished();
|
||||
QTC_ASSERT(state() == EngineRunRequested, qDebug() << this << state());
|
||||
showStatusMessage(tr("Running."));
|
||||
setState(InferiorRunRequested);
|
||||
}
|
||||
|
||||
void DebuggerEngine::notifyEngineRunAndInferiorRunOk()
|
||||
{
|
||||
showMessage(_("NOTE: ENGINE RUN AND INFERIOR RUN OK"));
|
||||
|
@@ -293,10 +293,9 @@ protected:
|
||||
virtual void notifyInferiorSetupOk();
|
||||
virtual void notifyInferiorSetupFailed();
|
||||
|
||||
virtual void notifyEngineRunOkAndInferiorRunRequested();
|
||||
virtual void notifyEngineRunAndInferiorRunOk();
|
||||
virtual void notifyEngineRunAndInferiorStopOk();
|
||||
virtual void notifyInferiorUnrunnable(); // Called by CoreAdapter.
|
||||
virtual void notifyEngineRunOkAndInferiorUnrunnable(); // Called by CoreAdapter.
|
||||
|
||||
// Use notifyInferiorRunRequested() plus notifyInferiorRunOk() instead.
|
||||
//virtual void notifyInferiorSpontaneousRun();
|
||||
|
@@ -243,7 +243,7 @@ void GdbCoreEngine::runEngine()
|
||||
void GdbCoreEngine::handleTargetCore(const DebuggerResponse &response)
|
||||
{
|
||||
QTC_ASSERT(state() == EngineRunRequested, qDebug() << state());
|
||||
notifyInferiorUnrunnable();
|
||||
notifyEngineRunOkAndInferiorUnrunnable();
|
||||
if (response.resultClass == ResultDone) {
|
||||
showMessage(tr("Attached to core."), StatusBar);
|
||||
// Due to the auto-solib-add off setting, we don't have any
|
||||
|
@@ -93,7 +93,6 @@ void GdbPlainEngine::handleExecRun(const DebuggerResponse &response)
|
||||
{
|
||||
QTC_ASSERT(state() == EngineRunRequested, qDebug() << state());
|
||||
if (response.resultClass == ResultRunning) {
|
||||
//notifyEngineRunOkAndInferiorRunRequested();
|
||||
notifyEngineRunAndInferiorRunOk(); // For gdb < 7.0
|
||||
//showStatusMessage(tr("Running..."));
|
||||
showMessage(_("INFERIOR STARTED"));
|
||||
|
@@ -535,7 +535,7 @@ void QmlCppEngine::slaveEngineStateChanged
|
||||
}
|
||||
case InferiorUnrunnable: {
|
||||
qmlEngine()->quitDebugger();
|
||||
notifyInferiorUnrunnable();
|
||||
notifyEngineRunOkAndInferiorUnrunnable();
|
||||
break;
|
||||
}
|
||||
case InferiorRunRequested: {
|
||||
|
Reference in New Issue
Block a user