Added #2131 AS1/2 Debugger - show _root variable

Fixed #2131 AS1/2 Debugger - Breakpoint handling - incorrect script names
Fixed #2131 Debugger - Correct walking variables tree
This commit is contained in:
Jindra Petřík
2023-12-30 18:06:08 +01:00
parent 9741e8260a
commit e371372392
14 changed files with 177 additions and 64 deletions
@@ -359,15 +359,15 @@ public class ABCPanel extends JPanel implements ItemListener, SearchListener<Scr
}
InGetVariable igv;
Long objectId = varToObjectId(var);
//Long objectId = varToObjectId(var);
boolean useGetter = (var.flags & VariableFlags.IS_CONST) == 0;
if (objectId != 0) {
/*if (objectId != 0) {
igv = Main.getDebugHandler().getVariable(objectId, "", true, useGetter);
} else {
igv = Main.getDebugHandler().getVariable(parentObjectId, var.name, true, useGetter);
}
} else {*/
igv = Main.getDebugHandler().getVariable(parentObjectId, var.name, true, useGetter);
//}
//current var is getter function - set it to value really got
if ((var.flags & VariableFlags.HAS_GETTER) > 0) {
@@ -440,6 +440,9 @@ public class ABCPanel extends JPanel implements ItemListener, SearchListener<Scr
if (var.vType == VariableType.OBJECT) {
return (Long) var.value;
}
if (var.vType == VariableType.MOVIECLIP) {
return (Long) var.value;
}
return 0L;
}
@@ -262,7 +262,7 @@ public class ASMSourceEditorPane extends DebuggableEditorPane implements CaretLi
}
}
String aname = "#PCODE abc:" + abcIndex + ",body:" + bodyIndex + ";" + scriptPathName;
setScriptName(aname);
setScriptName(aname, aname);
setHex(exportMode, true);
}
@@ -891,7 +891,7 @@ public class DecompiledEditorPane extends DebuggableEditorPane implements CaretL
}
String sn = scriptLeaf.getClassPath().toString();
setScriptName(sn);
setScriptName(sn, sn);
abcPanel.scriptNameLabel.setText(sn);
int scriptIndex = scriptLeaf.scriptIndex;
ScriptInfo nscript = null;