百度地图 - 点聚合 - Marker设置Lable

MarkerClusterer_min.js

MarkerClusterer.js 修改

g.prototype.remove = function() {

    for (var j = 0, h; h = this._markers[j]; j++) {        

        var tmplabel = this._markers[j].getLabel();       

        this._markers[j].getMap() && this._map.removeOverlay(this._markers[j]);

        this._markers[j].setLabel(tmplabel);

    }

    this._map.removeOverlay(this._clusterMarker);

    this._markers.length = 0;

    delete this._markers

};

你可能感兴趣的:(百度地图 - 点聚合 - Marker设置Lable)