Package | com.asfusion.mate.core |
Class | public class ListenerProxy |
Property | Defined by | ||
---|---|---|---|
dispatcher : IEventDispatcher
Storage for the EventDispatcher that will be used to listen and dispatch events.
| ListenerProxy | ||
registered : Boolean
Flag indicating if ListenerProxy is already listening for events
| ListenerProxy | ||
type : String
Type used to register to events in the dispatcher object.
| ListenerProxy |
Method | Defined by | ||
---|---|---|---|
ListenerProxy(dispatcher:IEventDispatcher)
| ListenerProxy | ||
addListener(type:String, typeWatcher:IEventDispatcher = null):void
addListener will register to listen to an event with the type that is passed as argument,
using capture and priority one.
| ListenerProxy | ||
removeListener(type:String):void
Removes the listener from the dispatcher.
| ListenerProxy |
Method | Defined by | ||
---|---|---|---|
globalListenerProxyHandler(event:Event):void
Similar to the listenerProxyHandler with the difference that this handler will only run if
the dispatcher is a GlobalDispatcher and the event happens in the popup display tree.
| ListenerProxy | ||
listenerProxyHandler(event:Event):void
Handler that will run every time an event is captured in our dispatcher.
| ListenerProxy | ||
typeChangeHandler(event:InjectorSettingsEvent):void
Handler that will run every time the event type changes by calling the injectorSettings.
| ListenerProxy |
dispatcher | property |
dispatcher:IEventDispatcher
[read-write]Storage for the EventDispatcher that will be used to listen and dispatch events. This property is required in the constructor of this class.
Implementation protected function get dispatcher():IEventDispatcher
protected function set dispatcher(value:IEventDispatcher):void
registered | property |
protected var registered:Boolean
Flag indicating if ListenerProxy is already listening for events
type | property |
protected var type:String
Type used to register to events in the dispatcher object.
ListenerProxy | () | constructor |
public function ListenerProxy(dispatcher:IEventDispatcher)
Parameters
dispatcher:IEventDispatcher |
addListener | () | method |
public function addListener(type:String, typeWatcher:IEventDispatcher = null):void
addListener will register to listen to an event with the type that is passed as argument, using capture and priority one. If the dispatcher is a GlobalDispatcher, we also register to listen events in the popup DiplayObject tree.
Parameterstype:String |
|
typeWatcher:IEventDispatcher (default = null )
|
globalListenerProxyHandler | () | method |
protected function globalListenerProxyHandler(event:Event):void
Similar to the listenerProxyHandler with the difference that this handler will only run if the dispatcher is a GlobalDispatcher and the event happens in the popup display tree.
Parametersevent:Event |
listenerProxyHandler | () | method |
protected function listenerProxyHandler(event:Event):void
Handler that will run every time an event is captured in our dispatcher. This handler will create a new InjectorEvent and will dispatch it from the dispatcher. That will make all the Injectors that are registered to listen for that class type run.
Parametersevent:Event |
removeListener | () | method |
public function removeListener(type:String):void
Removes the listener from the dispatcher.
Parameterstype:String |
typeChangeHandler | () | method |
protected function typeChangeHandler(event:InjectorSettingsEvent):void
Handler that will run every time the event type changes by calling the injectorSettings.
Parametersevent:InjectorSettingsEvent |