From cf40d8aa8694677275f2c4bac0ed7cb82f413bd6 Mon Sep 17 00:00:00 2001 From: danzel Date: Thu, 31 Oct 2013 09:13:55 +1300 Subject: [PATCH] Hide spiderfied markers on a big zoom. Fixes #268 --- src/MarkerCluster.Spiderfier.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/MarkerCluster.Spiderfier.js b/src/MarkerCluster.Spiderfier.js index 50d1c0a6f..2a1a6f476 100644 --- a/src/MarkerCluster.Spiderfier.js +++ b/src/MarkerCluster.Spiderfier.js @@ -353,10 +353,9 @@ L.MarkerClusterGroup.include({ if (this._map.options.zoomAnimation) { this._map.on('zoomstart', this._unspiderfyZoomStart, this); - } else { - //Browsers without zoomAnimation don't fire zoomstart - this._map.on('zoomend', this._unspiderfyWrapper, this); } + //Browsers without zoomAnimation or a big zoom don't fire zoomstart + this._map.on('zoomend', this._noanimationUnspiderfy, this); if (L.Path.SVG && !L.Browser.touch) { this._map._initPathRoot();