new MapBrowserEvent
Parameters:
| Name | Type | Argument | Description |
|---|---|---|---|
type |
string | Event type. | |
map |
ol.Map | Map. | |
browserEvent |
goog.events.BrowserEvent | Browser event. | |
frameState |
?ol.FrameState= |
<optional> <nullable> |
(Optional) Frame state. |
- Source:
- mapbrowserevent.js, line 27
Extends
Members
-
<static> EventType :string
-
Constants for event names.
- Source:
- mapbrowserevent.js, line 309
Properties:
Name Type Default Description CLICKstring goog.events.EventType.CLICK DBLCLICKstring goog.events.EventType.DBLCLICK DRAGSTARTstring dragstart DRAGstring drag DRAGENDstring dragend DOWNstring down -
browserEvent :goog.events.BrowserEvent
-
- Source:
- mapbrowserevent.js, line 34
-
defaultPrevented :boolean
-
- Inherited From:
- Source:
- mapevent.js, line 36
-
frameState :?ol.FrameState
-
- Inherited From:
- Source:
- mapevent.js, line 41
-
map :ol.Map
-
- Inherited From:
- Source:
- mapevent.js, line 31
Methods
-
getCoordinate
-
- Source:
- mapbrowserevent.js, line 55
Returns:
Coordinate.- Type
- ol.Coordinate
-
getPixel
-
Get pixel offset of the event from the top-left corner of the map viewport.
- Source:
- mapbrowserevent.js, line 67
Returns:
Pixel offset.- Type
- ol.Pixel
-
isMouseActionButton
-
- Source:
- mapbrowserevent.js, line 80
Returns:
Do we have a left click?- Type
- boolean
-
preventDefault
-
Prevents the default action.
- Inherited From:
- Source:
- mapevent.js, line 50