OpenLayers Api 中文文档2 MapBrowserEvent

OpenLayers Api Doc

MapBrowserEvent

ol/MapBrowserEvent

Events emitted as map browser events are instances of this type. See Map for which events trigger a map browser event.

作为地图浏览器事件发出的事件是这种类型的实例。关于哪些事件会触发地图浏览器事件,请参阅地图。

Extends

成员 Members

coordinate{Coordinate}

The coordinate corresponding to the original browser event. This will be in the user projection if one is set. Otherwise it will be in the view projection.

对应于原始浏览器事件的坐标。如果设置了用户投影,这将是一个用户投影。否则,它将是在视图投影中。

dragging{boolean}

Indicates if the map is currently being dragged. Only set for POINTERDRAG and POINTERMOVE events. Default is false.

指示地图是否正在被拖动。只对POINTERDRAGPOINTERMOVE事件设置。默认为 “false”。

frameState{FrameState}

The frame state at the time of the event.

事件发生时的框架状态。

map{Map}

The map where the event occurred.

事件发生的地图。

originalEvent{EVENT}

The original browser event.

最初的浏览器事件。

pixel{Pixel}

The map pixel relative to the viewport corresponding to the original event.

相对于视口的地图像素,对应于原始事件。

target{Object}

The event target.

该事件的目标。

type{string}

The event type.

事件的类型。

方法Methods

preventDefault()

Prevents the default browser action. See https://developer.mozilla.org/en-US/docs/Web/API/event.preventDefault.

阻止默认的浏览器动作。见https://developer.mozilla.org/en-US/docs/Web/API/event.preventDefault

stopPropagation()

Prevents further propagation of the current event. See https://developer.mozilla.org/en-US/docs/Web/API/event.stopPropagation.

防止当前事件的进一步传播。见https://developer.mozilla.org/en-US/docs/Web/API/event.stopPropagation

事件Events

change inherited

Generic change event. Triggered when the revision counter is increased.

通用的改变事件。当修订计数器增加时触发。

click

一个没有拖动的点击。一次双击将发射两个这样的。

A click with no dragging. A double click will fire two of this.

dblclick

真正的双击,没有拖动。

A true double click, with no dragging.

error inherited

通用的错误事件。当一个错误发生时被触发。

Generic error event. Triggered when an error occurs.

loadend inherited

当加载额外的地图数据完成后触发。

Triggered when loading of additional map data has completed.

loadstart inherited

当开始加载额外的地图数据(瓦片、图像、特征)时触发。

Triggered when loading of additional map data (tiles, images, features) starts.

moveend inherited

在地图被移动后触发。

Triggered after the map is moved.

movestart inherited

当地图开始移动时触发。

Triggered when the map starts moving.

pointerdrag

指针被拖动时触发。

Triggered when a pointer is dragged.

pointermove

指针被移动时触发。注意,在触摸设备上,当地图被平移时触发,所以与mousemove不一样。

Triggered when a pointer is moved. Note that on touch devices this is triggered when the map is panned, so is not the same as mousemove.

postrender inherited

在地图帧被渲染后触发。

Triggered after a map frame is rendered.

singleclick

一个真正的单次点击,没有拖动,没有双击。请注意,这个事件被延迟了250毫秒,以确保它不是一个双击。

A true single click with no dragging and no double click. Note that this event is delayed by 250 ms to ensure that it is not a double click.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值