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 2016/06/11 05:13:08 UTC
[1/3] git commit: [flex-asjs] [refs/heads/develop] - add a helloworld
example
Repository: flex-asjs
Updated Branches:
refs/heads/develop f7afff254 -> a894f963e
add a helloworld 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/8a8fc6e0
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/8a8fc6e0
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/8a8fc6e0
Branch: refs/heads/develop
Commit: 8a8fc6e06f546c8578a95e103a080a6cf9e61f42
Parents: f7afff2
Author: Alex Harui <ah...@apache.org>
Authored: Fri Jun 10 13:26:16 2016 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Jun 10 13:26:16 2016 -0700
----------------------------------------------------------------------
examples/flexjs/HelloWorld/build.xml | 44 +++++++++++++++++++++
examples/flexjs/HelloWorld/src/HelloWorld.mxml | 30 ++++++++++++++
2 files changed, 74 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/8a8fc6e0/examples/flexjs/HelloWorld/build.xml
----------------------------------------------------------------------
diff --git a/examples/flexjs/HelloWorld/build.xml b/examples/flexjs/HelloWorld/build.xml
new file mode 100644
index 0000000..0e2d763
--- /dev/null
+++ b/examples/flexjs/HelloWorld/build.xml
@@ -0,0 +1,44 @@
+<?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="helloworld" default="main" basedir=".">
+ <property name="FLEXJS_HOME" location="../../.."/>
+ <property name="example" value="HelloWorld" />
+
+ <property file="${FLEXJS_HOME}/env.properties"/>
+ <property environment="env"/>
+ <property file="${FLEXJS_HOME}/build.properties"/>
+ <property name="FLEX_HOME" value="${FLEXJS_HOME}"/>
+
+ <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/8a8fc6e0/examples/flexjs/HelloWorld/src/HelloWorld.mxml
----------------------------------------------------------------------
diff --git a/examples/flexjs/HelloWorld/src/HelloWorld.mxml b/examples/flexjs/HelloWorld/src/HelloWorld.mxml
new file mode 100644
index 0000000..70d8d20
--- /dev/null
+++ b/examples/flexjs/HelloWorld/src/HelloWorld.mxml
@@ -0,0 +1,30 @@
+<?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.
+
+-->
+<js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
+ xmlns:js="library://ns.apache.org/flexjs/basic" >
+ <js:valuesImpl>
+ <js:SimpleCSSValuesImpl />
+ </js:valuesImpl>
+ <js:initialView>
+ <js:View>
+ <js:Label text="Hello World!" />
+ </js:View>
+ </js:initialView>
+</js:Application>
[3/3] git commit: [flex-asjs] [refs/heads/develop] - launch scripts
to convert a new Flex project to a FlexJS project in FB
Posted by ah...@apache.org.
launch scripts to convert a new Flex project to a FlexJS project in FB
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/a894f963
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/a894f963
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/a894f963
Branch: refs/heads/develop
Commit: a894f963e1e1fdb73e39c2a38239d8a15c2607af
Parents: f9ddca5
Author: Alex Harui <ah...@apache.org>
Authored: Fri Jun 10 22:12:53 2016 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Jun 10 22:12:53 2016 -0700
----------------------------------------------------------------------
...ew Flex Project to FlexJS MVC Project.launch | 19 ++++++
...rt New Flex Project to FlexJS Project.launch | 17 ++++++
ide/flashbuilder/FlexJS (Cordova Build).launch | 2 +-
ide/flashbuilder/FlexJS (Cordova Run).launch | 2 +-
ide/flashbuilder/antscripts.xml | 61 ++++++++++++++++++++
installer.xml | 20 +++++++
6 files changed, 119 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a894f963/ide/flashbuilder/Convert New Flex Project to FlexJS MVC Project.launch
----------------------------------------------------------------------
diff --git a/ide/flashbuilder/Convert New Flex Project to FlexJS MVC Project.launch b/ide/flashbuilder/Convert New Flex Project to FlexJS MVC Project.launch
new file mode 100644
index 0000000..98b6498
--- /dev/null
+++ b/ide/flashbuilder/Convert New Flex Project to FlexJS MVC Project.launch
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<launchConfiguration type="org.eclipse.ant.AntLaunchConfigurationType">
+<booleanAttribute key="org.eclipse.ant.ui.DEFAULT_VM_INSTALL" value="true"/>
+<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS"/>
+<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES"/>
+<mapAttribute key="org.eclipse.debug.core.environmentVariables">
+<mapEntry key="ANT_HOME" value="/Applications/Adobe Flash Builder 4.7/eclipse/plugins/org.apache.ant_1.8.2.v20110505-1300"/>
+<mapEntry key="PATH" value="/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin"/>
+</mapAttribute>
+<stringAttribute key="org.eclipse.jdt.launching.CLASSPATH_PROVIDER" value="org.eclipse.ant.ui.AntClasspathProvider"/>
+<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.eclipse.ant.internal.launching.remote.InternalAntRunner"/>
+<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value=""/>
+<stringAttribute key="org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER" value="org.eclipse.ant.ui.AntClasspathProvider"/>
+<stringAttribute key="org.eclipse.ui.externaltools.ATTR_ANT_TARGETS" value="convert_project_mvc,"/>
+<booleanAttribute key="org.eclipse.ui.externaltools.ATTR_HIDE_INTERNAL_TARGETS" value="true"/>
+<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="$FLEXJS_HOME/ide/flashbuilder/antscripts.xml"/>
+<stringAttribute key="org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS" value="-DprojectDir="${project_loc}""/>
+<stringAttribute key="process_factory_id" value="org.eclipse.ant.ui.remoteAntProcessFactory"/>
+</launchConfiguration>
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a894f963/ide/flashbuilder/Convert New Flex Project to FlexJS Project.launch
----------------------------------------------------------------------
diff --git a/ide/flashbuilder/Convert New Flex Project to FlexJS Project.launch b/ide/flashbuilder/Convert New Flex Project to FlexJS Project.launch
new file mode 100644
index 0000000..0224b51
--- /dev/null
+++ b/ide/flashbuilder/Convert New Flex Project to FlexJS Project.launch
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<launchConfiguration type="org.eclipse.ant.AntLaunchConfigurationType">
+<booleanAttribute key="org.eclipse.ant.ui.DEFAULT_VM_INSTALL" value="true"/>
+<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS"/>
+<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES"/>
+<mapAttribute key="org.eclipse.debug.core.environmentVariables">
+<mapEntry key="PATH" value="/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin"/>
+</mapAttribute>
+<stringAttribute key="org.eclipse.jdt.launching.CLASSPATH_PROVIDER" value="org.eclipse.ant.ui.AntClasspathProvider"/>
+<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.eclipse.ant.internal.launching.remote.InternalAntRunner"/>
+<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value=""/>
+<stringAttribute key="org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER" value="org.eclipse.ant.ui.AntClasspathProvider"/>
+<booleanAttribute key="org.eclipse.ui.externaltools.ATTR_HIDE_INTERNAL_TARGETS" value="true"/>
+<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="$FLEXJS_HOME/ide/flashbuilder/antscripts.xml"/>
+<stringAttribute key="org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS" value="-DprojectDir=""{project_loc}""/>
+<stringAttribute key="process_factory_id" value="org.eclipse.ant.ui.remoteAntProcessFactory"/>
+</launchConfiguration>
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a894f963/ide/flashbuilder/FlexJS (Cordova Build).launch
----------------------------------------------------------------------
diff --git a/ide/flashbuilder/FlexJS (Cordova Build).launch b/ide/flashbuilder/FlexJS (Cordova Build).launch
index 4d9dc2d..f7223d1 100644
--- a/ide/flashbuilder/FlexJS (Cordova Build).launch
+++ b/ide/flashbuilder/FlexJS (Cordova Build).launch
@@ -12,7 +12,7 @@
<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value=""/>
<stringAttribute key="org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER" value="org.eclipse.ant.ui.AntClasspathProvider"/>
<booleanAttribute key="org.eclipse.ui.externaltools.ATTR_HIDE_INTERNAL_TARGETS" value="true"/>
-<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="/Users/pent/dev/flex-asjs/cordova-build.xml"/>
+<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="$FLEXJS_HOME/cordova-build.xml"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS" value="-Dprojectdir=${project_loc}"/>
<stringAttribute key="process_factory_id" value="org.eclipse.ant.ui.remoteAntProcessFactory"/>
</launchConfiguration>
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a894f963/ide/flashbuilder/FlexJS (Cordova Run).launch
----------------------------------------------------------------------
diff --git a/ide/flashbuilder/FlexJS (Cordova Run).launch b/ide/flashbuilder/FlexJS (Cordova Run).launch
index 354e9cf..a71cdee 100644
--- a/ide/flashbuilder/FlexJS (Cordova Run).launch
+++ b/ide/flashbuilder/FlexJS (Cordova Run).launch
@@ -14,7 +14,7 @@
<stringAttribute key="org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER" value="org.eclipse.ant.ui.AntClasspathProvider"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_ANT_TARGETS" value="run,"/>
<booleanAttribute key="org.eclipse.ui.externaltools.ATTR_HIDE_INTERNAL_TARGETS" value="true"/>
-<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="/Users/pent/dev/flex-asjs/cordova-build.xml"/>
+<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="$FLEXJS_HOME/cordova-build.xml"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS" value="-Dprojectdir=${project_loc}"/>
<stringAttribute key="process_factory_id" value="org.eclipse.ant.ui.remoteAntProcessFactory"/>
</launchConfiguration>
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a894f963/ide/flashbuilder/antscripts.xml
----------------------------------------------------------------------
diff --git a/ide/flashbuilder/antscripts.xml b/ide/flashbuilder/antscripts.xml
new file mode 100644
index 0000000..fe51e8f
--- /dev/null
+++ b/ide/flashbuilder/antscripts.xml
@@ -0,0 +1,61 @@
+<?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="flashbuilder_antscripts" default="convert_project" basedir=".">
+
+ <property environment="env"/>
+
+ <condition property="isWindows" value="windows">
+ <os family="windows" />
+ </condition>
+
+ <target name="check_params" >
+ <fail unless="projectDir"
+ message="projectDir parameter not set" />
+ <fail message="projectDir ${projectDir} does not exist">
+ <condition>
+ <not>
+ <available file="${projectDir}" />
+ </not>
+ </condition>
+ </fail>
+ </target>
+
+ <target name="convert_project" depends="check_params, cutpath" description="Replaces the files in a new Flex project folder with a basic FlexJS project">
+ <copy file="${basedir}/../../examples/flexjs/HelloWorld/src/HelloWorld.mxml" tofile="${projectDir}/src/${projectName}.mxml" overwrite="true" />
+ </target>
+
+ <target name="convert_project_mvc" depends="check_params, cutpath" description="Replaces the files in a new Flex project folder with a basic FlexJS MVC project">
+ <copy file="${basedir}/../../examples/flexjs/DataBindingExample/src/DataBindingExample.mxml" tofile="${projectDir}/src/${projectName}.mxml" overwrite="true" />
+ <copy file="${basedir}/../../examples/flexjs/DataBindingExample/src/MyInitialView.mxml" tofile="${projectDir}/src/MyInitialView.mxml" overwrite="true" />
+ <mkdir dir="${projectDir}/src/models" />
+ <mkdir dir="${projectDir}/src/controllers" />
+ <copy file="${basedir}/../../examples/flexjs/DataBindingExample/src/StockDataJSONItemConverter.as" tofile="${projectDir}/src/StockDataJSONItemConverter.as" overwrite="true" />
+ <copy file="${basedir}/../../examples/flexjs/DataBindingExample/src/models/MyModel.as" tofile="${projectDir}/src/models/MyModel.as" overwrite="true" />
+ <copy file="${basedir}/../../examples/flexjs/DataBindingExample/src/controllers/MyController.as" tofile="${projectDir}/src/controllers/MyController.as" overwrite="true" />
+ <replace file="${projectDir}/src/controllers/MyController.as" token="DataBindingExample" value="${projectName}" />
+ </target>
+
+ <target name="cutpath" >
+ <basename file="${projectDir}" property="projectName" />
+ <echo>projectDir: ${projectDir}</echo>
+ <echo>projectName: ${projectName}</echo>
+ </target>
+</project>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/a894f963/installer.xml
----------------------------------------------------------------------
diff --git a/installer.xml b/installer.xml
index 75814cf..20808bf 100644
--- a/installer.xml
+++ b/installer.xml
@@ -954,6 +954,26 @@ tofile="${FLEXJS_HOME}/frameworks/themes/Halo/Halo.swc" />
token="$FLEXJS_HOME"
value="${FLEXJS_HOME}"/>
</replace>
+ <replace file="${FLEXJS_HOME}/ide/flashbuilder/FlexJS (Cordova Build).launch">
+ <replacefilter
+ token="$FLEXJS_HOME"
+ value="${FLEXJS_HOME}"/>
+ </replace>
+ <replace file="${FLEXJS_HOME}/ide/flashbuilder/FlexJS (Cordova Run).launch">
+ <replacefilter
+ token="$FLEXJS_HOME"
+ value="${FLEXJS_HOME}"/>
+ </replace>
+ <replace file="${FLEXJS_HOME}/ide/flashbuilder/Convert New Flex Project to FlexJS MVC Project.launch">
+ <replacefilter
+ token="$FLEXJS_HOME"
+ value="${FLEXJS_HOME}"/>
+ </replace>
+ <replace file="${FLEXJS_HOME}/ide/flashbuilder/Convert New Flex Project to FlexJS Project.launch">
+ <replacefilter
+ token="$FLEXJS_HOME"
+ value="${FLEXJS_HOME}"/>
+ </replace>
<replace file="${FLEXJS_HOME}/js/bin/mxmlc.bat">
<replacefilter
token="@java"
[2/3] git commit: [flex-asjs] [refs/heads/develop] - force label to
be single-line
Posted by ah...@apache.org.
force label to be single-line
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/f9ddca52
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/f9ddca52
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/f9ddca52
Branch: refs/heads/develop
Commit: f9ddca525496c8baf35d0350fdd75186d2fb4bb7
Parents: 8a8fc6e
Author: Alex Harui <ah...@apache.org>
Authored: Fri Jun 10 13:26:32 2016 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Jun 10 13:26:32 2016 -0700
----------------------------------------------------------------------
.../projects/HTML/src/main/flex/org/apache/flex/html/Label.as | 1 +
1 file changed, 1 insertion(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/f9ddca52/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Label.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Label.as b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Label.as
index 392dcca..2512a31 100644
--- a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Label.as
+++ b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Label.as
@@ -156,6 +156,7 @@ package org.apache.flex.html
element = document.createElement('span') as WrappedHTMLElement;
positioner = element;
element.flexjs_wrapper = this;
+ element.style.whiteSpace = "nowrap";
return element;
}