M/control/Location~Location


import Location from 'M/control/Location';

Main constructor of the class. Creates a Location control that allows the user to locate and draw your position on the map.

new Location()

facade/js/control/Location.js, line 26

Extends

  • M.Control

Members

module:M/control/Location~Location.NAME{string}

Name to identify this control

Methods

createView(map){Promise}

facade/js/control/Location.js, line 47

This function creates the view to the specified map

Name Type Description
map M.Map

Facade map

Returns:
HTML template

equals(obj){boolean}

facade/js/control/Location.js, line 79

This function checks if an object is equals to this control

Name Type Description
obj *

Object to compare

Returns:
equals - Returns if they are equal or not

getActivationButton(element){HTMLElement}

facade/js/control/Location.js, line 65

This function returns the HTML button control.

Name Type Description
element HTMLElement

Control template

Returns:
HTML control button