more traditional event listener stuff
This commit is contained in:
parent
be31565c47
commit
a1f814a294
@ -1,17 +1,14 @@
|
||||
package
|
||||
{
|
||||
import mx.core.Application;
|
||||
import mx.controls.Button;
|
||||
import flash.events.MouseEvent;
|
||||
|
||||
|
||||
public class CustomApp extends Application
|
||||
{
|
||||
public var mutton:Button;
|
||||
|
||||
function CustomApp()
|
||||
{
|
||||
mutton.addEventListener(MouseEvent.CLICK, butterCup);
|
||||
}
|
||||
|
||||
public function butterCup(event:MouseEvent):void
|
||||
|
@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<me:CustomApp xmlns:mx="http://www.adobe.com/2006/mxml"
|
||||
xmlns:me="*" layout="absolute">
|
||||
<mx:Button id="mutton" label="howdy" />
|
||||
<mx:Button id="mutton" label="howdy" click="butterCup(event)" />
|
||||
</me:CustomApp>
|
||||
|
Loading…
Reference in New Issue
Block a user