Ok, I've reduced the number of setup steps and posted on the wiki here:

https://cwiki.apache.org/confluence/display/FLEX/Using+FlexJS+with+Adobe+Fla
sh+Builder

Feedback welcome,
-Alex

On 2/25/13 4:29 PM, "Om" <bigosma...@gmail.com> wrote:

> Thanks for this Alex.  I am trying to keep up as much as possible.  Do you
> mind putting these instructions up on the wiki as well?
> 
> Thanks,
> Om
> 
> On Mon, Feb 25, 2013 at 4:26 PM, Alex Harui <aha...@adobe.com> wrote:
> 
>> OK, time for another update before I get lost in ApacheCon:
>> 
>> I¹ve added the FalconJS stuff to the FlexJSOverlay.zip.  You can now use
>> Flash Builder to create non-Flash "apps".
>> 
>> We have prototypes of a List, Button, Label, TextArea, and TextInput
>> We have a prototype of a HTTPService and a LazyCollection
>> The FlexJSSDKTest example is updated so you can choose a stock symbol from
>> the List, hit a Button and see the stock price in the Label
>> 
>> If you want to play with the this stuff and are too lazy to build from the
>> sources, I have hacked together a way for you to try it in Flash Builder.
>> 
>> Setup instructions are:
>> 
>> 1) Get Apache Flex 4.9 working in FB.  (I tried it with FB 4.7, but not FB
>> 4.6)
>> 2) Shut down FB
>> 3) Make a copy of your Apache Flex 4.9 folder.  The zip file contains a
>> shell script that will neuter the Flex aspects of this folder and replace
>> it
>> with FlexJS stuff.
>> 4) Unzip FlexJSOverlay into a some other folder.
>> 5) Change to that folder and run deploy.sh or deploy.bat <path to copy of
>> Apache Flex 4.9 folder>
>> 6) Run Flash Builder
>> 7) In the Flash Builder Preferences menu add this new folder as a Flex SDK.
>> 8) Choose from the File menu, Import, Run/Debug, Launch Configurations
>> 9) Choose the ide/flashbuilder folder from this copy of Apache Flex 4.9 we
>> are mucking with.
>> 10) There should now be four new configs in the Run menu under External
>> Tools
>> 11) Go to External Tools Configuration
>> 12) Select one of the configs
>> 13) Hit the variables button
>> 14) Hit the Edit Variables button
>> 15) Change FLEX_HOME to point to the modified Apache Flex SDK.
>> 16) Install Google Closure library
>> 17) For each of the two FalconJS configs, edit the launch configurations
>> environment variables to set FLEXJS_HOME to the js/src of your overlaid SDK
>> 18) For each of the two FalconJS configs, edit the launch configurations
>> environment variables to set GOOG_HOME to the goog folder of your
>> GoogleClosure install.
>> 19) For each of the four launch configurations, ensure that the location
>> field points to the Java runtime.
>> 
>> Now for each project:
>> 
>> 1) Create a new Flex Project
>> 2) Choose this modified Apache Flex SDK
>> 3) Do not change the output folder from bin-debug
>> 4) Flash Builder will generate a totally messed up Application tag so
>> replace it with this template:
>> 
>> <?xml version="1.0" encoding="utf-8"?>
>> <basic:Application xmlns:fx="http://ns.adobe.com/mxml/2009";
>>                    xmlns:basic="library://ns.apache.org/flexjs/basic"
>>> 
>> </basic:Application>
>> 
>> Source Code
>> 
>> Right now, Application doesn¹t contain any UI, it takes another MXML file
>> as
>> the initialView property and a model and a controller.  You can reference
>> the example in FlexJSSDKTest.
>> 
>> Building and Running/Debugging
>> 
>> As you edit the code, the regular Flex compiler is compiling and reporting
>> errors, but it only knows how to build Flex SWFs so the output SWF probably
>> won¹t run.  So, before you debug, choose from the Run menu the new External
>> Tool: ³FlexJS (Debug Build)².  This will run the Falcon compiler with the
>> right options to generate a SWF in the bin-debug folder that overwrites the
>> one that is there.  Then you should be able to set breakpoints and debug.
>> 
>> Once you have your app working as a SWF, try one of the FalconJS tools.  It
>> will output by default to the binjs-debug or binjs-release folder.  If you
>> run the FalconJS debug configuration, see the console output for
>> instructions on how to copy the goog and FlexJS source folders into your
>> binjs-debug folder.
>> 
>> I¹m sure there¹ll be lots of issues, but feel free to comment or
>> contribute.
>> Remember, this is in its infancy so it will likely fall down easily and
>> poop
>> unexpectedly.
>> 
>> --
>> Alex Harui
>> Flex SDK Team
>> Adobe Systems, Inc.
>> http://blogs.adobe.com/aharui
>> 
>> 

-- 
Alex Harui
Flex SDK Team
Adobe Systems, Inc.
http://blogs.adobe.com/aharui

Reply via email to