Re: TextInput JS events

2014-03-08 Thread Alex Harui
But would flattening our namespaces get around package name collisions that Carlos ran into? Doing so wouldn't negatively affect Closure's output, or would it? -Alex On 3/8/14 8:54 AM, "Erik de Bruin" wrote: >The Closure compiler flattens namespaces (dot notation) for us, among many >other opt

Re: TextInput JS events

2014-03-08 Thread Erik de Bruin
The Closure compiler flattens namespaces (dot notation) for us, among many other optimisations. There is really no need to be worry about stuff like that. The GCC is really an awesome tool, you should check out it's output sometime, you'll be amazed how much optimisation it achieves if fed a prope

Re: TextInput JS events

2014-03-08 Thread Carlos Rovira
Hi Alex, I think this is right since as I see it, generated code for JS takes the role of somewhat like compiled code, regarding there's no developer use and it's final. So whatever we do to get more speed the better, id we could get speed with tricks like that we should change from dot notation t

Re: TextInput JS events

2014-03-06 Thread Alex Harui
FWIW, what subsystems or anything requires us to use dot.path expressions for packages? The original FalconJS developer mentioned to me once that we should consider having FalconJX flatten the packages (org_apache_flex_TextInput instead of org.apache.flex.TextInput) because it looks up faster in J

Re: TextInput JS events

2014-03-06 Thread Carlos Rovira
Hi Erik, finally refactored and committed the todo list sample to package "sample.todo" and change the rest to plural ("controllers", "events", and so on... in this regard I think we have a compiler bug since if I left singular, the compiler throw warnings that signals "incomplete alias" (over 17

Re: TextInput JS events

2014-03-06 Thread Erik de Bruin
If you are going to use 'org.apache.flex' for you app you run the risk of collisions with the SDK, which also uses that namespace. Also, the plural ("events") makes more sense - to me at least - as there will likely be more classes in that one package: events.firstEvent, events.secondEvent, events

Re: TextInput JS events

2014-03-06 Thread Carlos Rovira
Hi Erik, I see the point and I was thinking to introduce "org.apache.flex" to solve a similar problem I send to this list some days ago thinking that it was a bug in the compiler, but the problem is the package structure. I prefer introduce "org.apache.flex" and then maintain packages in singular

Re: TextInput JS events

2014-03-06 Thread Erik de Bruin
As a first try, I'd suggest you rename the "event" package to something less collision prone, like "events"... EdB On Thu, Mar 6, 2014 at 1:29 PM, Erik de Bruin wrote: > Carlos, > > I'm currently looking at the example application. You use 'event' as part > of the namespace. In FlexJS JS, al

Re: TextInput JS events

2014-03-06 Thread Erik de Bruin
Carlos, I'm currently looking at the example application. You use 'event' as part of the namespace. In FlexJS JS, all objects are fully qualified, so where in AS you would have "new TodoListEvent(TodoListEvent.LOG_TODO)", in JS that will become "new event.TodoListEvent(event.TodoListEvent.LOG_TODO

Re: TextInput JS events

2014-03-06 Thread Carlos Rovira
Hi Erik, thanks, I have a version locally without the need of InputHandler goog class to remove that dependency, but although I'm with you that this solution should be the right from a design perspective it's not working for me. The method is getting called due to MXMLDataInterpreter setup interna

Re: TextInput JS events

2014-03-06 Thread Erik de Bruin
Carlos, In your JS implementation I see you already set up a handler that catches "input" events and re-casts them as "change" events. This seems like a perfectly acceptable solution to this issue and much more clean and intuitive than trying to get the AS side to emit "input" instead of change, a

Re: TextInput JS events

2014-03-05 Thread Alex Harui
Hi Carlos, We don't have a strict policy on that yet. We could just call event "input" and kill the textInput event on the SWF side and dispatch it as "input". That would have backward compatibility problems for Flex users expecting "textInput", but FlexJS doesn't promise 100% compatibility. I

Re: TextInput JS events

2014-03-05 Thread Erik de Bruin
I'll try to have a look at this tomorrow. EdB On Wed, Mar 5, 2014 at 6:19 PM, Carlos Rovira wrote: > Hi, > > I'm trying to deal with events in JS and I'm finding some troubles. Maybe > you guys more experienced with google closure could help me to find the > way. > > In old Flex SDK, TextInpu

TextInput JS events

2014-03-05 Thread Carlos Rovira
Hi, I'm trying to deal with events in JS and I'm finding some troubles. Maybe you guys more experienced with google closure could help me to find the way. In old Flex SDK, TextInput change event is used to signal changes in text as user introduces. In JS input text that event is 'input', while 'c