Thanks Piotr, that make sense...I don't know the way to solve, right now...maybe a hook where we can change the way FlexJS assign listeners from MXML....
I must to leave now, hope you could find a solution or maybe Alex could know one Thanks! 2017-01-25 22:08 GMT+01:00 piotrz <piotrzarzyck...@gmail.com>: > Hi Carlos, > > You basically have input inside label and this second click is from input. > Fix for that in pure JS world would be addEventListener to input only, but > in our FlexJS world it won't work.[1] > > Inside component I'm adding listener to input - It will be called once, but > outside component click listener is being added to "label". > > Iniside component - With that listener is called once: > input.addEventListener("click", clickHandler, false); > COMPILE::JS > public function clickHandler(event:Event):void > { > selected = !selected; > } > > BUT, outside component: > <mdl:IconToggle dataMdlFor="mdlBoldIcon" click="onClickHandler(event)"> > > Listener is being added to Label. Will investigate farther. > > [1] > http://stackoverflow.com/questions/10819699/simple- > click-on-labels-makes-double-click > > Piotr > > > > ----- > Apache Flex PMC > piotrzarzyck...@gmail.com > -- > View this message in context: http://apache-flex- > development.2333347.n4.nabble.com/FlexJS-IconToggle- > duplicates-click-event-tp58696p58698.html > Sent from the Apache Flex Development mailing list archive at Nabble.com. > -- Carlos Rovira Director General M: +34 607 22 60 05 http://www.codeoscopic.com http://www.avant2.es Este mensaje se dirige exclusivamente a su destinatario y puede contener información privilegiada o confidencial. Si ha recibido este mensaje por error, le rogamos que nos lo comunique inmediatamente por esta misma vía y proceda a su destrucción. De la vigente Ley Orgánica de Protección de Datos (15/1999), le comunicamos que sus datos forman parte de un fichero cuyo responsable es CODEOSCOPIC S.A. La finalidad de dicho tratamiento es facilitar la prestación del servicio o información solicitados, teniendo usted derecho de acceso, rectificación, cancelación y oposición de sus datos dirigiéndose a nuestras oficinas c/ Paseo de la Habana 9-11, 28036, Madrid con la documentación necesaria.