RE: [flexcoders] Click Lite: The right click now. But not now?

2008-04-16 Thread Alex Harui
In MXML, click=Foo(2) really generates the following code: private function btnFoo_clickHandler(event:MouseEvent):void { Foo(2); } btnFoo.addEventListener(MouseEvent.CLICK, btnFoo_clickHandler); What you tried to do in AS was set the listener to be the result of a call to

RE: [flexcoders] Click Lite: The right click now. But not now?

2008-04-16 Thread Gordon Smith
It works in MXML and not in AS3 because these are different languages with different rules... one is declarative and one is procedural. You obviously find the MXML syntax convenient... and that's why we support it! But in a procedural language like AS3, when you pass Foo(2) as a method