Debugger: Activate debug mode when loading is done

When Creator is executed with -debug (core or executable) and a project, the
core dump is opened, but the mode is switched to Edit when the project opens,
while the user expects debug mode.

Switch to debug mode when loading is done.

Change-Id: I2a6b18c9ff90605840fc53a6b23dee1e8d4d4e2c
Reviewed-by: hjk <hjk@theqtcompany.com>
This commit is contained in:
Orgad Shaneh
2015-12-12 23:02:43 +02:00
committed by Orgad Shaneh
parent e99aaf23b9
commit d7f255bbd7

View File

@@ -1942,6 +1942,7 @@ void DebuggerPluginPrivate::updateState(DebuggerEngine *engine)
setProxyAction(m_visibleStartAction, Id(Constants::INTERRUPT));
m_hiddenStopAction->setAction(m_interruptAction);
m_localsAndExpressionsWindow->setShowLocals(false);
activateDebugMode();
} else if (state == DebuggerFinished) {
Project *project = SessionManager::startupProject();
const bool canRun = ProjectExplorerPlugin::canRun(project, ProjectExplorer::Constants::DEBUG_RUN_MODE);
@@ -1967,6 +1968,7 @@ void DebuggerPluginPrivate::updateState(DebuggerEngine *engine)
m_hiddenStopAction->setAction(m_exitAction);
// show locals in core dumps
m_localsAndExpressionsWindow->setShowLocals(true);
activateDebugMode();
} else {
// Everything else is "undisturbable".
m_interruptAction->setEnabled(false);