From eec91777e6abec911c74d60bf9a8c871b1ad1b2e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jindra=20Pet=C5=99=C3=ADk?= Date: Sat, 13 Feb 2021 16:47:51 +0100 Subject: [PATCH] Fixed: #1339 AS1/2 direct editation - targetPath as an expression --- CHANGELOG.md | 1 + .../action/parser/script/ActionScript2Parser.java | 14 +++++++------- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f2166c3ac..93636f06d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ All notable changes to this project will be documented in this file. - #1298 AS1/2 properly decompiled setProperty/getProperty - AS1/2 Direct editation mark line on error - Collapsing tag tree on SWF reload +- #1339 AS1/2 direct editation - targetPath as an expression ## [13.0.3] - 2021-02-12 ### Added diff --git a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/action/parser/script/ActionScript2Parser.java b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/action/parser/script/ActionScript2Parser.java index b7eb39e61..342ea974c 100644 --- a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/action/parser/script/ActionScript2Parser.java +++ b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/action/parser/script/ActionScript2Parser.java @@ -12,7 +12,8 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library. */ + * License along with this library. + */ package com.jpexs.decompiler.flash.action.parser.script; import com.jpexs.decompiler.flash.SourceGeneratorLocalData; @@ -539,6 +540,11 @@ public class ActionScript2Parser { expectedType(SymbolType.PARENT_CLOSE); ret = new GetTimeActionItem(null, null); break; + case TARGETPATH: + expectedType(SymbolType.PARENT_OPEN); + ret = new TargetPathActionItem(null, null, (expression(inFunction, inMethod, true, variables, functions))); + expectedType(SymbolType.PARENT_CLOSE); + break; default: return null; } @@ -706,12 +712,6 @@ public class ActionScript2Parser { ret = new StopDragActionItem(null, null); break; - case TARGETPATH: - expectedType(SymbolType.PARENT_OPEN); - ret = new TargetPathActionItem(null, null, (expression(inFunction, inMethod, true, variables, functions))); - expectedType(SymbolType.PARENT_CLOSE); - break; - case UNLOADMOVIE: case UNLOADMOVIENUM: SymbolType unloadType = s.type;