You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@royale.apache.org by yi...@apache.org on 2021/11/09 05:18:21 UTC
[royale-asjs] branch develop updated: Make some changes to Ace
example app because JS isn't loaded in init time.
This is an automated email from the ASF dual-hosted git repository.
yishayw pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git
The following commit(s) were added to refs/heads/develop by this push:
new 7cf307c Make some changes to Ace example app because JS isn't loaded in init time.
7cf307c is described below
commit 7cf307cbe2e38816d7abff96416c76d6f5146cba
Author: Yishay Weiss <yi...@hotmail.com>
AuthorDate: Tue Nov 9 07:17:23 2021 +0200
Make some changes to Ace example app because JS isn't loaded in init
time.
---
examples/royale/Ace/src/main/royale/Ace.mxml | 17 ++++++++++++++---
1 file changed, 14 insertions(+), 3 deletions(-)
diff --git a/examples/royale/Ace/src/main/royale/Ace.mxml b/examples/royale/Ace/src/main/royale/Ace.mxml
index 06f9da3..e291d6d 100644
--- a/examples/royale/Ace/src/main/royale/Ace.mxml
+++ b/examples/royale/Ace/src/main/royale/Ace.mxml
@@ -23,11 +23,22 @@ limitations under the License.
<js:valuesImpl>
<js:SimpleCSSValuesImpl />
</js:valuesImpl>
+<fx:Style>
+
+ global {
+ IStatesImpl: ClassReference("org.apache.royale.core.SimpleStatesImpl");
+ }
+ </fx:Style>
<js:initialView>
- <js:View>
+ <js:View id="mainView">
+ <js:states>
+ <js:State name="editorExcluded"/>
+ <js:State name="editorIncluded"/>
+ </js:states>
<js:VContainer>
- <js:Label text="Hello World!" />
- <ace:ACEEditor id="myEditor" width="400" height="400"/>
+ <js:TextButton text="Add Ace Editor" click="mainView.currentState='editorIncluded'"/>
+ <js:Spacer height="20" includeIn="editorIncluded"/>
+ <ace:ACEEditor includeIn="editorIncluded" id="myEditor" width="400" height="400"/>
</js:VContainer>
</js:View>
</js:initialView>