diff --git a/CHANGELOG.md b/CHANGELOG.md index 218dccd31..9988770bc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,7 @@ All notable changes to this project will be documented in this file. - [#2478] Simple editor - remembering last frame / timeline - Optional heap memory status widget in the titlebar - [#2485] Show variable name in the text tree node label +- Deobfuscate identifiers option - non destructible renaming identifiers for display purposes ### Fixed - [#2474] Gotos incorrectly decompiled diff --git a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/exporters/SoundExporter.java b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/exporters/SoundExporter.java index f6e4f9649..2da941263 100644 --- a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/exporters/SoundExporter.java +++ b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/exporters/SoundExporter.java @@ -37,6 +37,7 @@ import com.jpexs.decompiler.flash.tags.gfx.DefineExternalStreamSound; import com.jpexs.decompiler.flash.timeline.SoundStreamFrameRange; import com.jpexs.decompiler.flash.types.sound.SoundExportFormat; import com.jpexs.decompiler.flash.types.sound.SoundFormat; +import com.jpexs.decompiler.graph.DottedChain; import com.jpexs.helpers.ByteArrayRange; import com.jpexs.helpers.CancellableWorker; import com.jpexs.helpers.Helper; @@ -52,6 +53,7 @@ import java.nio.file.StandardCopyOption; import java.util.ArrayList; import java.util.Arrays; import java.util.HashSet; +import java.util.LinkedHashSet; import java.util.List; import java.util.Set; @@ -123,6 +125,9 @@ public class SoundExporter { Set classNames = (st instanceof CharacterTag) ? ((CharacterTag) st).getClassNames() : new HashSet<>(); if (Configuration.as3ExportNamesUseClassNamesOnly.get() && !classNames.isEmpty()) { for (String className : classNames) { + if (Configuration.autoDeobfuscateIdentifiers.get()) { + className = DottedChain.parseNoSuffix(className).toPrintableString(new LinkedHashSet<>(), st.getSwf(), true); + } File classFile = new File(outdir + File.separator + Helper.makeFileName(className + ext)); new RetryTask(() -> { Files.copy(file.toPath(), classFile.toPath(), StandardCopyOption.REPLACE_EXISTING);