diff options
author | Katie Filbert <filbertk@gmail.com> | 2012-12-01 19:51:14 +0100 |
---|---|---|
committer | Katie Filbert <filbertk@gmail.com> | 2012-12-01 19:51:14 +0100 |
commit | 1da493d2d40e4333711991e94b61d690e99f2db8 (patch) | |
tree | fa6c40d6ef84e1086338ae37c99226aa79f490f3 | |
parent | 52b27dc1a6a45feba00220c8193a8fde1e91d101 (diff) | |
download | health-map-1da493d2d40e4333711991e94b61d690e99f2db8.tar health-map-1da493d2d40e4333711991e94b61d690e99f2db8.tar.gz |
min zoom level for layer
-rw-r--r-- | resources/map.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/resources/map.js b/resources/map.js index 9a56112..1909037 100644 --- a/resources/map.js +++ b/resources/map.js @@ -21,6 +21,10 @@ $(document).ready(function() { map.on('locationerror', onLocationError); map.on('moveend', function(e) { + var zoom = map.getZoom(); + if (zoom < 10) { + return; + } if (!self.hospitalLayer) return; var bounds = map.getBounds(); |