forked from qt-creator/qt-creator
Debugger: Re-enable retrieval of register content
Less use of magical object names. Change-Id: I2da17f1cefe1a72f4ea8be4c041e7443265def93 Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
This commit is contained in:
@@ -2008,9 +2008,9 @@ void CdbEngine::processStop(const GdbMi &stopReason, bool conditionalBreakPointT
|
|||||||
// Fire off remaining commands asynchronously
|
// Fire off remaining commands asynchronously
|
||||||
if (!m_pendingBreakpointMap.isEmpty() && !m_pendingSubBreakpointMap.isEmpty())
|
if (!m_pendingBreakpointMap.isEmpty() && !m_pendingSubBreakpointMap.isEmpty())
|
||||||
listBreakpoints();
|
listBreakpoints();
|
||||||
if (Internal::isDockVisible(QLatin1String(DOCKWIDGET_REGISTER)))
|
if (Internal::isRegistersWindowVisible())
|
||||||
reloadRegisters();
|
reloadRegisters();
|
||||||
if (Internal::isDockVisible(QLatin1String(DOCKWIDGET_MODULES)))
|
if (Internal::isModulesWindowVisible())
|
||||||
reloadModules();
|
reloadModules();
|
||||||
}
|
}
|
||||||
// After the sequence has been sent off and CDB is pondering the commands,
|
// After the sequence has been sent off and CDB is pondering the commands,
|
||||||
|
|||||||
@@ -77,7 +77,8 @@ void displayDebugger(DebuggerEngine *engine, bool updateEngine);
|
|||||||
void synchronizeBreakpoints();
|
void synchronizeBreakpoints();
|
||||||
|
|
||||||
QWidget *mainWindow();
|
QWidget *mainWindow();
|
||||||
bool isDockVisible(const QString &objectName);
|
bool isRegistersWindowVisible();
|
||||||
|
bool isModulesWindowVisible();
|
||||||
void showModuleSymbols(const QString &moduleName, const QVector<Internal::Symbol> &symbols);
|
void showModuleSymbols(const QString &moduleName, const QVector<Internal::Symbol> &symbols);
|
||||||
void showModuleSections(const QString &moduleName, const QVector<Internal::Section> §ions);
|
void showModuleSections(const QString &moduleName, const QVector<Internal::Section> §ions);
|
||||||
void openMemoryEditor();
|
void openMemoryEditor();
|
||||||
|
|||||||
@@ -3128,10 +3128,14 @@ QWidget *mainWindow()
|
|||||||
return dd->m_mainWindow;
|
return dd->m_mainWindow;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool isDockVisible(const QString &objectName)
|
bool isRegistersWindowVisible()
|
||||||
{
|
{
|
||||||
QDockWidget *dock = dd->findChild<QDockWidget *>(objectName);
|
return dd->m_registerWindow->isVisible();
|
||||||
return dock && dock->toggleViewAction()->isChecked();
|
}
|
||||||
|
|
||||||
|
bool isModulesWindowVisible()
|
||||||
|
{
|
||||||
|
return dd->m_modulesWindow->isVisible();
|
||||||
}
|
}
|
||||||
|
|
||||||
void openMemoryEditor()
|
void openMemoryEditor()
|
||||||
|
|||||||
@@ -3445,7 +3445,7 @@ void GdbEngine::handleMakeSnapshot(const DebuggerResponse &response, const QStri
|
|||||||
|
|
||||||
void GdbEngine::reloadRegisters()
|
void GdbEngine::reloadRegisters()
|
||||||
{
|
{
|
||||||
if (!Internal::isDockVisible(_(DOCKWIDGET_REGISTER)))
|
if (!Internal::isRegistersWindowVisible())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (state() != InferiorStopOk && state() != InferiorUnrunnable)
|
if (state() != InferiorStopOk && state() != InferiorUnrunnable)
|
||||||
|
|||||||
@@ -956,7 +956,7 @@ void LldbEngine::handleLocationNotification(const GdbMi &reportedLocation)
|
|||||||
|
|
||||||
void LldbEngine::reloadRegisters()
|
void LldbEngine::reloadRegisters()
|
||||||
{
|
{
|
||||||
if (!Internal::isDockVisible(QLatin1String(DOCKWIDGET_REGISTER)))
|
if (!Internal::isRegistersWindowVisible())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
DebuggerCommand cmd("fetchRegisters");
|
DebuggerCommand cmd("fetchRegisters");
|
||||||
|
|||||||
Reference in New Issue
Block a user