From f53b11d0ea284e869f6941df2b6d57fbb31e23d2 Mon Sep 17 00:00:00 2001 From: danzel Date: Fri, 27 Jul 2012 13:59:46 +1200 Subject: [PATCH] Don't spiderfy/unspiderfy while a zoom is going on --- src/MarkerCluster.Spiderfier.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/MarkerCluster.Spiderfier.js b/src/MarkerCluster.Spiderfier.js index 74da4990e9..cbc3b5339a 100644 --- a/src/MarkerCluster.Spiderfier.js +++ b/src/MarkerCluster.Spiderfier.js @@ -15,7 +15,7 @@ L.MarkerCluster.include({ // 0 -> always spiral; Infinity -> always circle spiderfy: function () { - if (this._group._spiderfied === this) { + if (this._group._spiderfied === this || this._group._inZoomAnimation) { return; } @@ -41,7 +41,9 @@ L.MarkerCluster.include({ }, unspiderfy: function () { - + if (this._group._inZoomAnimation) { + return; + } this._animationUnspiderfy(); this._group._spiderfied = null;