[Pkg-javascript-commits] [leaflet-markercluster] 294/479: Update build
Jonas Smedegaard
dr at jones.dk
Thu Oct 16 16:00:40 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 f9539fed324a4ff5537016ab123ef6f231d2ed17
Author: danzel <danzel at localhost.geek.nz>
Date: Wed Dec 5 11:30:14 2012 +1300
Update build
---
dist/leaflet.markercluster-src.js | 13 +++++++++----
dist/leaflet.markercluster.js | 2 +-
2 files changed, 10 insertions(+), 5 deletions(-)
diff --git a/dist/leaflet.markercluster-src.js b/dist/leaflet.markercluster-src.js
index b285627..8e28e17 100644
--- a/dist/leaflet.markercluster-src.js
+++ b/dist/leaflet.markercluster-src.js
@@ -27,6 +27,9 @@ L.MarkerClusterGroup = L.FeatureGroup.extend({
// If you are adding individual markers set to true, if adding bulk markers leave false for massive performance gains.
animateAddingMarkers: false,
+ //Increase to increase the distance away that spiderfied markers appear from the center
+ spiderfyDistanceMultiplier: 1,
+
//Options to pass to the L.Polygon constructor
polygonOptions: {}
},
@@ -1496,7 +1499,7 @@ L.MarkerCluster.include({
},
_generatePointsCircle: function (count, centerPt) {
- var circumference = this._circleFootSeparation * (2 + count),
+ var circumference = this._group.options.spiderfyDistanceMultiplier * this._circleFootSeparation * (2 + count),
legLength = circumference / this._2PI, //radius from circumference
angleStep = this._2PI / count,
res = [],
@@ -1513,7 +1516,9 @@ L.MarkerCluster.include({
},
_generatePointsSpiral: function (count, centerPt) {
- var legLength = this._spiralLengthStart,
+ var legLength = this._group.options.spiderfyDistanceMultiplier * this._spiralLengthStart,
+ separation = this._group.options.spiderfyDistanceMultiplier * this._spiralFootSeparation,
+ lengthFactor = this._group.options.spiderfyDistanceMultiplier * this._spiralLengthFactor,
angle = 0,
res = [],
i;
@@ -1521,9 +1526,9 @@ L.MarkerCluster.include({
res.length = count;
for (i = count - 1; i >= 0; i--) {
- angle += this._spiralFootSeparation / legLength + i * 0.0005;
+ angle += separation / legLength + i * 0.0005;
res[i] = new L.Point(centerPt.x + legLength * Math.cos(angle), centerPt.y + legLength * Math.sin(angle))._round();
- legLength += this._2PI * this._spiralLengthFactor / angle;
+ legLength += this._2PI * lengthFactor / angle;
}
return res;
}
diff --git a/dist/leaflet.markercluster.js b/dist/leaflet.markercluster.js
index 926151d..d202dbc 100644
--- a/dist/leaflet.markercluster.js
+++ b/dist/leaflet.markercluster.js
@@ -3,4 +3,4 @@
Leaflet.markercluster is an open-source JavaScript library for Marker Clustering on leaflet powered maps.
https://github.com/danzel/Leaflet.markercluster
*/
-(function(e,t){L.MarkerClusterGroup=L.FeatureGroup.extend({options:{maxClusterRadius:80,iconCreateFunction:null,spiderfyOnMaxZoom:!0,showCoverageOnHover:!0,zoomToBoundsOnClick:!0,singleMarkerMode:!1,disableClusteringAtZoom:null,animateAddingMarkers:!1,polygonOptions:{}},initialize:function(e){L.Util.setOptions(this,e),this.options.iconCreateFunction||(this.options.iconCreateFunction=this._defaultIconCreateFunction),L.FeatureGroup.prototype.initialize.call(this,[]),this._inZoomAnimation=0 [...]
\ No newline at end of file
+(function(e,t){L.MarkerClusterGroup=L.FeatureGroup.extend({options:{maxClusterRadius:80,iconCreateFunction:null,spiderfyOnMaxZoom:!0,showCoverageOnHover:!0,zoomToBoundsOnClick:!0,singleMarkerMode:!1,disableClusteringAtZoom:null,animateAddingMarkers:!1,spiderfyDistanceMultiplier:1,polygonOptions:{}},initialize:function(e){L.Util.setOptions(this,e),this.options.iconCreateFunction||(this.options.iconCreateFunction=this._defaultIconCreateFunction),L.FeatureGroup.prototype.initialize.call(thi [...]
\ No newline at end of file
--
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