|
Last change
on this file since 280 was 2, checked in by Dmitry A. Kuminov, 17 years ago |
|
Initially imported qt-all-opensource-src-4.5.1 from Trolltech.
|
|
File size:
808 bytes
|
| Line | |
|---|
| 1 | name = "down";
|
|---|
| 2 |
|
|---|
| 3 | group = "stack";
|
|---|
| 4 |
|
|---|
| 5 | shortDescription = "Select and print the stack frame below the current one";
|
|---|
| 6 |
|
|---|
| 7 | longDescription = "";
|
|---|
| 8 |
|
|---|
| 9 | seeAlso = [ "up", "frame" ];
|
|---|
| 10 |
|
|---|
| 11 | function execute() {
|
|---|
| 12 | var idx = getCurrentFrameIndex();
|
|---|
| 13 | if (idx == 0) {
|
|---|
| 14 | warning("Already at bottom (innermost) frame.");
|
|---|
| 15 | return;
|
|---|
| 16 | }
|
|---|
| 17 | setCurrentFrameIndex(idx - 1);
|
|---|
| 18 | scheduleGetContextInfo(idx - 1);
|
|---|
| 19 | state = 1;
|
|---|
| 20 | }
|
|---|
| 21 |
|
|---|
| 22 | function handleResponse(resp, id) {
|
|---|
| 23 | if (state == 1) {
|
|---|
| 24 | var info = resp.result;
|
|---|
| 25 | setCurrentScriptId(info.scriptId);
|
|---|
| 26 | setCurrentLineNumber(info.lineNumber);
|
|---|
| 27 | scheduleGetBacktrace();
|
|---|
| 28 | state = 2;
|
|---|
| 29 | } else if (state == 2) {
|
|---|
| 30 | var backtrace = resp.result;
|
|---|
| 31 | message("#" + getCurrentFrameIndex() + " " + backtrace[getCurrentFrameIndex()]);
|
|---|
| 32 | }
|
|---|
| 33 | }
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.