From dfce77bd1f319e8dd6af88cb1ebe796d43d6bef2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jindra=20Pet=C5=99=C3=ADk?= Date: Mon, 23 Sep 2024 08:26:41 +0200 Subject: [PATCH] Fixed: #2313 AS3 direct editation - parsing class traits metadata --- CHANGELOG.md | 2 ++ .../flash/abc/avm2/parser/script/ActionScript3Parser.java | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 368d92fe6..6a65eb87d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -28,6 +28,7 @@ All notable changes to this project will be documented in this file. - AS3 direct editation - script slot/const traits assignments - AS3 direct editation - double returnvoid on script initializer - AS3 empty interface indentation +- [#2313] AS3 direct editation - parsing class traits metadata ## [21.0.5] - 2024-09-05 ### Fixed @@ -3580,6 +3581,7 @@ Major version of SWF to XML export changed to 2. [#2291]: https://www.free-decompiler.com/flash/issues/2291 [#2290]: https://www.free-decompiler.com/flash/issues/2290 [#2296]: https://www.free-decompiler.com/flash/issues/2296 +[#2313]: https://www.free-decompiler.com/flash/issues/2313 [#2293]: https://www.free-decompiler.com/flash/issues/2293 [#2294]: https://www.free-decompiler.com/flash/issues/2294 [#2299]: https://www.free-decompiler.com/flash/issues/2299 diff --git a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/avm2/parser/script/ActionScript3Parser.java b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/avm2/parser/script/ActionScript3Parser.java index a58e56809..fb7836915 100644 --- a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/avm2/parser/script/ActionScript3Parser.java +++ b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/avm2/parser/script/ActionScript3Parser.java @@ -669,7 +669,6 @@ public class ActionScript3Parser { String customNs = null; String rawCustomNs = null; NamespaceItem namespace = null; - ParsedSymbol s = lex(); //static class initializer /*if (s.type == SymbolType.CURLY_OPEN) { cinit.addAll(commands(allOpenedNamespaces, thisType, pkg, cinitNeedsActivation, importedClasses, openedNamespaces, new Stack<>(), new HashMap<>(), new HashMap<>(), true, false, 0, cinitVariables, abc)); @@ -679,7 +678,8 @@ public class ActionScript3Parser { }*/ List>> metadata = parseMetadata(); //s = lex(); - + + ParsedSymbol s = lex(); while (s.isType(SymbolType.NATIVE, SymbolType.STATIC, SymbolType.PUBLIC, SymbolType.PRIVATE, SymbolType.PROTECTED, SymbolType.OVERRIDE, SymbolType.FINAL, SymbolType.DYNAMIC, SymbolGroup.IDENTIFIER, SymbolType.INTERNAL, SymbolType.PREPROCESSOR)) { if (s.type == SymbolType.FINAL) { if (isFinal) {