use Basic components so we can run it on both SWF and JS and get it working for 
SWF.  Next up: JS


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/4f2f8e3f
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/4f2f8e3f
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/4f2f8e3f

Branch: refs/heads/develop
Commit: 4f2f8e3f90064e21dff268ef658911a2e3ae3002
Parents: de5406c
Author: Alex Harui <[email protected]>
Authored: Tue Aug 22 18:17:02 2017 -0700
Committer: Carlos Rovira <[email protected]>
Committed: Thu Sep 7 00:24:03 2017 +0200

----------------------------------------------------------------------
 .../RemoteObjectAMFTest/src/main/flex/App.mxml  | 22 +++++++++-----------
 1 file changed, 10 insertions(+), 12 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/4f2f8e3f/examples/flexjs/RemoteObjectAMFTest/src/main/flex/App.mxml
----------------------------------------------------------------------
diff --git a/examples/flexjs/RemoteObjectAMFTest/src/main/flex/App.mxml 
b/examples/flexjs/RemoteObjectAMFTest/src/main/flex/App.mxml
index 4ef6867..2709cff 100644
--- a/examples/flexjs/RemoteObjectAMFTest/src/main/flex/App.mxml
+++ b/examples/flexjs/RemoteObjectAMFTest/src/main/flex/App.mxml
@@ -35,6 +35,7 @@ limitations under the License.
                        private function onResult(evt:ResultEvent):void
                        {
                                trace("Result=" + evt.data);
+                               received.text = "Received: " + evt.data;
                        }
                        
                        private function onFault(evt:FaultEvent):void
@@ -45,7 +46,8 @@ limitations under the License.
        </fx:Script>
 
     <js:beads>
-        <js:RemoteObject id="service"
+        <js:ClassAliasBead />
+        <js:RemoteObject id="service" result="onResult(event)" 
fault="onFault(event)"
                          endPoint = 
"http://localhost:8080/messagebroker/websocket-amf";
                          destination = "exampleService"
                          source = "exampleService"/>
@@ -53,17 +55,13 @@ limitations under the License.
 
     <js:initialView>
         <js:View>
-            <mdl:Grid>
-                <mdl:TextField id="name_txt">
-                    <mdl:beads>
-                        <mdl:TextPrompt prompt="Text to be sent via AMF 
RemoteObject..."/>
-                        <mdl:Tooltip text="This sample requires an AMF 
Backend"/>
-                    </mdl:beads>
-                </mdl:TextField>
-                
-                <mdl:Button text="Send Name to AMF" raised="true"  
accent="true"
-                            click="sendName()"/>
-            </mdl:Grid>
+            <js:beads>
+                <js:VerticalLayout />
+            </js:beads>
+            <js:Label text="Text to be sent via AMF RemoteObject..." />
+            <js:TextInput id="name_txt" />
+            <js:TextButton text="Send Name to AMF" click="sendName()"/>
+                       <js:Label id="received" width="300"/>
         </js:View>
     </js:initialView>
 

Reply via email to