mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-09-25 13:20:51 +00:00
AS3 instruction name padding is optional (can be enabled in settings/scripts)
as it may be hard to search an instruction with spaces behind it
This commit is contained in:
+5
-2
@@ -29,6 +29,7 @@ import com.jpexs.decompiler.flash.abc.avm2.instructions.other.ThrowIns;
|
||||
import com.jpexs.decompiler.flash.abc.types.Float4;
|
||||
import com.jpexs.decompiler.flash.abc.types.MethodBody;
|
||||
import com.jpexs.decompiler.flash.abc.types.Multiname;
|
||||
import com.jpexs.decompiler.flash.configuration.Configuration;
|
||||
import com.jpexs.decompiler.flash.helpers.GraphTextWriter;
|
||||
import com.jpexs.decompiler.graph.DottedChain;
|
||||
import com.jpexs.decompiler.graph.GraphSource;
|
||||
@@ -380,8 +381,10 @@ public class AVM2Instruction implements Cloneable, GraphSourceItem {
|
||||
|
||||
public String toStringNoAddress(AVM2ConstantPool constants, List<DottedChain> fullyQualifiedNames) {
|
||||
String s = definition.instructionName;
|
||||
for (int i = s.length(); i < 19; i++) {
|
||||
s += " ";
|
||||
if (Configuration.padAs3PCodeInstructionName.get()) {
|
||||
for (int i = s.length(); i < 19; i++) {
|
||||
s += " ";
|
||||
}
|
||||
}
|
||||
s += getParams(constants, fullyQualifiedNames) + getComment();
|
||||
return s.trim();
|
||||
|
||||
@@ -190,6 +190,10 @@ public final class Configuration {
|
||||
@ConfigurationInternal
|
||||
public static ConfigurationItem<Boolean> showOriginalBytesInPcodeHex = null;
|
||||
|
||||
@ConfigurationDefaultBoolean(false)
|
||||
@ConfigurationCategory("script")
|
||||
public static ConfigurationItem<Boolean> padAs3PCodeInstructionName = null;
|
||||
|
||||
/**
|
||||
* Limit of code subs (for obfuscated code)
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user