[Pkg-javascript-commits] [leaflet-markercluster] 84/219: Update MarkerClusterGroup.js

Jonas Smedegaard dr at jones.dk
Sat May 7 09:39:14 UTC 2016


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

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

commit 502d8ac2c83200ee2b9ea6a0a72845b8d7fe6dac
Author: olive380 <olive380 at users.noreply.github.com>
Date:   Wed Aug 5 16:29:28 2015 +0200

    Update MarkerClusterGroup.js
    
    A better solution...
---
 src/MarkerClusterGroup.js | 13 ++++++++-----
 1 file changed, 8 insertions(+), 5 deletions(-)

diff --git a/src/MarkerClusterGroup.js b/src/MarkerClusterGroup.js
index 390be2a..afdb186 100644
--- a/src/MarkerClusterGroup.js
+++ b/src/MarkerClusterGroup.js
@@ -263,6 +263,14 @@ L.MarkerClusterGroup = L.FeatureGroup.extend({
 			return this;
 		}
 
+		if (this._unspiderfy) {
+			this._unspiderfy();
+			for (i = 0, l = layersArray.length; i < l; i++) {
+				m = layersArray[i];
+				this._unspiderfyLayer(m);
+			}
+		}
+		
 		for (i = 0, l = layersArray.length; i < l; i++) {
 			m = layersArray[i];
 
@@ -270,11 +278,6 @@ L.MarkerClusterGroup = L.FeatureGroup.extend({
 				npg.removeLayer(m);
 				continue;
 			}
-
-			if (this._unspiderfy) {
-				this._unspiderfy();
-				this._unspiderfyLayer(m);
-			}
 			
 			this._removeLayer(m, true, true);
 

-- 
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