EventManager interface

This interface partially defines the map control's EventManager. This definition only includes the method added by using the drawing tools. For the base definition see: https://docs.microsoft.com/javascript/api/azure-maps-control/atlas.eventmanager?view=azure-maps-typescript-latest

Methods

add("drawingchanged" | "drawingchanging" | "drawingcomplete" | "drawingstarted" | "drawingerased", DrawingManager, (e: azmaps.Shape) => void)

Adds an event to the DrawingManager

add("drawingmodechanged", DrawingManager, (e: DrawingMode) => void)

Adds an event to the DrawingManager

remove(string, DrawingManager, (e?: any) => void)

Removes an event listener from the DrawingManager

Method Details

add("drawingchanged" | "drawingchanging" | "drawingcomplete" | "drawingstarted" | "drawingerased", DrawingManager, (e: azmaps.Shape) => void)

Adds an event to the DrawingManager

function add(eventType: "drawingchanged" | "drawingchanging" | "drawingcomplete" | "drawingstarted" | "drawingerased", target: DrawingManager, callback: (e: azmaps.Shape) => void)

Parameters

eventType

"drawingchanged" | "drawingchanging" | "drawingcomplete" | "drawingstarted" | "drawingerased"

The event name.

target
DrawingManager

The DrawingManager to add the event for.

callback

(e: azmaps.Shape) => void

The event handler callback.

add("drawingmodechanged", DrawingManager, (e: DrawingMode) => void)

Adds an event to the DrawingManager

function add(eventType: "drawingmodechanged", target: DrawingManager, callback: (e: DrawingMode) => void)

Parameters

eventType

"drawingmodechanged"

The event name.

target
DrawingManager

The DrawingManager to add the event for.

callback

(e: DrawingMode) => void

The event handler callback.

remove(string, DrawingManager, (e?: any) => void)

Removes an event listener from the DrawingManager

function remove(eventType: string, target: DrawingManager, callback: (e?: any) => void)

Parameters

eventType

string

The event name.

target
DrawingManager

The DrawingManager to remove the event for.

callback

(e?: any) => void

The event handler callback.