[Pkg-javascript-commits] [leaflet-markercluster] 260/479: Comments

Jonas Smedegaard dr at jones.dk
Thu Oct 16 16:00:37 UTC 2014


This is an automated email from the git hooks/post-receive script.

js pushed a commit to branch master
in repository leaflet-markercluster.

commit d5a7fd003b9eab536e6b91b3715344aabe8ee052
Author: danzel <danzel at localhost.geek.nz>
Date:   Thu Oct 11 10:06:50 2012 +1300

    Comments
---
 src/MarkerClusterGroup.js | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/MarkerClusterGroup.js b/src/MarkerClusterGroup.js
index 27c742c..02be113 100644
--- a/src/MarkerClusterGroup.js
+++ b/src/MarkerClusterGroup.js
@@ -125,6 +125,7 @@ L.MarkerClusterGroup = L.FeatureGroup.extend({
 		return this;
 	},
 
+	//Takes an array of markers and adds them in bulk
 	addLayers: function (layersArray) {
 		if (!this._map) {
 			this._needsClustering = this._needsClustering.concat(layersArray);
@@ -185,6 +186,7 @@ L.MarkerClusterGroup = L.FeatureGroup.extend({
 		return this;
 	},
 
+	//Removes all layers from the MarkerClusterGroup
 	clearLayers: function () {
 		//Need our own special implementation as the LayerGroup one doesn't work for us
 
@@ -211,6 +213,7 @@ L.MarkerClusterGroup = L.FeatureGroup.extend({
 		return this;
 	},
 
+	//Returns true if the given layer is in this MarkerClusterGroup
 	hasLayer: function (layer) {
 		var res = false;
 
@@ -225,6 +228,7 @@ L.MarkerClusterGroup = L.FeatureGroup.extend({
 		return res;
 	},
 
+	//Zoom down to show the given layer (spiderfying if necessary) then calls the callback
 	zoomToShowLayer: function (layer, callback) {
 
 		var showMarker = function () {

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/leaflet-markercluster.git



More information about the Pkg-javascript-commits mailing list