开启地图识别监听

 map-identify.js
* 开启地图识别监听
   */
  startIdentify() {
    if (!this._map) {
      return
    }
    if (!this.mouseTip || this._viewer !== this._mapStore.gMapObject.viewer) {
      this._viewer = this._mapStore.gMapObject.viewer
      this.mouseTip = new MouseTip(this._viewer)
    }
    this._createHelpTooltip()
    this._handlers.push(
      this._viewer.on('click', clickEvt => {
        this._mapClickHandle(clickEvt)
      })
    )
  }
posted @ 2022-03-24 09:52  进击中的前端攻城狮  阅读(29)  评论(0编辑  收藏  举报