tinymce.util.Dispatcher

This class is used to dispatch event to observers/listeners. All internal events inside TinyMCE uses this class.

Examples

// Creates a custom event
this.onSomething = new tinymce.util.Dispatcher(this);

// Dispatch/fire the event
this.onSomething.dispatch('some string');

Methods

Method Defined By
Constructs a new event dispatcher object.
tinymce.util.Dispatcher
Add an observer function to be executed when a dispatch call is done.
tinymce.util.Dispatcher
Add an observer function to be executed to the top of the list of observers.
tinymce.util.Dispatcher
Removes an observer function.
tinymce.util.Dispatcher
Dispatches an event to all observers/listeners.
tinymce.util.Dispatcher