Debugger: Use Utils::TreeModel as base for StackHandler

Change-Id: I3fcc1b3a149f15cf414a1560d91145b623e40c63
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
hjk
2019-06-24 12:28:07 +02:00
parent 33fde35c19
commit 0d49c2cd2c
7 changed files with 87 additions and 80 deletions

View File

@@ -2581,7 +2581,8 @@ void GdbEngine::loadSymbolsForStack()
{
bool needUpdate = false;
const Modules &modules = modulesHandler()->modules();
for (const StackFrame &frame : stackHandler()->frames()) {
stackHandler()->forItemsAtLevel<1>([modules, &needUpdate, this](StackFrameItem *frameItem) {
const StackFrame &frame = frameItem->frame;
if (frame.function == "??") {
//qDebug() << "LOAD FOR " << frame.address;
for (const Module &module : modules) {
@@ -2592,7 +2593,7 @@ void GdbEngine::loadSymbolsForStack()
}
}
}
}
});
if (needUpdate) {
reloadStack();
updateLocals();
@@ -2924,7 +2925,7 @@ void GdbEngine::activateFrame(int frameIndex)
StackHandler *handler = stackHandler();
if (frameIndex == handler->stackSize()) {
if (handler->isSpecialFrame(frameIndex)) {
reloadFullStack();
return;
}