From 482c53d11aeb50116b368cbc4c374b048519cd3f Mon Sep 17 00:00:00 2001 From: Christian Stenger Date: Fri, 18 Oct 2019 13:08:21 +0200 Subject: [PATCH] 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 --- src/plugins/debugger/debuggerengine.cpp | 1 + src/plugins/debugger/stackhandler.cpp | 5 +++++ src/plugins/debugger/stackhandler.h | 1 + 3 files changed, 7 insertions(+) diff --git a/src/plugins/debugger/debuggerengine.cpp b/src/plugins/debugger/debuggerengine.cpp index 8fa02ef988d..a90c569c6dc 100644 --- a/src/plugins/debugger/debuggerengine.cpp +++ b/src/plugins/debugger/debuggerengine.cpp @@ -442,6 +442,7 @@ public: m_lookupRequests.clear(); m_locationTimer.stop(); m_locationMark.reset(); + m_stackHandler.resetLocation(); m_disassemblerAgent.resetLocation(); m_toolTipManager.resetLocation(); } diff --git a/src/plugins/debugger/stackhandler.cpp b/src/plugins/debugger/stackhandler.cpp index aeafc69fbf8..65c6f092643 100644 --- a/src/plugins/debugger/stackhandler.cpp +++ b/src/plugins/debugger/stackhandler.cpp @@ -314,6 +314,11 @@ void StackHandler::scheduleResetLocation() m_contentsValid = false; } +void StackHandler::resetLocation() +{ + emit layoutChanged(); +} + int StackHandler::stackRowCount() const { // Only one "thread" for now. diff --git a/src/plugins/debugger/stackhandler.h b/src/plugins/debugger/stackhandler.h index 22be87b16f6..10ce5a4e85e 100644 --- a/src/plugins/debugger/stackhandler.h +++ b/src/plugins/debugger/stackhandler.h @@ -112,6 +112,7 @@ public: bool isContentsValid() const { return m_contentsValid; } bool operatesByInstruction() const; void scheduleResetLocation(); + void resetLocation(); QIcon iconForRow(int row) const;