]> git.parisson.com Git - mezzo.git/commitdiff
Limit the map zoom level to 3
authorJérémy Fabre <Jeremy@iMac-de-Jeremy.local>
Mon, 24 Oct 2016 13:13:38 +0000 (15:13 +0200)
committerJérémy Fabre <Jeremy@iMac-de-Jeremy.local>
Mon, 24 Oct 2016 13:13:38 +0000 (15:13 +0200)
app/static/src/js/modules/lightslidernetwork-init.js

index d1cd5c965ee4111c48a50ae50ee1d43d0f5c4bdd..f386fa56261dd0b9e0eacecb9cf707b9cccd5294 100644 (file)
@@ -57,6 +57,10 @@ LightSliderNetworkInit.prototype.init = function() {
             that.initMarkers();
         });
 
+        google.maps.event.addListener(that.map, 'zoom_changed', function() {
+            if (that.map.getZoom() < 3) that.map.setZoom(3);
+        });
+
     }
 
 };