Awesome! I hope to finish up FDB this week and then work on packaging. I’ll try integrating your stuff then. I looked at your changes a few days ago and it looked reasonable.
Just to be sure, does this still require some parts of a regular Flex SDK or is a FlexJS SDK now working on its own? -Alex On 5/28/15, 11:22 AM, "Frédéric THOMAS" <webdoubl...@hotmail.com> wrote: >Almost the end. > >So, to come back on this, at the moment with my current implementation, >we can compile Applications and Libraries and link them together >overriding the IntelliJ configuration as show here >http://snag.gy/5SzuG.jpg the second build configuarion suffixed by _JS >guess what, is to compile to JS, to create it, it's enough to copy the >first build configuration and add the -js-output-type to any of the >current valid output type. > >Not perfect and not what I was hoping but still, that's much more better >than using external tools and it is per build configuration, not one for >all of your projects. > >A better integration could happen if I find time to code an IntelliJ >plugin for FlexJS though, let see first how it will be adopted, the >current integration seems still pretty descent. > >So, I would like better compiler expert to review my code as it was my >first compiler contribution, the branch is IDEA_JS_COMPILER (sorry, I >forgot to prefix with ticket ID) > >Maybe it would be opportune to create a binary kit for people would want >to test it and return feedback, maybe we can also wait for the Alex work >about FDB and see how to deal better with swfutils.jar as at the moment >I'm using the one of the Flex SDK. > >thought ? > >Thanks, >Frédéric THOMAS > > >> From: webdoubl...@hotmail.com >> To: dev@flex.apache.org >> Subject: RE: AW: AW: AW: [FlexJS] IntelliJ Integration >> Date: Thu, 28 May 2015 14:41:03 +0100 >> >> The result of the empty spark.css [1] :-) >> >> If I let only the NS, it creates the swf but crashes because it can't >>find IStateClient2 >> >> Frédéric THOMAS >> >> [1] >> Error:[DataBindingTest]: : java.lang.NullPointerException at >>org.antlr.runtime.tree.BaseTreeAdaptor.isNil(BaseTreeAdaptor.java:73) >> at >>org.antlr.runtime.tree.CommonTreeNodeStream.nextElement(CommonTreeNodeStr >>eam.java:104) at >>org.antlr.runtime.misc.LookaheadStream.fill(LookaheadStream.java:113) >> at >>org.antlr.runtime.misc.LookaheadStream.syncAhead(LookaheadStream.java:107 >>) at >>org.antlr.runtime.misc.LookaheadStream.LT(LookaheadStream.java:129) >>at >>org.apache.flex.compiler.internal.css.CSSTree.stylesheet(CSSTree.java:200 >>) at >>org.apache.flex.compiler.internal.css.CSSDocument.parse(CSSDocument.java: >>81) at >>org.apache.flex.compiler.internal.caches.CSSDocumentCache$CSSDocumentCach >>eKey2.parse(CSSDocumentCache.java:280) at >>org.apache.flex.compiler.internal.caches.CSSDocumentCache.createEntryValu >>e(CSSDocumentCache.java:323) at >>org.apache.flex.compiler.internal.caches.CSSDocumentCache.createEntryValu >>e(CSSDocumentCache.java:54) at >>org.apache.flex.compiler.internal.caches.ConcurrentCacheStoreBase.get(Con >>currentCacheStoreBase.java:69) at >>org.apache.flex.compiler.internal.css.CSSManager.getCSSFromThemes(CSSMana >>ger.java:251) at >>org.apache.flex.compiler.internal.targets.FlexAppSWFTarget.collectThemes( >>FlexAppSWFTarget.java:553) at >>org.apache.flex.compiler.internal.targets.FlexAppSWFTarget.findAllCompila >>tionUnitsToLink(FlexAppSWFTarget.java:493) at >>org.apache.flex.compiler.internal.targets.Target.buildAllCompilationUnits >>(Target.java:297) at >>org.apache.flex.compiler.internal.targets.Target.getBuiltCompilationUnitS >>et(Target.java:306) at >>org.apache.flex.compiler.internal.targets.SWFTarget.build(SWFTarget.java: >>228) at >>org.apache.flex.compiler.clients.MXMLC.buildSWFModel(MXMLC.java:760) >> at org.apache.flex.compiler.clients.MXMLC.buildArtifact(MXMLC.java:746) >> at org.apache.flex.compiler.clients.MXMLC.compile(MXMLC.java:625) >> at org.apache.flex.compiler.clients.MXMLC.compile(MXMLC.java:611) >> at org.apache.flex.compiler.clients.MXMLC.mainNoExit(MXMLC.java:230) >> at org.apache.flex.compiler.clients.MXMLC.mainNoExit(MXMLC.java:198) >> at org.apache.flex.compiler.clients.MXMLC.execute(MXMLC.java:185) >> at flex2.tools.Tool.compile(Tool.java:62) at >>flex2.tools.Mxmlc.mxmlc(Mxmlc.java:72) at >>com.intellij.flex.compiler.flex4.Flex4Handler.compileSwf(Flex4Handler.jav >>a:81) at >>com.intellij.flex.compiler.CompilationThread.run(CompilationThread.java:4 >>8) >> >> > From: webdoubl...@hotmail.com >> > To: dev@flex.apache.org >> > Subject: RE: AW: AW: AW: [FlexJS] IntelliJ Integration >> > Date: Thu, 28 May 2015 14:09:29 +0100 >> > >> > > Just quickly, I noticed the gist contains a different set of >>namespaces, >> > > therefore excluding all of our new components, and still had a theme >> > > pointing at spark.css. The flex-config.xml in a FlexJS SDK has a >> > > different set of manifest.xml files and nothing in the theme tag. >> > >> > Not sure at all it would help, my guess is that it has its own rule >>to write its config.xml, the only way I guess would be a plugin to >>override its behaviour. >> > >> > > And for the theme, maybe an empty Spark.css will work. >> > >> > I can try that >> > >> > Frédéric THOMAS >> > >> > > From: aha...@adobe.com >> > > To: dev@flex.apache.org >> > > Subject: Re: AW: AW: AW: [FlexJS] IntelliJ Integration >> > > Date: Thu, 28 May 2015 12:58:45 +0000 >> > > >> > > Hi Fred, >> > > >> > > Just quickly, I noticed the gist contains a different set of >>namespaces, >> > > therefore excluding all of our new components, and still had a theme >> > > pointing at spark.css. The flex-config.xml in a FlexJS SDK has a >> > > different set of manifest.xml files and nothing in the theme tag. >> > > >> > > I wonder if leaving a basic-manifest.xml in the SDK folder will >>convince >> > > IJ to use that, or if we have to copy basic-manifest into >>mxml-manifest. >> > > >> > > And for the theme, maybe an empty Spark.css will work. >> > > >> > > Thanks for digging into this, >> > > -Alex >> > > >> > > On 5/28/15, 3:57 AM, "Frédéric THOMAS" <webdoubl...@hotmail.com> >>wrote: >> > > >> > > >Actually, it is more complicated. >> > > > >> > > >This is what it is generated by IJ: >> > > > >> > > >https://gist.github.com/doublefx/ae135f1886cc2800c08d >> > > > >> > > >And I added the flex-config.xml from the framework, this one >>overrides >> > > >the one of IJ apparently >> > > > >> > > >it results: >> > > > >> > > >Information:28/05/2015 11:16 - Compilation completed with 7 errors >>and 11 >> > > >warnings >> > > >U:\sources\flexJsProjects\DataBindingTest\src\DataBindingTest.mxml >> > > >Error:(26, 19) [DataBindingTest]: Call to a possibly undefined >>method >> > > >MyModel. >> > > >Warning:(30, 15) [DataBindingTest]: Definition models.MyModel >>could not >> > > >be found. >> > > >Error:(40, 8) [DataBindingTest]: This tag could not be resolved to >>an >> > > >ActionScript class. It will be ignored. >> > > >U:\sources\flexJsProjects\DataBindingTest\src\MyInitialView.mxml >> > > >Warning:(26, 10) [DataBindingTest]: Definition models.MyModel >>could not >> > > >be found. >> > > >Error:(53, 24) [DataBindingTest]: Call to a possibly undefined >>method >> > > >MyModel. >> > > >Error:(54, 27) [DataBindingTest]: Call to a possibly undefined >>method >> > > >MyModel. >> > > >Warning:(119, 50) [DataBindingTest]: Data binding will not be able >>to >> > > >detect assignments to 'MyModel'. >> > > >Warning:(119, 76) [DataBindingTest]: Data binding will not be able >>to >> > > >detect assignments to 'stockSymbol'. >> > > >Warning:(123, 63) [DataBindingTest]: Data binding will not be able >>to >> > > >detect assignments to 'MyModel'. >> > > >Warning:(123, 89) [DataBindingTest]: Data binding will not be able >>to >> > > >detect assignments to 'responseText'. >> > > >Warning:(131, 50) [DataBindingTest]: Data binding will not be able >>to >> > > >detect assignments to 'MyModel'. >> > > >Warning:(131, 76) [DataBindingTest]: Data binding will not be able >>to >> > > >detect assignments to 'strings'. >> > > >Warning:(143, 30) [DataBindingTest]: Data binding will not be able >>to >> > > >detect assignments to 'MyModel'. >> > > >Warning:(143, 56) [DataBindingTest]: Data binding will not be able >>to >> > > >detect assignments to 'allData'. >> > > >>>U:\sources\flexJsProjects\DataBindingTest\src\controllers\MyController.a >>>s >> > > >Warning:(26, 11) [DataBindingTest]: Definition models.MyModel >>could not >> > > >be found. >> > > >Error:(61, 3) [DataBindingTest]: Call to a possibly undefined >>method >> > > >MyModel. >> > > >Error:(66, 3) [DataBindingTest]: Call to a possibly undefined >>method >> > > >MyModel. >> > > >Error:(71, 12) [DataBindingTest]: Call to a possibly undefined >>method >> > > >MyModel. >> > > > >> > > >But if I pass directly to Mxmlc : >> > > > >> > > >>>-load-config="D:\SDKs\FlexJS\0.0.3_FP16.0_AIR16.0_en_US\frameworks\flex- >>>co >> > > >nfig.xml" >> > > >>>-output=U:\sources\flexJsProjects\DataBindingTest\bin\DataBindingTest.sw >>>f >> > > >>>-library-path+=U:/sources/flexJsProjects/DataBindingTest/libs/libTest.sw >>>c >> > > >U:\sources\flexJsProjects\DataBindingTest\src\DataBindingTest.mxml >> > > > >> > > >It builds. >> > > > >> > > >And if I ommit the flex-config.xml from the framework, it results >>in >> > > >compilation error because it can't find mxml-2009-manifest.xml >>neither >> > > >the bundle resources, actually, the locale folder in my FlexJS SDK >>is >> > > >empty, it I fill it with the locales of my Flex SDK, the >>compilation >> > > >fails because the >> > > >it can't find the components from the >> > > >>>D:\SDKs\FlexJS\0.0.3_FP16.0_AIR16.0_en_US\frameworks\themes\Spark\spark. >>>cs >> > > >s >> > > > >> > > >Frédéric THOMAS >> > > > >> > > >> From: webdoubl...@hotmail.com >> > > >> To: dev@flex.apache.org >> > > >> Subject: RE: AW: AW: AW: [FlexJS] IntelliJ Integration >> > > >> Date: Thu, 28 May 2015 08:47:26 +0100 >> > > >> >> > > >> Hi, >> > > >> >> > > >> Adding support for Comp C / JSC, I've been able to compile swc >>and js >> > > >>files from IntelliJ. >> > > >> >> > > >> In IntelliJ, I still have to add the FlexJS as a Lib to have >>things >> > > >>green though, also, despite, it passes a correct config.xml, the >>MXMLC >> > > >>compiler can't find the classe in the lib (the class is in the >>lib and >> > > >>the lib is well referenced, I tried with both include path and >>external >> > > >>and had the same result), did someone already tried this kind of >>config ? >> > > >> >> > > >> Thanks, >> > > >> Frédéric THOMAS >> > > >> >> > > >> > From: webdoubl...@hotmail.com >> > > >> > To: dev@flex.apache.org >> > > >> > Subject: RE: AW: AW: AW: [FlexJS] IntelliJ Integration >> > > >> > Date: Wed, 27 May 2015 01:12:22 +0100 >> > > >> > >> > > >> > > If you modify the Configuration class in flex-oem-compiler >>does it >> > > >>get >> > > >> > > used or does IJ have its own version? If you can use a >>modified >> > > >> > > Configuration, you might be able to change >>getCompilerConfiguration >> > > >>to >> > > >> > > call OEMUtil, or maybe some earlier call can call OEMUtil >>and store >> > > >>the >> > > >> > > config someplace. >> > > >> > >> > > >> > Yeah, I was thinking to stub most of the legacy config and >>still make >> > > >>IJ happy. >> > > >> > >> > > >> > > Just so I understand: does this mean the FlexJS SDK can do >>these >> > > >>things in >> > > >> > > IJ without overlaying a regular Flex SDK or being a library >>within a >> > > >> > > regular Flex SDK? >> > > >> > >> > > >> > For some reasons I didn't get yet (didn't dug into either, we >>still >> > > >>need to add the FlexJS Lib + FlexJS SDK >> > > >> > >> > > >> > Frédéric THOMAS >> > > >> > >> > > >> > > From: aha...@adobe.com >> > > >> > > To: dev@flex.apache.org >> > > >> > > Subject: Re: AW: AW: AW: [FlexJS] IntelliJ Integration >> > > >> > > Date: Tue, 26 May 2015 23:58:16 +0000 >> > > >> > > >> > > >> > > >> > > >> > > >> > > >> > > On 5/26/15, 4:41 PM, "Frédéric THOMAS" >><webdoubl...@hotmail.com> >> > > >>wrote: >> > > >> > > >> > > >> > > >> I may not be understanding the issue, but if you look at >> > > >> > > >> flex2/tools/oem/internal/OEMUtil.java I believe there is >>code in >> > > >>there >> > > >> > > >> that calls Falcon’s MXMLC to get Falcon’s config, then >>populates >> > > >> > > >> CompilerConfiguration from the Falcon config. >> > > >> > > > >> > > >> > > >IJ calls the proccessConfiguration which returns a legacy >> > > >>Configuration >> > > >> > > >nd from there IJ getCompilerConfiguration(), so, IFAIK, I >>can't use >> > > >> > > >OEMUtil to give it directly. >> > > >> > > >> > > >> > > If you modify the Configuration class in flex-oem-compiler >>does it >> > > >>get >> > > >> > > used or does IJ have its own version? If you can use a >>modified >> > > >> > > Configuration, you might be able to change >>getCompilerConfiguration >> > > >>to >> > > >> > > call OEMUtil, or maybe some earlier call can call OEMUtil >>and store >> > > >>the >> > > >> > > config someplace. >> > > >> > > >> > > >> > > > >> > > >> > > >Anyway, good news, I can now make / build / compile from >>IntelliJ >> > > >>to .swf >> > > >> > > >/ .js >> > > >> > > >> > > >> > > Just so I understand: does this mean the FlexJS SDK can do >>these >> > > >>things in >> > > >> > > IJ without overlaying a regular Flex SDK or being a library >>within a >> > > >> > > regular Flex SDK? >> > > >> > > >> > > >> > > > >> > > >> > > >It is too late for me to try to adapt and make it build >>with Ant >> > > >>tonight >> > > >> > > >though, I'll keep you in touch. >> > > >> > > >> > > >> > > Hey, this is great progress. I’m going to be a while on the >>FDB for >> > > >> > > Falcon so no hurry. >> > > >> > > >> > > >> > > -Alex >> > > >> > > >> > > >> > >> > > >> >> > > > >> > > >> > >> >