DomEvent
Utility functions to work with the DOM events, used by Leaflet internally.
Methods
Method | Returns | Description |
---|---|---|
addListener(
|
this |
Adds a listener fn to the element's DOM event of the specified type. this keyword inside the listener will point to context , or to the element if not specified. |
removeListener(
|
this |
Removes an event listener from the element. |
stopPropagation(
|
this |
Stop the given event from propagation to parent elements. Used inside the listener functions:
|
preventDefault(
|
this |
Prevents the default action of the event from happening (such as following a link in the href of the a element, or doing a POST request with page reload when form is submitted). Use it inside listener functions.
|
stop(
|
this |
Does stopPropagation and preventDefault at the same time. |
disableClickPropagation(
|
this |
Adds stopPropagation to the element's 'click' , 'doubleclick' , 'mousedown' and 'touchstart' events. |
getMousePosition(
|
Point |
Gets normalized mouse position from a DOM event relative to the container or to the whole page if not specified. |
getWheelDelta(
|
Number |
Gets normalized wheel delta from a mousewheel DOM event. |
v0.1.1335
- L.Wrld.themes
- Event objects
- WrldPoiApi
- L.Map
- L.Marker
- L.Popup
- L.TileLayer
- L.TileLayer.WMS
- L.TileLayer.Canvas
- L.ImageOverlay
- L.Path
- L.Polyline
- L.MultiPolyline
- L.Polygon
- L.MultiPolygon
- L.Rectangle
- L.Circle
- L.CircleMarker
- L.LayerGroup
- L.FeatureGroup
- L.GeoJson
- L.LatLng
- L.LatLngBounds
- L.Point
- L.Bounds
- L.Icon
- L.DivIcon
- L.Control
- L.Control.zoom
- L.Control.Attribution
- L.Control.Layers
- L.Control.Scale
- Events methods
- Event objects
- L.Class
- L.Browser
- L.Util
- L.Transformation
- L.LineUtil
- L.PolyUtil
- L.DomEvent
- L.DomUtil
- L.PosAnimation
- L.Draggable
- L.IHandler
- L.ILayer
- L.IControl
- L.IProjection
- L.ICRS
- Global Switches
- L.noConflict
- L.version
Themes
Events
Services (Optional)
Leaflet
Themes
L.Wrld.themes
Events
Event objects
Services (Optional)
WrldPoiApi
Leaflet
L.Map
L.Marker
L.Popup
L.TileLayer
L.TileLayer.WMS
L.TileLayer.Canvas
L.ImageOverlay
L.Path
L.Polyline
L.MultiPolyline
L.Polygon
L.MultiPolygon
L.Rectangle
L.Circle
L.CircleMarker
L.LayerGroup
L.FeatureGroup
L.GeoJson
L.LatLng
L.LatLngBounds
L.Point
L.Bounds
L.Icon
L.DivIcon
L.Control
L.Control.zoom
L.Control.Attribution
L.Control.Layers
L.Control.Scale
Events methods
Event objects
L.Class
L.Browser
L.Util
L.Transformation
L.LineUtil
L.PolyUtil
L.DomEvent
L.DomUtil
L.PosAnimation
L.Draggable
L.IHandler
L.ILayer
L.IControl
L.IProjection
L.ICRS
Global Switches
L.noConflict
L.version