JS API
- Parameters
- Options
- Example
- Methods
- fitToBoundingBox
- getBoundingBox
- getInitialBoundingBox
- getLayers
- getMouseMode
- off
- on
- once
- refresh
- reset
- setMouseMode
- usingLayer
- usingNewLayer
- Events
- Parameters
- Example
- Methods
- addFeature
- addFeatureCollection
- bringForwards
- bufferGeometry
- changeProperties
- clearFilters
- clearFeatures
- clearStyle
- clipByFeatureCollection
- convertToCentroids
- filterByBoundingBox
- filterByFeatureCollection
- filterByNearest
- filterByText
- getFeatureCollection
- hide
- sendBackwards
- show
- style
- update
- usingFeature
getMouseMode
Returns the current MouseMode of the map.
The MapMode determines the behaviour of the map based on mouse activity. Examples of this behaviour include zooming, panning and drawing on the map.
The available values are held by the Mapzania.MouseModes object and are:
- Pan (default)
- DrawPoint
- DrawLine
- DrawPolygon
Parameters
No parameters.
Example
var map = new Mapzania.Map("map-div", "WORLD");
console.log(map.getMouseMode());
//OUTPUT
1