236 Commits

Author SHA1 Message Date
038f17f725 Simplify QuickHull generation. Fixes #249 2013-09-20 13:34:08 -04:00
b7a8ee44ba Test and document quickhull algorithm 2013-09-18 13:21:15 -04:00
4f40622dfe removeLayer supports LayerGroup. Fixes #236 2013-08-26 15:39:25 +12:00
31a8bb7772 Test and fix for removing and re-adding a marker while we are not on the map. 2013-07-18 11:25:02 +12:00
4ce11f3c8b Fix markers not being added on a big zoom animation. Fixes #216
If we zoomed down such that a cluster would be out of our visible bounds then any of its children would be added at its location for the animation. In this case those markers would immediately be removed as they are out of our visible bounds.
Instead we now don't animate adding markers after a zoom if they are coming from outside of our visible bounds.
2013-07-10 11:04:55 +12:00
63e43e430f Clear our internal cluster layer when we are removed from the map so those layers aren't there when we are re-added. Fixes #211 2013-07-05 12:03:20 +12:00
847271498c Support spiderfying circle/circleMarker. Fixes #212 2013-07-05 11:21:55 +12:00
74e1443bb0 Throw an error if a MarkerClusterGroup is added to a map with no maxZoom. Fixes #189 2013-07-01 09:45:09 +12:00
80e2496045 Don't try extend bounds by an invalid bounds, doesn't work on leaflet versions earlier than Leaflet/Leafet@ef17f99708, to be removed when 0.6 is released. 2013-06-25 09:03:53 +12:00
3e6a715b91 Fixes for #200 2013-06-24 10:23:44 +12:00
10b91f8ad4 More tests and more making them work 2013-06-22 10:47:10 +12:00
d032b53fea Fix places we were looping over this._layers to use this._featureGroup.eachLayer instead. Fixes child markers not being added to the map. 2013-06-21 16:55:38 +12:00
cbe92f1468 Support adding random things to the MarkerClusterGroup. Don't try to to cluster them. Refs #195 2013-06-21 16:41:56 +12:00
d47a3140ca Refactor to contain a FeatureGroup rather than sort of being one. Fixes all the _noHas hacks. Now we require leaflet 0.5 however. 2013-06-21 16:14:47 +12:00
9d9fde91aa More whitespace fixes 2013-06-21 15:15:55 +12:00
8807a0c3a2 White space formatting and make sure we don't hit null if the parent isn't visible. 2013-06-21 15:15:01 +12:00
4d3c964172 #123 adding getVisibleParent for Marker
(cherry picked from commit da2952d57bdab7af998ab480200c38212cbc662e)
2013-06-21 15:12:32 +12:00
9f0819706e Another noHas hack, fixes spiderfy in IE 2013-06-19 10:15:58 +12:00
04b71ed450 Add factory method and use them everywhere. Fixes #21 2013-06-14 17:08:22 +12:00
9152c2aaba Another _noHas hack to fix removing layers. 2013-06-14 16:22:34 +12:00
0394227f49 Fix lots of bugs with using CircleMarker/Circle as children. Fixes #189 Fixes #148 2013-06-14 15:49:01 +12:00
1440b56b4e More _noHas hacks. Will work around this properly at some stage, fixes #60 again. 2013-06-14 14:15:34 +12:00
b11665eb83 Replace all build scripts with latest ones from leaflet. Add a package.json 2013-06-14 10:56:53 +12:00
e0846ced2d Don't break if calling hasLayer with null. Fixes #170. Thanks @l0c0luke 2013-05-10 09:36:15 +12:00
e7e1d5391f Fix #160
If we are added to the map, then removed, then a marker is removed from us. Previously that marker wouldn't be removed, now it is when we get re-added to the map.
2013-04-26 09:58:40 +12:00
dcbaabe234 Remove hasProperty checks from loops. Refs leaflet/leaflet#1606 2013-04-24 10:48:00 +12:00
890406abd6 Fix clearLayers with spiderfied markers. Refs #162 2013-04-24 10:44:46 +12:00
ef4227dcd2 Make this work on old leaflet too. Thanks @nkovacs 2013-04-24 10:08:20 +12:00
47c147d9a9 Cludge around our hasLayer implementation to make us work with the latest Leaflet master. Fixes #159
Our hasLayer returns true when we contains a marker. FeatureGroup/LayerGroup (which we inherit from) now check hasLayer when addLayer is called. At this stage our hasLayer will return true, stopping the marker from ending up on the map.
2013-04-22 09:31:10 +12:00
6276021bd9 Fix some warnings from new uglify 2013-04-15 10:11:49 +12:00
4883316d19 Add MarkerCluster.getBounds 2013-04-10 09:05:20 +12:00
1eea835251 Fix whitespace 2013-04-10 09:05:19 +12:00
828bb3e2d6 Fix not firing animationEnd when we have only one marker in the markerClusterGroup. Fixes #146 2013-04-10 09:05:19 +12:00
542fc622b6 Reduce all animation timers to 200ms instead of 250ms so that they happen within the space of a leaflet zoom. Fixes #140 more details on there. 2013-03-01 14:15:34 +13:00
17846a97c4 Removed Trailing whitespaces 2013-02-23 21:26:39 -05:00
604c2e25e1 Removed library files 2013-02-12 09:19:43 +13:00
ed311ad5f4 Added an option (removeOutsideVisibleBounds) to prevent removing clusters that are deemed to be outside of the visible bounds. Fixes #103 2013-02-12 09:19:43 +13:00
0e92b6622a Don't show the coverage of spiderfied MarkerClusters because it will be wrong. Fixes #95 2013-02-01 10:57:29 +13:00
1566118ac5 Make us not crash if we have a spidified cluster and it has a marker added to it. Fixes #114 bug 2 2013-01-09 11:21:59 +13:00
4afda973fc Fix #114 bug 1. 2013-01-09 11:21:58 +13:00
46ca075ccb Fix map.removeLayers(MCG) not doing anything. Thanks Driklyn. Fixes #108 2012-12-21 15:01:13 +13:00
e86afca04a Fix clearLayers not unsetting __parent of the markers, preventing them from being re-added. Fixes #99 2012-12-06 13:42:27 +13:00
73ae0e9a9b Redo eachChildLayer, turns out with a bit of love we can override eachLayer, yay :)
Refs #102
2012-12-06 13:16:45 +13:00
13e71f5a85 Add eachChildLayer, an eachLayer implementation. We cannot override eachLayer as we have different behaviour. Doing so makes us add all makers to the map always which is dumb :(
Fixes #102
2012-12-06 09:47:31 +13:00
bb92b17b20 Add options.spiderfyDistanceMultiplier, allows making spiderfied markers go futher away. Fixes #100 2012-12-05 11:28:54 +13:00
f875421fc4 Fix up some bugs that happen when removing and adding a MarkerClusterGroup from the map.
Was leaving layers in _layers which meant they'd get added again when we were re-added. Wasn't unbinding our events from almost anything.
Fixes #94
2012-11-22 17:05:44 +13:00
9fb345543a Handle removeLayers([]) where some elements aren't in the MarkerClusterGroup 2012-11-14 09:58:22 +13:00
17f32ab1f8 When initially adding layers, skip layers that are already added. Fixes adding the same layer multiple times before adding the MarkerClusterGroup to the map. Refs #44 2012-11-09 15:53:21 +13:00
ef2a51235e Unset layer.__parent in removeLayers as well as removeLayer. Refs #44 2012-11-01 09:45:04 +13:00
bef1dbb33e Feature Detect SVG Animation and only use it if available. IE10 does not support it. Fixes #86 2012-11-01 09:32:51 +13:00