MCPcopy Index your code
hub / github.com/SuperMap/iClient-JavaScript / _bindMapEvent

Method _bindMapEvent

src/mapboxgl/mapping/VideoMap.js:287–306  ·  view source on GitHub ↗
(e)

Source from the content-addressed store, hash-verified

285 }
286
287 _bindMapEvent(e) {
288 if (e.lngLat) {
289 if (this.originCoordsRightBottom && this.originCoordsLeftTop && this.videoWidth && this.videoHeight) {
290 let coord = [e.lngLat.lng, e.lngLat.lat];
291 if (this.coordTransfer) {
292 let spatialPoint = this.coordTransfer.toSpatialCoordinate(
293 transformCoordReverse({
294 coord,
295 originCoordsRightBottom: this.originCoordsRightBottom,
296 originCoordsLeftTop: this.originCoordsLeftTop,
297 videoHeight: this.videoHeight,
298 videoWidth: this.videoWidth
299 })
300 );
301 e.spatialPoint = [spatialPoint[0], spatialPoint[1]];
302 }
303 }
304 }
305 this.fire(e.type, { mapEvent: e });
306 }
307}

Callers

nothing calls this directly

Calls 3

transformCoordReverseFunction · 0.90
toSpatialCoordinateMethod · 0.80
fireMethod · 0.45

Tested by

no test coverage detected