mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-09-25 11:50:51 +00:00
Fixed ip highlighting
This commit is contained in:
@@ -34,6 +34,7 @@ import com.jpexs.decompiler.flash.SWFSourceInfo;
|
||||
import com.jpexs.decompiler.flash.SearchMode;
|
||||
import com.jpexs.decompiler.flash.SwfOpenException;
|
||||
import com.jpexs.decompiler.flash.Version;
|
||||
import com.jpexs.decompiler.flash.abc.ClassPath;
|
||||
import com.jpexs.decompiler.flash.abc.ScriptPack;
|
||||
import com.jpexs.decompiler.flash.abc.avm2.AVM2Code;
|
||||
import com.jpexs.decompiler.flash.configuration.Configuration;
|
||||
@@ -160,6 +161,8 @@ public class Main {
|
||||
|
||||
private static Map<ScriptPack, Set<Integer>> breakPointMap = new WeakHashMap<>();
|
||||
private static Map<ScriptPack, Set<Integer>> invalidBreakPointMap = new WeakHashMap<>();
|
||||
private static int ip = 0;
|
||||
private static ClassPath ipClass = null;
|
||||
|
||||
public static void clearBreakPoints(ScriptPack pack) {
|
||||
if (breakPointMap.containsKey(pack)) {
|
||||
@@ -167,6 +170,25 @@ public class Main {
|
||||
}
|
||||
}
|
||||
|
||||
public static boolean isDebugging() {
|
||||
return mainFrame.getMenu().isDebugRunning();
|
||||
}
|
||||
|
||||
public static int getIp(ScriptPack pack) {
|
||||
return ip;
|
||||
}
|
||||
|
||||
public static ClassPath getIpClass() {
|
||||
return ipClass;
|
||||
}
|
||||
|
||||
public static void breakAt(ClassPath clsName, int ip) {
|
||||
Main.ip = ip;
|
||||
Main.ipClass = clsName;
|
||||
mainFrame.getPanel().gotoClassLine(getMainFrame().getPanel().getCurrentSwf(), clsName.toString(), ip);
|
||||
//Main.getMainFrame().getPanel().debuggerBreakAt(Main.getMainFrame().getPanel().getCurrentSwf(), cls, message.line);
|
||||
}
|
||||
|
||||
public static boolean isBreakPointValid(ScriptPack pack, int line) {
|
||||
if (!invalidBreakPointMap.containsKey(pack)) {
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user