Skip to content

Commit a9b061e

Browse files
committed
修改项目名称,修复mapv和echart是图层问题
1 parent babedb1 commit a9b061e

File tree

4 files changed

+13
-16
lines changed

4 files changed

+13
-16
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ SuperMap iClient for JavaScript 是一套由 JavaScript 语言编写的 GIS 客
88
## 简介
99
* 官网:[http://iclient.supermap.io](http://iclient.supermap.io)
1010

11-
* 源码:[https://github.com/SuperMap/iClient9](https://github.com/SuperMap/iClient9)
11+
* 源码:[https://github.com/SuperMap/iClient9-JavaScript](https://github.com/SuperMap/iClient9-JavaScript)
1212

1313
## 许可
1414
[ Apache License 2.0 ](./LICENSE)

src/leaflet/overlay/EChartsLayer.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,9 +147,6 @@ export var EchartsLayer = L.Layer.extend({
147147
},
148148

149149
onRemove: function (map) {
150-
for (var i in this._layers) {
151-
map.removeLayer(this._layers[i]);
152-
}
153150
// 销毁echarts实例
154151
this._ec.dispose();
155152
},

src/leaflet/overlay/MapVLayer.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -51,13 +51,13 @@ export var MapVLayer = L.Layer.extend({
5151
this.fire("loaded");
5252
},
5353

54-
_hide: function () {
55-
this.canvas.style.display = 'none';
56-
},
54+
// _hide: function () {
55+
// this.canvas.style.display = 'none';
56+
// },
5757

58-
_show: function () {
59-
this.canvas.style.display = 'block';
60-
},
58+
// _show: function () {
59+
// this.canvas.style.display = 'block';
60+
// },
6161

6262
/**
6363
* @private

src/leaflet/overlay/mapv/MapVRenderer.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,6 @@ export default class MapVRenderer extends BaseLayer {
3333
this._moveStartEvent = this.moveStartEvent.bind(this);
3434
this._moveEndEvent = this.moveEndEvent.bind(this);
3535
this._zoomstart = this.zoomStartEvent.bind(this);
36-
this.map.on('movestart', this._moveStartEvent);
37-
this.map.on('moveend', this._moveEndEvent);
38-
this.map.on('zoomstart', this._zoomstart);
3936
this.bindEvent();
4037
}
4138

@@ -75,9 +72,9 @@ export default class MapVRenderer extends BaseLayer {
7572
map.on('mousemove', this.mousemoveEvent);
7673
}
7774
}
78-
this.map.off('movestart', this._moveStartEvent);
79-
this.map.off('moveend', this._moveEndEvent);
80-
this.map.off('zoomstart', this._zoomStartEvent);
75+
this.map.on('movestart', this._moveStartEvent);
76+
this.map.on('moveend', this._moveEndEvent);
77+
this.map.on('zoomstart', this._zoomstart);
8178
}
8279

8380
/**
@@ -96,6 +93,9 @@ export default class MapVRenderer extends BaseLayer {
9693
map.off('mousemove', this.mousemoveEvent);
9794
}
9895
}
96+
this.map.off('movestart', this._moveStartEvent);
97+
this.map.off('moveend', this._moveEndEvent);
98+
this.map.off('zoomstart', this._zoomStartEvent);
9999
}
100100

101101
/**

0 commit comments

Comments
 (0)