flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cd...@apache.org
Subject [05/10] git commit: [flex-asjs] [refs/heads/feature/maven-migration] - Adding CreateJS example.
Date Thu, 21 Apr 2016 11:44:50 GMT
Adding CreateJS example.


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

Branch: refs/heads/feature/maven-migration
Commit: 9a52f49f696330dd566c3e96f11f8d9e354370a9
Parents: 1f399ec
Author: Peter Ent <pent@apache.org>
Authored: Tue Apr 19 11:19:07 2016 -0400
Committer: Peter Ent <pent@apache.org>
Committed: Tue Apr 19 11:19:07 2016 -0400

----------------------------------------------------------------------
 examples/flexjs/CreateJSExample/build.xml       | 45 ++++++++++++++++++
 examples/flexjs/CreateJSExample/pom.xml         | 50 ++++++++++++++++++++
 .../CreateJSExample/src/CreateJSExample.mxml    | 42 ++++++++++++++++
 examples/flexjs/CreateJSExample/src/README.txt  | 26 ++++++++++
 .../CreateJSExample/src/models/MyModel.as       | 34 +++++++++++++
 5 files changed, 197 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9a52f49f/examples/flexjs/CreateJSExample/build.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/CreateJSExample/build.xml b/examples/flexjs/CreateJSExample/build.xml
new file mode 100644
index 0000000..6b8d2f2
--- /dev/null
+++ b/examples/flexjs/CreateJSExample/build.xml
@@ -0,0 +1,45 @@
+<?xml version="1.0"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+
+
+<project name="createjsexample" default="main" basedir=".">
+    <property name="FLEXJS_HOME" location="../../.."/>
+    <property name="example" value="CreateJSExample" />
+    
+    <property file="${FLEXJS_HOME}/env.properties"/>
+    <property environment="env"/>
+    <property file="${FLEXJS_HOME}/build.properties"/>
+    <property name="FLEX_HOME" value="${FLEXJS_HOME}"/>
+    <property name="opt1_arg" value="-js-output-optimization=skipAsCoercions" />
+
+    <include file="${basedir}/../../build_example.xml" />
+    
+    <target name="main" depends="clean,build_example.compile,build_example.compilejs"
description="Clean build of ${example}">
+    </target>
+    
+    <target name="clean">
+        <delete dir="${basedir}/bin" failonerror="false" />
+        <delete dir="${basedir}/bin-debug" failonerror="false" />
+        <delete dir="${basedir}/bin-release" failonerror="false" />
+    </target>
+
+    
+    
+</project>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9a52f49f/examples/flexjs/CreateJSExample/pom.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/CreateJSExample/pom.xml b/examples/flexjs/CreateJSExample/pom.xml
new file mode 100644
index 0000000..286e2ae
--- /dev/null
+++ b/examples/flexjs/CreateJSExample/pom.xml
@@ -0,0 +1,50 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.flex.examples.flexjs</groupId>
+        <artifactId>examples</artifactId>
+        <version>1.0.0-SNAPSHOT</version>
+    </parent>
+
+    <artifactId>DataBindingExample</artifactId>
+    <version>1.0.0-SNAPSHOT</version>
+    <packaging>swf</packaging>
+
+    <build>
+        <sourceDirectory>src</sourceDirectory>
+        <plugins>
+            <plugin>
+                <groupId>net.flexmojos.oss</groupId>
+                <artifactId>flexmojos-maven-plugin</artifactId>
+                <version>7.1.0-SNAPSHOT</version>
+                <extensions>true</extensions>
+                <configuration>
+                    <sourceFile>DataBindingExample.mxml</sourceFile>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+
+</project>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9a52f49f/examples/flexjs/CreateJSExample/src/CreateJSExample.mxml
----------------------------------------------------------------------
diff --git a/examples/flexjs/CreateJSExample/src/CreateJSExample.mxml b/examples/flexjs/CreateJSExample/src/CreateJSExample.mxml
new file mode 100644
index 0000000..f7c8768
--- /dev/null
+++ b/examples/flexjs/CreateJSExample/src/CreateJSExample.mxml
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You under the Apache License, Version 2.0
+(the "License"); you may not use this file except in compliance with
+the License.  You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+-->
+<cjs:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
+                   xmlns:local="*"
+                   xmlns:js="library://ns.apache.org/flexjs/basic" 
+                   xmlns:cjs="library://ns.apache.org/flexjs/createjs"
+                   >
+
+    <js:valuesImpl>
+        <js:SimpleCSSValuesImpl />
+    </js:valuesImpl>
+    
+    <js:initialView>
+        <cjs:View>
+        
+			<cjs:Circle x="100" y="120" width="100" height="100">
+				<js:fill>
+					<js:SolidColor color="#26C9FF" />
+				</js:fill>
+			</cjs:Circle>
+   		    
+        </cjs:View>
+    </js:initialView>
+
+</cjs:Application>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9a52f49f/examples/flexjs/CreateJSExample/src/README.txt
----------------------------------------------------------------------
diff --git a/examples/flexjs/CreateJSExample/src/README.txt b/examples/flexjs/CreateJSExample/src/README.txt
new file mode 100644
index 0000000..4e51a64
--- /dev/null
+++ b/examples/flexjs/CreateJSExample/src/README.txt
@@ -0,0 +1,26 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+DESCRIPTION
+
+This is an example of using the CreateJS framework in FlexJS. The example follows the first
+demo on the CreateJS/EaselJS site, drawing a simple circle.
+
+This example shows how CreateJS can be used with MXML, supplying the object and some of its
+properties directly in MXML.

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9a52f49f/examples/flexjs/CreateJSExample/src/models/MyModel.as
----------------------------------------------------------------------
diff --git a/examples/flexjs/CreateJSExample/src/models/MyModel.as b/examples/flexjs/CreateJSExample/src/models/MyModel.as
new file mode 100644
index 0000000..9092424
--- /dev/null
+++ b/examples/flexjs/CreateJSExample/src/models/MyModel.as
@@ -0,0 +1,34 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package models
+{
+	import org.apache.flex.events.Event;
+	import org.apache.flex.events.EventDispatcher;
+
+	/**
+	 * This model exists to satisfy the requirement that FlexJS apps have
+	 * models.
+	 */
+	public class MyModel extends EventDispatcher
+	{
+		public function MyModel()
+		{
+		}
+	}
+}


Mime
View raw message