Commit 05f72338 authored by hjk's avatar hjk

Debugger: Handle the <more> item in LLDB stack view

Task-number: QTCREATORBUG-11915
Change-Id: I7216987c68802c9d3b74fbd5b543ea4aa5953ff8
Reviewed-by: default avatarEike Ziller <eike.ziller@digia.com>
parent 88255a68
......@@ -1169,7 +1169,6 @@ class Dumper(DumperBase):
else:
state = self.process.GetState()
if state == lldb.eStateStopped:
self.reportStack()
self.reportStackPosition()
self.reportThreads()
self.reportVariables()
......@@ -1259,7 +1258,6 @@ class Dumper(DumperBase):
stoppedThread = self.firstStoppedThread()
if stoppedThread:
self.process.SetSelectedThread(stoppedThread)
self.reportStack({'stacklimit': 20})
self.reportStackTop()
self.reportThreads()
self.reportLocation()
......
......@@ -491,15 +491,17 @@ void LldbEngine::activateFrame(int frameIndex)
if (state() != InferiorStopOk && state() != InferiorUnrunnable)
return;
int limit = debuggerCore()->action(MaximalStackDepth)->value().toInt();
int n = stackHandler()->stackSize();
if (frameIndex == n)
limit = n * 10 + 3;
const int n = stackHandler()->stackSize();
if (frameIndex == n) {
Command cmd("reportStack");
cmd.arg("stacklimit", n * 10 + 3);
runCommand(cmd);
return;
}
Command cmd("activateFrame");
cmd.arg("index", frameIndex);
cmd.arg("thread", threadsHandler()->currentThread().raw());
cmd.arg("stacklimit", limit);
runCommand(cmd);
updateAll();
......@@ -883,9 +885,24 @@ bool LldbEngine::setToolTipExpression(const QPoint &mousePos,
void LldbEngine::updateAll()
{
reloadRegisters();
updateStack();
updateLocals();
}
void LldbEngine::reloadFullStack()
{
Command cmd("reportStack");
cmd.arg("stacklimit", -1);
runCommand(cmd);
}
void LldbEngine::updateStack()
{
Command cmd("reportStack");
cmd.arg("stacklimit", 20);
runCommand(cmd);
}
//////////////////////////////////////////////////////////////////////
//
// Watch specific stuff
......
......@@ -134,7 +134,7 @@ private:
void reloadModules();
void reloadRegisters();
void reloadSourceFiles() {}
void reloadFullStack() {}
void reloadFullStack();
void fetchDisassembler(Internal::DisassemblerAgent *);
void refreshDisassembly(const GdbMi &data);
......@@ -161,6 +161,7 @@ private:
Q_SLOT void handleResponse(const QByteArray &data);
Q_SLOT void runEngine2();
Q_SLOT void updateAll();
Q_SLOT void updateStack();
Q_SLOT void updateLocals();
Q_SLOT void createFullBacktrace();
void doUpdateLocals(UpdateParameters params);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment