The goog.events.Listener Class

goog.events.Listener()

Simple class that stores information about a listener

.ENABLE_MONITORING

.callOnce {boolean}

Whether to remove the listener after it has been called.

.capture {boolean}

Whether the listener is being called in the capture or bubble phase

.creationStack {string}

If monitoring the goog.events.Listener instances is enabled, stores the creation stack trace of the Disposable instance.

.handleEvent(eventObject)

Calls the internal listener

eventObject {Object}
Event object to be passed to listener.
returns {boolean}
The result of the internal listener call.

.handler {Object|undefined}

Optional object whose context to execute the listener in

.init(listener, proxy, src, type, capture, opt_handler)

Initializes the listener.

listener {Function|Object}
Callback function, or an object with a handleEvent function.
proxy {Function}
Wrapper for the listener that patches the event.
src {Object}
Source object for the event.
type {string}
Event type.
capture {boolean}
Whether in capture or bubble phase.
opt_handler {Object=}
Object in whose context to execute the callback.

.key {number}

The key of the listener.

.listener {Function|Object|null}

Call back function or an object with a handleEvent function.

.proxy {Function}

Proxy for callback that passes through {@link goog.events#HandleEvent_}

.removed {boolean}

Whether the listener has been removed.

.src {Object|goog.events.EventTarget}

Object or node that callback is listening to

.type {string}

Type of event