Debugger: Fix display of stack

When switching between interrupted and continue while
debugging the stack was not updated when the engine
states it is running again, but immediately did so
when clicking into the stack view.
Fix by explicitly updating the stack when the engine
reports it is running.

Change-Id: Ie8cb445e87fe6e45f9ae86b8ee2eec386be78a5c
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Christian Stenger
2019-10-18 13:08:21 +02:00
parent b5942847e2
commit 482c53d11a
3 changed files with 7 additions and 0 deletions

View File

@@ -442,6 +442,7 @@ public:
m_lookupRequests.clear(); m_lookupRequests.clear();
m_locationTimer.stop(); m_locationTimer.stop();
m_locationMark.reset(); m_locationMark.reset();
m_stackHandler.resetLocation();
m_disassemblerAgent.resetLocation(); m_disassemblerAgent.resetLocation();
m_toolTipManager.resetLocation(); m_toolTipManager.resetLocation();
} }

View File

@@ -314,6 +314,11 @@ void StackHandler::scheduleResetLocation()
m_contentsValid = false; m_contentsValid = false;
} }
void StackHandler::resetLocation()
{
emit layoutChanged();
}
int StackHandler::stackRowCount() const int StackHandler::stackRowCount() const
{ {
// Only one "thread" for now. // Only one "thread" for now.

View File

@@ -112,6 +112,7 @@ public:
bool isContentsValid() const { return m_contentsValid; } bool isContentsValid() const { return m_contentsValid; }
bool operatesByInstruction() const; bool operatesByInstruction() const;
void scheduleResetLocation(); void scheduleResetLocation();
void resetLocation();
QIcon iconForRow(int row) const; QIcon iconForRow(int row) const;