You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by ah...@apache.org on 2017/04/13 17:43:57 UTC
[26/50] git commit: [flex-falcon] [refs/heads/dual] -
MXMLFlexxJSEmitter: fixed JS output for MXML script and events to match
whitespace in tests
MXMLFlexxJSEmitter: fixed JS output for MXML script and events to match whitespace in tests
Project: http://git-wip-us.apache.org/repos/asf/flex-falcon/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-falcon/commit/f2e03cce
Tree: http://git-wip-us.apache.org/repos/asf/flex-falcon/tree/f2e03cce
Diff: http://git-wip-us.apache.org/repos/asf/flex-falcon/diff/f2e03cce
Branch: refs/heads/dual
Commit: f2e03cce9646adfca5685af7d273932e6701fed4
Parents: 43eae18
Author: Josh Tynjala <jo...@apache.org>
Authored: Fri Mar 24 15:09:12 2017 -0700
Committer: Josh Tynjala <jo...@apache.org>
Committed: Fri Mar 24 15:09:12 2017 -0700
----------------------------------------------------------------------
.../codegen/mxml/flexjs/MXMLFlexJSEmitter.java | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/f2e03cce/compiler-jx/src/main/java/org/apache/flex/compiler/internal/codegen/mxml/flexjs/MXMLFlexJSEmitter.java
----------------------------------------------------------------------
diff --git a/compiler-jx/src/main/java/org/apache/flex/compiler/internal/codegen/mxml/flexjs/MXMLFlexJSEmitter.java b/compiler-jx/src/main/java/org/apache/flex/compiler/internal/codegen/mxml/flexjs/MXMLFlexJSEmitter.java
index 6728cc2..2b19b87 100644
--- a/compiler-jx/src/main/java/org/apache/flex/compiler/internal/codegen/mxml/flexjs/MXMLFlexJSEmitter.java
+++ b/compiler-jx/src/main/java/org/apache/flex/compiler/internal/codegen/mxml/flexjs/MXMLFlexJSEmitter.java
@@ -1499,6 +1499,7 @@ public class MXMLFlexJSEmitter extends MXMLEmitter implements
writeNewline();
writeNewline();
+ writeNewline();
}
}
}
@@ -1527,15 +1528,19 @@ public class MXMLFlexJSEmitter extends MXMLEmitter implements
int len = node.getChildCount();
for (int i = 0; i < len; i++)
{
+ if (i > 0)
+ {
+ writeNewline();
+ }
IASNode cnode = node.getChild(i);
asEmitter.getWalker().walk(cnode);
- writeToken(ASEmitterTokens.SEMICOLON);
- writeNewline();
+ write(ASEmitterTokens.SEMICOLON);
}
- write(ASEmitterTokens.BLOCK_CLOSE);
- writeNewline(";");
+ indentPop();
writeNewline();
+ write(ASEmitterTokens.BLOCK_CLOSE);
+ writeNewline(ASEmitterTokens.SEMICOLON);
writeNewline();
}
}