The CairngormEventDispatcher class is a singleton class, used by the application developer to broadcast events that correspond to user gestures and requests.

The singleton implementation of the CairngormEventDispatcher ensures that one and only one class can be responsible for broadcasting events that the FrontController is subscribed to listen and react to.

Since the CairngormEventDispatcher implements singleton access, use of the singleton is simple to distribute throughout your application. At any point in your application, should you capture a user gesture (such as in a click handler, or a dragComplete handler, etc) then simply use a code idiom as follows:

// LoginEvent inherits from com.adobe.cairngorm.control.CairngormEvent
var eventObject = new LoginEvent();
eventObject.username = username.text;
eventObject.password = username.password;


See also:

Static methods


Returns the single instance of the dispatcher


Releases the current instance so that the next call to getInstance() returns a new instance.


@:value({ target : null })new(?target:IEventDispatcher)



@:value({ useWeakReference : false, priority : 0, useCapture : false })addEventListener<T>(type:EventType<T>, listener:T ‑> Void, useCapture:Bool = false, priority:Int = 0, useWeakReference:Bool = false):Void

Adds an event listener.


Dispatches a cairngorm event.


Returns whether an event listener exists.

@:value({ useCapture : false })removeEventListener<T>(type:EventType<T>, listener:T ‑> Void, useCapture:Bool = false):Void

Removes an event listener.


Returns whether an event will trigger.