Skip to content

Latest commit

 

History

History
117 lines (66 loc) · 2.89 KB

event.md

File metadata and controls

117 lines (66 loc) · 2.89 KB

See html formatted version

event namespace

google.maps.event namespace

Static Methods

undefined

addDomListener(instance, eventName, handler[, capture])

Parameters: 

  • instance:  Object
  • eventName:  string
  • handler:  Function
  • capture:  boolean optional

Return Value:  MapsEventListener

Cross browser event handler registration. This listener is removed by calling removeListener(handle) for the handle that is returned by this function.

undefined

addDomListenerOnce(instance, eventName, handler[, capture])

Parameters: 

  • instance:  Object
  • eventName:  string
  • handler:  Function
  • capture:  boolean optional

Return Value:  MapsEventListener

Wrapper around addDomListener that removes the listener after the first event.

undefined

addListener(instance, eventName, handler)

Parameters: 

  • instance:  Object
  • eventName:  string
  • handler:  Function

Return Value:  MapsEventListener

Adds the given listener function to the given event name for the given object instance. Returns an identifier for this listener that can be used with removeListener().

undefined

addListenerOnce(instance, eventName, handler)

Parameters: 

  • instance:  Object
  • eventName:  string
  • handler:  Function

Return Value:  MapsEventListener

Like addListener, but the handler removes itself after handling the first event.

undefined

clearInstanceListeners(instance)

Parameters: 

  • instance:  Object

Return Value:  None

Removes all listeners for all events for the given instance.

undefined

clearListeners(instance, eventName)

Parameters: 

  • instance:  Object
  • eventName:  string

Return Value:  None

Removes all listeners for the given event for the given instance.

undefined

removeListener(listener)

Parameters: 

Return Value:  None

Removes the given listener, which should have been returned by addListener above. Equivalent to calling listener.remove().

undefined

trigger(instance, eventName, eventArgs)

Parameters: 

  • instance:  Object
  • eventName:  string
  • eventArgs:  ...*

Return Value:  None

Triggers the given event. All arguments after eventName are passed as arguments to the listeners.