Tag Archive for 'addeventlistener()'

20
Aug

Determining if an item is listening for a specific event

The following example shows how you can check whether a Flex Button control is listening for a specific event (FlexEvent.BUTTON_DOWN) by using the hasEventListener() and willTrigger() methods.

According to the Flex 3 documentation for the EventDispatcher class’s hasEventListener() method (link):

The difference between hasEventListener() and willTrigger() is that hasEventListener() examines only the object to which it belongs, whereas willTrigger() examines the entire event flow for the event specified by the type parameter.

Full code after the jump.

Continue reading ‘Determining if an item is listening for a specific event’




December 2008
M T W T F S S
« Nov    
1234567
891011121314
15161718192021
22232425262728
293031  

Badge Farm

  • Firefox 2
  • Powered by Redoable 1.2
  • Feeds burnt by Feedburner
  • Feed