From 0ca09ff3298e2dc4436ea6e504a24e31ab15e074 Mon Sep 17 00:00:00 2001 From: Honfika Date: Sat, 24 Aug 2013 22:48:30 +0200 Subject: [PATCH] pcode export shows "Decompilation skipped" when AS decompilation is disabled fixed => Configuration checking moved to "not pcode" branch --- .../decompiler/flash/abc/types/MethodBody.java | 14 +++++++------- .../jpexs/decompiler/flash/xfl/XFLConverter.java | 3 ++- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/trunk/src/com/jpexs/decompiler/flash/abc/types/MethodBody.java b/trunk/src/com/jpexs/decompiler/flash/abc/types/MethodBody.java index 8ee104f32..043fa4d21 100644 --- a/trunk/src/com/jpexs/decompiler/flash/abc/types/MethodBody.java +++ b/trunk/src/com/jpexs/decompiler/flash/abc/types/MethodBody.java @@ -113,16 +113,16 @@ public class MethodBody implements Cloneable, Serializable { System.err.println("Decompiling " + path); } String s = ""; - if (!(Boolean) Configuration.getConfig("decompile", Boolean.TRUE)) { - s = "//Decompilation skipped"; - if (hilight) { - s = Highlighting.hilighMethod(s, this.method_info); - } - return s; - } if (pcode) { s += code.toASMSource(constants, this, false); } else { + if (!(Boolean) Configuration.getConfig("decompile", Boolean.TRUE)) { + s = "//Decompilation skipped"; + if (hilight) { + s = Highlighting.hilighMethod(s, this.method_info); + } + return s; + } try { s += Helper.timedCall(new Callable() { @Override diff --git a/trunk/src/com/jpexs/decompiler/flash/xfl/XFLConverter.java b/trunk/src/com/jpexs/decompiler/flash/xfl/XFLConverter.java index 36b424466..b56efe9a2 100644 --- a/trunk/src/com/jpexs/decompiler/flash/xfl/XFLConverter.java +++ b/trunk/src/com/jpexs/decompiler/flash/xfl/XFLConverter.java @@ -21,6 +21,7 @@ import com.jpexs.decompiler.flash.RetryTask; import com.jpexs.decompiler.flash.RunnableIOEx; import com.jpexs.decompiler.flash.SWF; import com.jpexs.decompiler.flash.SWFInputStream; +import com.jpexs.decompiler.flash.action.Action; import com.jpexs.decompiler.flash.helpers.Highlighting; import com.jpexs.decompiler.flash.tags.CSMTextSettingsTag; import com.jpexs.decompiler.flash.tags.DefineButton2Tag; @@ -1158,7 +1159,7 @@ public class XFLConverter { } private static String convertActionScript(ASMSource as) { - String decompiledASHilighted = com.jpexs.decompiler.flash.action.Action.actionsToSource(as.getActions(SWF.DEFAULT_VERSION), SWF.DEFAULT_VERSION, as.toString()); + String decompiledASHilighted = Action.actionsToSource(as.getActions(SWF.DEFAULT_VERSION), SWF.DEFAULT_VERSION, as.toString()); return as.getActionSourcePrefix() + Helper.indentRows(as.getActionSourceIndent(), Highlighting.stripHilights(decompiledASHilighted), Graph.INDENT_STRING) + as.getActionSourceSuffix(); }