Members
-
module:ol/events/condition~altKeyOnly
-
Return
true
if only the alt-key is pressed,false
otherwise (e.g. when additionally the shift-key is pressed). -
module:ol/events/condition~altShiftKeysOnly
-
Return
true
if only the alt-key and shift-key is pressed,false
otherwise (e.g. when additionally the platform-modifier-key is pressed). -
module:ol/events/condition~click
-
Return
true
if the event is aclick
event,false
otherwise. -
module:ol/events/condition~doubleClick
-
Return
true
if the event is a mapdblclick
event,false
otherwise. -
module:ol/events/condition~focus
-
Return
true
if the map has the focus. This condition requires a map target element with atabindex
attribute, e.g.<div id="map" tabindex="1">
. -
module:ol/events/condition~mouseOnly
-
Return
true
if the event originates from a mouse device. -
module:ol/events/condition~noModifierKeys
-
Return
true
if no modifier key (alt-, shift- or platform-modifier-key) is pressed. -
module:ol/events/condition~platformModifierKeyOnly
-
Return
true
if only the platform-modifier-key (the meta-key on Mac, ctrl-key otherwise) is pressed,false
otherwise (e.g. when additionally the shift-key is pressed). -
module:ol/events/condition~pointerMove
-
Return
true
if the browser event is apointermove
event,false
otherwise. -
module:ol/events/condition~primaryAction
-
Return
true
if the event originates from a primary pointer in contact with the surface or if the left mouse button is pressed. See http://www.w3.org/TR/pointerevents/#button-states. -
module:ol/events/condition~shiftKeyOnly
-
Return
true
if only the shift-key is pressed,false
otherwise (e.g. when additionally the alt-key is pressed). -
module:ol/events/condition~singleClick
-
Return
true
if the event is a mapsingleclick
event,false
otherwise. -
module:ol/events/condition~targetNotEditable
-
Return
true
if the target element is not editable, i.e. not a<input>
-,<select>
- or<textarea>
-element,false
otherwise.
Methods
-
module:ol/events/condition~always(mapBrowserEvent){boolean}
events/condition.js, line 73 -
Return always true.
Name Type Description mapBrowserEvent
module:ol/MapBrowserEvent~MapBrowserEvent Map browser event.
Returns:
True.
-
module:ol/events/condition~never(mapBrowserEvent){boolean}
events/condition.js, line 112 -
Return always false.
Name Type Description mapBrowserEvent
module:ol/MapBrowserEvent~MapBrowserEvent Map browser event.
Returns:
False.
Type Definitions
-
Condition()
events/condition.js, line 10 -
A function that takes an
module:ol/MapBrowserEvent~MapBrowserEvent
and returns a{boolean}
. If the condition is met, true should be returned.