Re: [FlexJS] more on undefined / non initialised values

2017-06-09 Thread justin
Hi,

I think we may be talking cross purposes here to be clear - IMO this is not an 
optimisation issue this it’s a serious bug.

Justin

Re: [FlexJS] more on undefined / non initialised values

2017-06-09 Thread Justin Mclean
HI,

> The general principle is optimization.  Optimization looks for specific
> patterns.  What you wrote below is not one of the patterns.

Not one of what patterns?

BTW Initialising the Boolean to false also optimises the seed by a factor of 
two. i.e. twice as fast.

> Would be fun to see how often that pattern exists though. 

From a quick glance  (not testing)it exists in serval places in the existing 
SDK.

Thanks,
Justin

Re: [2/4] git commit: [flex-asjs] [refs/heads/develop] - LayoutBase Fix for strand set to null in remove bead, plus performance improvements in js

2017-06-09 Thread Alex Harui
Yes, thanks for removing unnecessary coercions.

While debugging examples, I also noted the removal of Layout in Panel.
Makes me wonder if we our container architecture/lifecycle is designed
properly.  The base classes may need to have a pattern for "proxies" and
"wrappers", which may be the essence of what Panels and Scrolling
Containers do (along with exposing instead of hiding the
addElement/removeElement APIs).

Looking at the code for bead removal, it seems so heavy it makes you want
to avoid it all together.  For the password input bead, for example, we
know there can be a version of the bead with a flag to enable/disable the
password characters.  How heavy is that implementation vs the one that
requires removal?  For Panel, maybe the lifecycle should just not assume
that the Container has a layout bead so there isn't one to replace.

Food for thought,
-Alex

On 6/9/17, 4:00 PM, "Greg Dove"  wrote:

>I happened to be testing against FlexJSStore at the time I discovered the
>need for this, and there is some removing going on.
>
>I think I improved performance compared to how it was originally by
>removing coercion in js and using local references for some of the repeat
>listener references/avoiding repeat closure lookups on js, so it is
>probably 'less' PAYG than it was before, with more safety, but I get the
>point.
>
>I'm not sure about injection, but I will come back to this and add a
>removable layout subclass for the FlexJSStore demo (not sure if the
>PanelView or whatever seems to be doing this is also used in other
>examples, I have not checked).
>
>
>
>
>On Sat, Jun 10, 2017 at 10:45 AM, Alex Harui  wrote:
>
>> I guess I don't believe that removing beads is so common that every app
>> needs to carry this code around.  I wonder if there is a way to inject
>> removability as needed.
>>
>> Having a RemovableXXXLayout could override the strand setter and remove
>> listeners if the handlers are protected.
>>
>> Thoughts?
>> -Alex
>>
>> On 6/8/17, 3:22 PM, "gregd...@apache.org"  wrote:
>>
>> >LayoutBase Fix for strand set to null in remove bead, plus performance
>> >improvements in js
>> >
>> >
>> >Project:
>> >https://na01.safelinks.protection.outlook.com/?url=
>> http%3A%2F%2Fgit-wip-us
>> >.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Frepo&data=02%
>> 7C01%7C%7Cb863f5cff77
>> >e41e305b708d4aebcd62e%7Cfa7b1b5a7b34438794aed2c178de
>> cee1%7C0%7C0%7C6363255
>> >73442866659&sdata=NsSQs6LJBQaYIJ36tZ%2FgMmMyuffAlo7pAuwtopOok2g%3D&
>> reserve
>> >d=0
>> >Commit:
>> >https://na01.safelinks.protection.outlook.com/?url=
>> http%3A%2F%2Fgit-wip-us
>> >.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Fcommit%
>> 2F08af60c7&data=02%7C01%7C%
>> >7Cb863f5cff77e41e305b708d4aebcd62e%7Cfa7b1b5a7b34438794aed2c178de
>> cee1%7C0%
>> >7C0%7C636325573442866659&sdata=a8HJuqkEEii03BRyFH6lMcvkLFirlc
>> lo6HwG%2F6w4J
>> >kA%3D&reserved=0
>> >Tree:
>> >https://na01.safelinks.protection.outlook.com/?url=
>> http%3A%2F%2Fgit-wip-us
>> >.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Ftree%2F08af60c7&
>> data=02%7C01%7C%7C
>> >b863f5cff77e41e305b708d4aebcd62e%7Cfa7b1b5a7b34438794aed2c178de
>> cee1%7C0%7C
>> >0%7C636325573442866659&sdata=CcHeFSf6IMQ75kKXSE%
>> 2BWY23J7VrbJauoxO1TvG%2BHS
>> >Yk%3D&reserved=0
>> >Diff:
>> >https://na01.safelinks.protection.outlook.com/?url=
>> http%3A%2F%2Fgit-wip-us
>> >.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Fdiff%2F08af60c7&
>> data=02%7C01%7C%7C
>> >b863f5cff77e41e305b708d4aebcd62e%7Cfa7b1b5a7b34438794aed2c178de
>> cee1%7C0%7C
>> >0%7C636325573442866659&sdata=E%2B6iEUFqZB3%2BO15%
>> 2BK3sHlnaiuIkWgm8DvWVcmUm
>> >nnIk%3D&reserved=0
>> >
>> >Branch: refs/heads/develop
>> >Commit: 08af60c7755a9c7dd64ab62cbfff97443841bda7
>> >Parents: b0f7013
>> >Author: greg-dove 
>> >Authored: Fri Jun 9 10:07:20 2017 +1200
>> >Committer: greg-dove 
>> >Committed: Fri Jun 9 10:17:54 2017 +1200
>> >
>> >--
>> > .../flex/org/apache/flex/core/LayoutBase.as | 40
>> +++-
>> > 1 file changed, 30 insertions(+), 10 deletions(-)
>> >--
>> >
>> >
>> >https://na01.safelinks.protection.outlook.com/?url=
>> http%3A%2F%2Fgit-wip-us
>> >.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Fblob%2F08af60c7%
>> 2Fframeworks%2Fpro
>> >jects%2FBasic%2Fsrc%2Fmain%2Fflex%2Forg%2Fapache%2Fflex%
>> 2Fcore%2FLayoutBas
>> >e.as&data=02%7C01%7C%7Cb863f5cff77e41e305b708d4aebc
>> d62e%7Cfa7b1b5a7b344387
>> >94aed2c178decee1%7C0%7C0%7C636325573442866659&sdata=
>> fnKUKGhxZfwPRFkiMwfiri
>> >aNYV21HE8X7463sLtyYOo%3D&reserved=0
>> >--
>> >diff --git
>> >a/frameworks/projects/Basic/src/main/flex/org/apache/flex/
>> core/LayoutBase.
>> >as
>> >b/frameworks/projects/Basic/src/main/flex/org/apache/flex/
>> core/LayoutBase.
>> >as
>> >index adadc75..be7d642 100644
>> >---
>> >a/frameworks/projects/Basic/src/main/flex/org/apache/flex/
>> core/LayoutBase.
>> >as
>> >+++

Re: [FlexJS] more on undefined / non initialised values

2017-06-09 Thread Alex Harui
The general principle is optimization.  Optimization looks for specific
patterns.  What you wrote below is not one of the patterns.  Would be fun
to see how often that pattern exists though.  IMO, it would not make sense
to initialize every boolean because 1% of the boolean expressions require
optimization if alternative patterns exist that allow for smaller code.

But again, we don't have to agree, just provide compiler options.

-Alex


On 6/8/17, 3:17 PM, "Justin Mclean"  wrote:

>Hi,
>
>Also how wold you fix this?
>
>if (someBoolean == (complex expression that equals false))
>
>Thanks,
>Justin



Re: [FlexJS] more on undefined / non initialised values

2017-06-09 Thread justin
Hi,

And this particular rabbit hole goes a lot deeper.

Any guesses what these two expression give?
false && undefined
undefined && false

If you expect them to have the same answer you would be incorrect. 

Does this matter? Well try this code on both platforms:

var a:Boolean;
var b:Boolean = false;
var c:Boolean = false;

if ((a && b) != c) {
trace("True");
}
else {
trace(“False);
}

You’ll get “False” in the flash player and “True” in JS.

And again this is a simple example the RHS would be a much more complex 
expression that equates to false and you’ll still have this bug.

Thanks,
Justin

Re: [DISCUSS] Discuss Release Apache FlexJS 0.8.0 RC1

2017-06-09 Thread OmPrakash Muppirala
Please note that I will be traveling for the next few days.  In any case I
will be waiting for the artifacts to be propagated through the mirrors
before pushing a FlexJS npm release.

Hopefully the timelines will coincide.  Worst case, there will be a bit of
a lag for the npm release.

Thanks,
Om

On Jun 9, 2017 3:01 PM, "Alex Harui"  wrote:

> This is the discussion thread.
>
> Thanks,
> Alex Harui
>
>


Re: [FlexJS] more on undefined / non initialised values

2017-06-09 Thread Justin Mclean
Hi,

> If a variable is of type Boolean in AS (not JS), is there a
> difference between these three patterns.

No as a boolean can only have the values of true and false and defaults to 
false in AS.

If you take the same code and run it in the browser it can now have three 
values, true, false and undefined and it defaults to undefined.

Currently this is cause bugs as undefined != false in JS.

For example this program with incorrectly get "B is true” in the browser and “B 
is false” in the flash player.


http://ns.adobe.com/mxml/2009";
   xmlns:js="library://ns.apache.org/flexjs/basic" 
applicationComplete="init()">

   
   
   

   

   
   
   
   



It is however a simple example and the same issue will also occur in any case 
where you end up comparing a freshly defined boolean (i.e. undefined) with an 
expression that evaluates to false so just converting (b == false) to (!b) 
would not be enough to solve the issue.

Thanks,
Justin

Re: [FlexJS] more on undefined / non initialised values

2017-06-09 Thread Josh Tynjala
I suspect that the if(b == true) and if(b == false) patterns aren't out of
the ordinary in real-world code. I hope the default will be to initialize
Booleans to false and that you'll need to opt into the other behavior.

- Josh

On Fri, Jun 9, 2017 at 3:38 PM, Alex Harui  wrote:

> Thanks for pointing it was == and not ===, but I must still be missing
> something.  If a variable is of type Boolean in AS (not JS), is there a
> difference between these three patterns:
>
> If (b)
> If (b == true)
> If (b === true)
>
> Or these three?
>
> If (!b)
> If (b == false)
> If (b === false)
>
> I don't think there is, and so for me, I would rather not have the output
> JS initialize b to false and would rather have the compiler catch were I
> wrote anything other than (b) or (!b).  I'd happily replace them and save
> code.
>
> But again, I don't think we have to agree.  The compiler can be taught to
> respond to options to initialize everything as well detect unnecessary
> code.
>
> Thanks,
> -Alex
>
> On 6/8/17, 3:40 PM, "Justin Mclean"  wrote:
>
> >HI,
> >
> >> Oh. One sec. I actually just tried it in JS and I see that undefined !=
> >>false. That’s weird.
> >
> >Yep that’s the issue.
> >
> >Thanks,
> >Justin
>
>


Re: [2/4] git commit: [flex-asjs] [refs/heads/develop] - LayoutBase Fix for strand set to null in remove bead, plus performance improvements in js

2017-06-09 Thread Greg Dove
I happened to be testing against FlexJSStore at the time I discovered the
need for this, and there is some removing going on.

I think I improved performance compared to how it was originally by
removing coercion in js and using local references for some of the repeat
listener references/avoiding repeat closure lookups on js, so it is
probably 'less' PAYG than it was before, with more safety, but I get the
point.

I'm not sure about injection, but I will come back to this and add a
removable layout subclass for the FlexJSStore demo (not sure if the
PanelView or whatever seems to be doing this is also used in other
examples, I have not checked).




On Sat, Jun 10, 2017 at 10:45 AM, Alex Harui  wrote:

> I guess I don't believe that removing beads is so common that every app
> needs to carry this code around.  I wonder if there is a way to inject
> removability as needed.
>
> Having a RemovableXXXLayout could override the strand setter and remove
> listeners if the handlers are protected.
>
> Thoughts?
> -Alex
>
> On 6/8/17, 3:22 PM, "gregd...@apache.org"  wrote:
>
> >LayoutBase Fix for strand set to null in remove bead, plus performance
> >improvements in js
> >
> >
> >Project:
> >https://na01.safelinks.protection.outlook.com/?url=
> http%3A%2F%2Fgit-wip-us
> >.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Frepo&data=02%
> 7C01%7C%7Cb863f5cff77
> >e41e305b708d4aebcd62e%7Cfa7b1b5a7b34438794aed2c178de
> cee1%7C0%7C0%7C6363255
> >73442866659&sdata=NsSQs6LJBQaYIJ36tZ%2FgMmMyuffAlo7pAuwtopOok2g%3D&
> reserve
> >d=0
> >Commit:
> >https://na01.safelinks.protection.outlook.com/?url=
> http%3A%2F%2Fgit-wip-us
> >.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Fcommit%
> 2F08af60c7&data=02%7C01%7C%
> >7Cb863f5cff77e41e305b708d4aebcd62e%7Cfa7b1b5a7b34438794aed2c178de
> cee1%7C0%
> >7C0%7C636325573442866659&sdata=a8HJuqkEEii03BRyFH6lMcvkLFirlc
> lo6HwG%2F6w4J
> >kA%3D&reserved=0
> >Tree:
> >https://na01.safelinks.protection.outlook.com/?url=
> http%3A%2F%2Fgit-wip-us
> >.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Ftree%2F08af60c7&
> data=02%7C01%7C%7C
> >b863f5cff77e41e305b708d4aebcd62e%7Cfa7b1b5a7b34438794aed2c178de
> cee1%7C0%7C
> >0%7C636325573442866659&sdata=CcHeFSf6IMQ75kKXSE%
> 2BWY23J7VrbJauoxO1TvG%2BHS
> >Yk%3D&reserved=0
> >Diff:
> >https://na01.safelinks.protection.outlook.com/?url=
> http%3A%2F%2Fgit-wip-us
> >.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Fdiff%2F08af60c7&
> data=02%7C01%7C%7C
> >b863f5cff77e41e305b708d4aebcd62e%7Cfa7b1b5a7b34438794aed2c178de
> cee1%7C0%7C
> >0%7C636325573442866659&sdata=E%2B6iEUFqZB3%2BO15%
> 2BK3sHlnaiuIkWgm8DvWVcmUm
> >nnIk%3D&reserved=0
> >
> >Branch: refs/heads/develop
> >Commit: 08af60c7755a9c7dd64ab62cbfff97443841bda7
> >Parents: b0f7013
> >Author: greg-dove 
> >Authored: Fri Jun 9 10:07:20 2017 +1200
> >Committer: greg-dove 
> >Committed: Fri Jun 9 10:17:54 2017 +1200
> >
> >--
> > .../flex/org/apache/flex/core/LayoutBase.as | 40
> +++-
> > 1 file changed, 30 insertions(+), 10 deletions(-)
> >--
> >
> >
> >https://na01.safelinks.protection.outlook.com/?url=
> http%3A%2F%2Fgit-wip-us
> >.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Fblob%2F08af60c7%
> 2Fframeworks%2Fpro
> >jects%2FBasic%2Fsrc%2Fmain%2Fflex%2Forg%2Fapache%2Fflex%
> 2Fcore%2FLayoutBas
> >e.as&data=02%7C01%7C%7Cb863f5cff77e41e305b708d4aebc
> d62e%7Cfa7b1b5a7b344387
> >94aed2c178decee1%7C0%7C0%7C636325573442866659&sdata=
> fnKUKGhxZfwPRFkiMwfiri
> >aNYV21HE8X7463sLtyYOo%3D&reserved=0
> >--
> >diff --git
> >a/frameworks/projects/Basic/src/main/flex/org/apache/flex/
> core/LayoutBase.
> >as
> >b/frameworks/projects/Basic/src/main/flex/org/apache/flex/
> core/LayoutBase.
> >as
> >index adadc75..be7d642 100644
> >---
> >a/frameworks/projects/Basic/src/main/flex/org/apache/flex/
> core/LayoutBase.
> >as
> >+++
> >b/frameworks/projects/Basic/src/main/flex/org/apache/flex/
> core/LayoutBase.
> >as
> >@@ -76,19 +76,39 @@ package org.apache.flex.core
> >  *  @productversion FlexJS 0.8
> >*
> >* @flexjsignorecoercion org.apache.flex.core.ILayoutChild
> >+   * @flexjsignorecoercion org.apache.flex.events.
> IEventDispatcher
> >  */
> >   public function set strand(value:IStrand):void
> >   {
> >-host = value as ILayoutChild;
> >-
> >-  IEventDispatcher(host).addEventListener("
> widthChanged",
> >handleSizeChange);
> >-  IEventDispatcher(host).addEventListener("
> heightChanged",
> >handleSizeChange);
> >-  IEventDispatcher(host).
> addEventListener("sizeChanged",
> >handleSizeChange);
> >-
> >-  IEventDispatcher(host).addEventListener("
> childrenAdded",
> >handleChildrenAdded);
> >-  IEventDispatcher(host).addEventListener("
> initCompl

Re: [2/4] git commit: [flex-asjs] [refs/heads/develop] - LayoutBase Fix for strand set to null in remove bead, plus performance improvements in js

2017-06-09 Thread Alex Harui
I guess I don't believe that removing beads is so common that every app
needs to carry this code around.  I wonder if there is a way to inject
removability as needed.

Having a RemovableXXXLayout could override the strand setter and remove
listeners if the handlers are protected.

Thoughts?
-Alex

On 6/8/17, 3:22 PM, "gregd...@apache.org"  wrote:

>LayoutBase Fix for strand set to null in remove bead, plus performance
>improvements in js
>
>
>Project: 
>https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fgit-wip-us
>.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Frepo&data=02%7C01%7C%7Cb863f5cff77
>e41e305b708d4aebcd62e%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C6363255
>73442866659&sdata=NsSQs6LJBQaYIJ36tZ%2FgMmMyuffAlo7pAuwtopOok2g%3D&reserve
>d=0
>Commit: 
>https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fgit-wip-us
>.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Fcommit%2F08af60c7&data=02%7C01%7C%
>7Cb863f5cff77e41e305b708d4aebcd62e%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%
>7C0%7C636325573442866659&sdata=a8HJuqkEEii03BRyFH6lMcvkLFirlclo6HwG%2F6w4J
>kA%3D&reserved=0
>Tree: 
>https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fgit-wip-us
>.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Ftree%2F08af60c7&data=02%7C01%7C%7C
>b863f5cff77e41e305b708d4aebcd62e%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C
>0%7C636325573442866659&sdata=CcHeFSf6IMQ75kKXSE%2BWY23J7VrbJauoxO1TvG%2BHS
>Yk%3D&reserved=0
>Diff: 
>https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fgit-wip-us
>.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Fdiff%2F08af60c7&data=02%7C01%7C%7C
>b863f5cff77e41e305b708d4aebcd62e%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C
>0%7C636325573442866659&sdata=E%2B6iEUFqZB3%2BO15%2BK3sHlnaiuIkWgm8DvWVcmUm
>nnIk%3D&reserved=0
>
>Branch: refs/heads/develop
>Commit: 08af60c7755a9c7dd64ab62cbfff97443841bda7
>Parents: b0f7013
>Author: greg-dove 
>Authored: Fri Jun 9 10:07:20 2017 +1200
>Committer: greg-dove 
>Committed: Fri Jun 9 10:17:54 2017 +1200
>
>--
> .../flex/org/apache/flex/core/LayoutBase.as | 40 +++-
> 1 file changed, 30 insertions(+), 10 deletions(-)
>--
>
>
>https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fgit-wip-us
>.apache.org%2Frepos%2Fasf%2Fflex-asjs%2Fblob%2F08af60c7%2Fframeworks%2Fpro
>jects%2FBasic%2Fsrc%2Fmain%2Fflex%2Forg%2Fapache%2Fflex%2Fcore%2FLayoutBas
>e.as&data=02%7C01%7C%7Cb863f5cff77e41e305b708d4aebcd62e%7Cfa7b1b5a7b344387
>94aed2c178decee1%7C0%7C0%7C636325573442866659&sdata=fnKUKGhxZfwPRFkiMwfiri
>aNYV21HE8X7463sLtyYOo%3D&reserved=0
>--
>diff --git 
>a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.
>as 
>b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.
>as
>index adadc75..be7d642 100644
>--- 
>a/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.
>as
>+++ 
>b/frameworks/projects/Basic/src/main/flex/org/apache/flex/core/LayoutBase.
>as
>@@ -76,19 +76,39 @@ package org.apache.flex.core
>  *  @productversion FlexJS 0.8
>* 
>* @flexjsignorecoercion org.apache.flex.core.ILayoutChild
>+   * @flexjsignorecoercion org.apache.flex.events.IEventDispatcher
>  */
>   public function set strand(value:IStrand):void
>   {
>-host = value as ILayoutChild;
>-  
>-  IEventDispatcher(host).addEventListener("widthChanged",
>handleSizeChange);
>-  IEventDispatcher(host).addEventListener("heightChanged",
>handleSizeChange);
>-  IEventDispatcher(host).addEventListener("sizeChanged",
>handleSizeChange);
>-  
>-  IEventDispatcher(host).addEventListener("childrenAdded",
>handleChildrenAdded);
>-  IEventDispatcher(host).addEventListener("initComplete",
>handleInitComplete);
>-  
>-  IEventDispatcher(host).addEventListener("layoutNeeded",
>handleLayoutNeeded);
>+  var newHost:ILayoutChild = value as ILayoutChild;
>+  var oldHost:ILayoutChild = host;
>+  if (newHost != oldHost) {
>+  var sizeChange:Function = handleSizeChange;
>+var childrenAdded:Function =handleChildrenAdded;
>+  var initComplete:Function = handleInitComplete;
>+  var layoutNeeded:Function = handleLayoutNeeded;
>+if (oldHost) {
>+ 
>IEventDispatcher(oldHost).removeEventListener("widthChanged", sizeChange);
>+ 
>IEventDispatcher(oldHost).removeEventListener("heightChanged",
>sizeChange);
>+ 
>IEventDispatcher(oldHost).removeEventListener("siz

Re: [FlexJS] more on undefined / non initialised values

2017-06-09 Thread Alex Harui
Thanks for pointing it was == and not ===, but I must still be missing
something.  If a variable is of type Boolean in AS (not JS), is there a
difference between these three patterns:

If (b)
If (b == true)
If (b === true)

Or these three?

If (!b)
If (b == false)
If (b === false)

I don't think there is, and so for me, I would rather not have the output
JS initialize b to false and would rather have the compiler catch were I
wrote anything other than (b) or (!b).  I'd happily replace them and save
code.

But again, I don't think we have to agree.  The compiler can be taught to
respond to options to initialize everything as well detect unnecessary
code.

Thanks,
-Alex

On 6/8/17, 3:40 PM, "Justin Mclean"  wrote:

>HI,
>
>> Oh. One sec. I actually just tried it in JS and I see that undefined !=
>>false. That’s weird.
>
>Yep that’s the issue.
>
>Thanks,
>Justin



[DISCUSS] Discuss Release Apache FlexJS 0.8.0 RC1

2017-06-09 Thread Alex Harui
This is the discussion thread.

Thanks,
Alex Harui



[VOTE] Release Apache FlexJS 0.8.0 RC1

2017-06-09 Thread Alex Harui
Hi,

This is vote for the 0.8.0 release of Apache FlexJS.

The release candidate can be found here;
https://dist.apache.org/repos/dist/dev/flex/flexjs/0.8.0/rc1/

Before voting please review the section,'What are the ASF requirements on
approving a release?', at:
http://www.apache.org/dev/release.html#approving-a-release

At a minimum you would be expected to check that:
- MD5 and signed packages are correct
- README, RELEASE_NOTES, NOTICE and LICENSE files are all fine
- That the build script completes successfully
- That you can compile and cross-compile a simple example using the SDK.

The source package is set up the same way as the repo.  This means that
the results of the build are not the same as an IDE-compatible SDK.  The
compiled source package can be used in combination with the FalconJX
source package to compile some of the sample applications.

The most convenient way to use the binary package is to install it via Ant
or the Installer.  To use an Installer you must use InstallApacheFlex
version 3.1 or later.  You can get InstallApacheFlex here:
http://www.apache.org/dyn/closer.cgi?path=/flex/installer/3.1/binaries/

Please vote to approve this release:
+1 Approve the release
-1 Veto the release (please provide specific comments to why)

This vote will be open for 72 hours or until a result can be called.

The vote passes if there is:
- At least 3 +1 votes from the PMC
- More positive votes than negative votes

Remember that this is a 'beta-quality' release so I expect there
will be many bugs found.  IMO the goal is not to try to find and fix bugs
in the RC, but to make sure we have the packaging right, and enough
functionality that folks will have some success trying to use it.

People who are not in PMC are also encouraged to test out the release and
vote, although their votes will not be binding, they can influence how the
PMC votes.

When voting please indicate what OS, IDE, Flash Player version and AIR
version you tested with.

For your convenience, there is an ant script that automates the common
steps to validate a release.  Instead of individually downloading the
package and signature files, unzipping, etc, you can instead:
1) create an empty folder,
2) download into that folder this file:
https://dist.apache.org/repos/dist/dev/flex/flexjs/0.8.0/rc1/ApproveFlexJS.
xml
3) run the script: ant -e -f ApproveFlexJS.xml -Drelease.version=0.8.0
-Drc=1

You are not required to use this script, and more testing of the packages
and build results are always encouraged.


Please put all discussion about this release in the DISCUSSION thread not
this VOTE thread.

Thanks,
Alex Harui



[DISCUSS] Discuss Release Apache Flex FalconJX 0.8.0 RC1

2017-06-09 Thread Alex Harui
This is the discussion thread.

Changes in this RC include:


Thanks,
Alex Harui



[VOTE] Release Apache Flex FalconJX 0.8.0 RC1

2017-06-09 Thread Alex Harui
Hi,

This is vote for the 0.8.0 release of the FalconJX (and Falcon)
compilers.  There is no separate Falcon-only release package at
this time.  The only purpose of the FalconJX packages are to serve as
upstream packages for the FlexJS release.

The release candidate can be found here;
https://dist.apache.org/repos/dist/dev/flex/falcon/0.8.0/rc1/

Before voting please review the section, 'What are the ASF requirements on
approving a release?', at:
http://www.apache.org/dev/release.html#approving-a-release

At a minimum you would be expected to check that:
- MD5 and signed packages are correct
- README, RELEASE_NOTES, NOTICE and LICENSE files are all fine
- That the build script completes successfully
- That you can compile using the results of building the source package

The source package is set up the same way as the repo.  This means that
the results of the build are not the same as the binary package.  The
compiled source package can be used to build FlexJS apps via the command
line and Ant, but not in Flash Builder or other IDEs.  You can test the
source
package by building it, then pointing to it from the source package of the
FlexJS release candidate and building the examples in the FlexJS package.

The binary package is set up as an upstream package for the FlexJS
release.  The most convenient way to use the binary package is to install
a FlexJS SDK via Ant or the Installer.

Please vote to approve this release:
+1 Approve the release
-1 Veto the release (please provide specific comments to why)

This vote will be open for 72 hours or until a result can be called.

The vote passes if there is:
- At least 3 +1 votes from the PMC
- More positive votes than negative votes

Remember that this is a 'beta-quality' release so there
will be many bugs found.  The goal is not to try to find and fix bugs
in the RC, but to make sure we have the packaging right, and enough
functionality that folks will have some success trying to use it.

People who are not in PMC are also encouraged to test out the release and
vote, although their votes will not be binding, they can influence how the
PMC votes.

When voting please indicate what OS, IDE, Flash Player version and AIR
version you tested with.

Please put all discussion about this release in the DISCUSSION thread not
this VOTE thread.

For your convenience there is an ant script that automates the common
steps to validate a release.  Instead of individually downloading the
package and signature files, unzipping, etc, you can instead:
1) create an empty folder,
2) download into that folder this file:
https://dist.apache.org/repos/dist/dev/flex/falcon/0.8.0/rc1/ApproveFalcon.
xml
3) run the script: ant -e -f ApproveFalcon.xml -Drelease.version=0.8.0
-Drc=1

You are not required to use this script, and more testing of the packages
and build results are always encouraged.

Thanks,
Alex Harui



Re: [FlexJS] Compiler options / VSCode config

2017-06-09 Thread Olaf Krueger
Josh Tynjala wrote
> Did you delete your ./target/javascript directory before compiling with
> the
> new SDK?

I'm pretty sure that I've done that all the time without any success.

After I've changed the "output" option as you mentioned the first time
including deleting the target folder it works now.
I noticed that if I pass something completely wrong to the "output" option
now (something like "output": "./\targetjavascript") the compiler is
creating a "bin" folder automatically.
This was not the case before I've changed the "output" option to whatever.
If I changed back the output option back to its origin value which was
"output": "./target/javascript" it also works.
Moreover, all your variations work for me.

So this is weird for me but it works and that's the important thing ;-)

Thank you, Josh!

Olaf





--
View this message in context: 
http://apache-flex-development.247.n4.nabble.com/FlexJS-Compiler-options-VSCode-config-tp62268p62270.html
Sent from the Apache Flex Development mailing list archive at Nabble.com.


Re: [FlexJS] Compiler options / VSCode config

2017-06-09 Thread Josh Tynjala
Did you delete your ./target/javascript directory before compiling with the
new SDK? I don't see why that would cause this problem, but it's worth a
try. Good to get in the habit when switching SDKs anyway, since some old
framework JS files might get stale.

I've seen some issues with the format of the path passed to the output
option on occasion. I think I noticed that it's more sensitive on Windows.
I've not had the time to figure out the exact patterns that fail, but you
might also try playing around with that a little. Maybe try some variations
like these?

"output": "target/javascript"
"output": ".\\target\\javascript"
"output": "target\\javascript"

- Josh

On Fri, Jun 9, 2017 at 12:45 PM, Olaf Krueger  wrote:

> Hi,
> after some weeks being technically offline at home, I'm hopefully back in
> the game now;-)
>
> I've just downloaded the nightly build using the installer and tried to
> compile my little test app
> with no success [1].
> I noticed that the target folder contains just a weird javascript file.
> I've already tried to replace the asconfig option "js-output-type":
> "flexjs"
> by "targets": ["JSFlex"] without success.
>
> Do I miss something?
>
> Thanks,
> Olaf
>
>
>
> [1]
> MXMLJSC
> +flexlib=C:\Daten\flex_sdks\flexjs_nightly_20170609\frameworks
> +configname=flex
> --debug=true
> --source-map=true
> --targets=JSFlex
> --output=./target/javascript
> src/EmployeeAdmin.mxml
> -html-template=src/resources/mdl-js-index-template.html
> -compiler.exclude-defaults-css-files=HTML.swc:defaults.css
> Compiling file:
> c:\local\workspaces\puremvc_flexjs\EmployeeAdminFlexJS2\
> target\javascript\bin\js-debug\EmployeeAdmin.js
> java.io.FileNotFoundException:
> c:\local\workspaces\puremvc_flexjs\EmployeeAdminFlexJS2\
> target\javascript\bin\js-debug\EmployeeAdmin.js
> (Das System kann den angegebenen Pfad nicht finden)
> java.io.FileOutputStream.open0(Native
> Method)java.io.FileOutputStream.open(FileOutputStream.java:270)
> java.io.FileOutputStream.(FileOutputStream.java:
> 213)java.io.FileOutputStream.(FileOutputStream.java:
> 162)org.apache.flex.compiler.clients.MXMLJSCFlex.compile(
> MXMLJSCFlex.java:367)org.apache.flex.compiler.clients.
> MXMLJSCFlex._mainNoExit(MXMLJSCFlex.java:245)org.
> apache.flex.compiler.clients.MXMLJSCFlex.mainNoExit(
> MXMLJSCFlex.java:202)org.apache.flex.compiler.clients.
> MXMLJSC._mainNoExit(MXMLJSC.java:347)org.apache.flex.
> compiler.clients.MXMLJSC.mainNoExit(MXMLJSC.java:282)
> org.apache.flex.compiler.clients.MXMLJSC.staticMainNoExit(MXMLJSC.java:
> 242)org.apache.flex.compiler.clients.MXMLJSC.main(MXMLJSC.java:224)
>
>
> 2.925021143 seconds
>
>
>
>
> --
> View this message in context: http://apache-flex-
> development.247.n4.nabble.com/FlexJS-Compiler-options-
> VSCode-config-tp62268.html
> Sent from the Apache Flex Development mailing list archive at Nabble.com.
>


[FlexJS] Compiler options / VSCode config

2017-06-09 Thread Olaf Krueger
Hi,
after some weeks being technically offline at home, I'm hopefully back in
the game now;-)

I've just downloaded the nightly build using the installer and tried to
compile my little test app
with no success [1].
I noticed that the target folder contains just a weird javascript file.
I've already tried to replace the asconfig option "js-output-type": "flexjs"
by "targets": ["JSFlex"] without success.

Do I miss something?

Thanks,
Olaf



[1]
MXMLJSC
+flexlib=C:\Daten\flex_sdks\flexjs_nightly_20170609\frameworks
+configname=flex
--debug=true
--source-map=true
--targets=JSFlex
--output=./target/javascript
src/EmployeeAdmin.mxml
-html-template=src/resources/mdl-js-index-template.html
-compiler.exclude-defaults-css-files=HTML.swc:defaults.css
Compiling file:
c:\local\workspaces\puremvc_flexjs\EmployeeAdminFlexJS2\target\javascript\bin\js-debug\EmployeeAdmin.js
java.io.FileNotFoundException:
c:\local\workspaces\puremvc_flexjs\EmployeeAdminFlexJS2\target\javascript\bin\js-debug\EmployeeAdmin.js
(Das System kann den angegebenen Pfad nicht finden)
java.io.FileOutputStream.open0(Native
Method)java.io.FileOutputStream.open(FileOutputStream.java:270)java.io.FileOutputStream.(FileOutputStream.java:213)java.io.FileOutputStream.(FileOutputStream.java:162)org.apache.flex.compiler.clients.MXMLJSCFlex.compile(MXMLJSCFlex.java:367)org.apache.flex.compiler.clients.MXMLJSCFlex._mainNoExit(MXMLJSCFlex.java:245)org.apache.flex.compiler.clients.MXMLJSCFlex.mainNoExit(MXMLJSCFlex.java:202)org.apache.flex.compiler.clients.MXMLJSC._mainNoExit(MXMLJSC.java:347)org.apache.flex.compiler.clients.MXMLJSC.mainNoExit(MXMLJSC.java:282)org.apache.flex.compiler.clients.MXMLJSC.staticMainNoExit(MXMLJSC.java:242)org.apache.flex.compiler.clients.MXMLJSC.main(MXMLJSC.java:224)


2.925021143 seconds




--
View this message in context: 
http://apache-flex-development.247.n4.nabble.com/FlexJS-Compiler-options-VSCode-config-tp62268.html
Sent from the Apache Flex Development mailing list archive at Nabble.com.


Re: [LAST CALL] Release FlexJS/FalconJX 0.8.0

2017-06-09 Thread Harbs
As long as it’s computer troubles and not family troubles… ;-)

> On Jun 9, 2017, at 5:30 PM, Alex Harui  wrote:
> 
> In case anybody is wondering, I'm having computer troubles and family
> stuff that is delaying the RC.
> 
> -Alex
> 
> On 6/8/17, 11:04 AM, "piotrz"  wrote:
> 
>> I just run Maven build [1] and it's blue, so from my point we are ready!
>> :)
>> 
>> [1]
>> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fbuilds.ap
>> ache.org%2Fview%2FE-G%2Fview%2FFlex%2Fjob%2FFlexJS%2520Pipeline%2Fjob%2Fre
>> lease0.8.0%2F&data=02%7C01%7C%7C813aa330920b4e1cbc4208d4ae9b0902%7Cfa7b1b5
>> a7b34438794aed2c178decee1%7C0%7C0%7C636325428280703335&sdata=5F8bFDfWWmUwZ
>> VZkyPRdOKCdWmHVn6seNLbKDz%2F003M%3D&reserved=0
>> 
>> Piotr
>> 
>> 
>> 
>> -
>> Apache Flex PMC
>> piotrzarzyck...@gmail.com
>> --
>> View this message in context:
>> https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-fle
>> x-development.247.n4.nabble.com%2FLAST-CALL-Release-FlexJS-FalconJX-0-
>> 8-0-tp61275p62256.html&data=02%7C01%7C%7C813aa330920b4e1cbc4208d4ae9b0902%
>> 7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636325428280703335&sdata=DKUG
>> YbuVA2YRqiYxwmra%2BaoCfACi4schZuZD2%2FsgmSA%3D&reserved=0
>> Sent from the Apache Flex Development mailing list archive at Nabble.com.
> 



Re: [LAST CALL] Release FlexJS/FalconJX 0.8.0

2017-06-09 Thread Alex Harui
In case anybody is wondering, I'm having computer troubles and family
stuff that is delaying the RC.

-Alex

On 6/8/17, 11:04 AM, "piotrz"  wrote:

>I just run Maven build [1] and it's blue, so from my point we are ready!
>:)
>
>[1]
>https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fbuilds.ap
>ache.org%2Fview%2FE-G%2Fview%2FFlex%2Fjob%2FFlexJS%2520Pipeline%2Fjob%2Fre
>lease0.8.0%2F&data=02%7C01%7C%7C813aa330920b4e1cbc4208d4ae9b0902%7Cfa7b1b5
>a7b34438794aed2c178decee1%7C0%7C0%7C636325428280703335&sdata=5F8bFDfWWmUwZ
>VZkyPRdOKCdWmHVn6seNLbKDz%2F003M%3D&reserved=0
>
>Piotr
>
>
>
>-
>Apache Flex PMC
>piotrzarzyck...@gmail.com
>--
>View this message in context:
>https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-fle
>x-development.247.n4.nabble.com%2FLAST-CALL-Release-FlexJS-FalconJX-0-
>8-0-tp61275p62256.html&data=02%7C01%7C%7C813aa330920b4e1cbc4208d4ae9b0902%
>7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636325428280703335&sdata=DKUG
>YbuVA2YRqiYxwmra%2BaoCfACi4schZuZD2%2FsgmSA%3D&reserved=0
>Sent from the Apache Flex Development mailing list archive at Nabble.com.



Re: [FlexJS] List reordering

2017-06-09 Thread Alex Harui
FlexJSStore example uses DragDrop to drag from what looks like a TileList
to a regular List, but neither are actually based on List. But there might
be code in there you can leverage.

HTH,
-Alex

On 6/9/17, 6:19 AM, "Josh Tynjala"  wrote:

>I played around with the HTML drag and drop API not too long ago. It was
>pretty intuitive and easy to work with.
>
>https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdeveloper
>.mozilla.org%2Fen-US%2Fdocs%2FWeb%2FAPI%2FHTML_Drag_and_Drop_API&data=02%7
>C01%7C%7Cd91b43a4d2a14219919308d4af3a5b41%7Cfa7b1b5a7b34438794aed2c178dece
>e1%7C0%7C0%7C636326112557338141&sdata=KouvLKvgUGHHWycH8iqc3XmvAcBSw2fl%2BZ
>Ot70tOBoA%3D&reserved=0
>
>- Josh
>
>On Thu, Jun 8, 2017 at 11:46 PM, Harbs  wrote:
>
>> Has anyone done any work on reordering items in lists (and drag/drop
>>from
>> and into lists)?
>>
>> Thanks,
>> Harbs



Re: [FlexJS] List reordering

2017-06-09 Thread Josh Tynjala
I played around with the HTML drag and drop API not too long ago. It was
pretty intuitive and easy to work with.

https://developer.mozilla.org/en-US/docs/Web/API/HTML_Drag_and_Drop_API

- Josh

On Thu, Jun 8, 2017 at 11:46 PM, Harbs  wrote:

> Has anyone done any work on reordering items in lists (and drag/drop from
> and into lists)?
>
> Thanks,
> Harbs


Re: [FlexJS] List reordering

2017-06-09 Thread Harbs
Basic.

> On Jun 9, 2017, at 9:47 AM, piotrz  wrote:
> 
> Hi Harbs,
> 
> I haven't touch subject, but one question - Do you have in mind Basic List
> or MDL List ?
> 
> Piotr
> 
> 
> 
> -
> Apache Flex PMC
> piotrzarzyck...@gmail.com
> --
> View this message in context: 
> http://apache-flex-development.247.n4.nabble.com/FlexJS-List-reordering-tp62261p62262.html
> Sent from the Apache Flex Development mailing list archive at Nabble.com.



Re: [FlexJS] List reordering

2017-06-09 Thread piotrz
Hi Harbs,

I haven't touch subject, but one question - Do you have in mind Basic List
or MDL List ?

Piotr



-
Apache Flex PMC
piotrzarzyck...@gmail.com
--
View this message in context: 
http://apache-flex-development.247.n4.nabble.com/FlexJS-List-reordering-tp62261p62262.html
Sent from the Apache Flex Development mailing list archive at Nabble.com.