]> git.openstreetmap.org Git - rails.git/commitdiff
Added autoPan for Directions markers
authorJ Guthrie <jamie.guthrie@gmail.com>
Sat, 31 Mar 2018 21:18:25 +0000 (22:18 +0100)
committerJ Guthrie <jamie.guthrie@gmail.com>
Sat, 31 Mar 2018 21:18:25 +0000 (22:18 +0100)
app/assets/javascripts/index/directions.js

index 1a3e0d4ecae558056b2b9867c4ea2ea0fe4b9920..392183cc601263ac24eaaac37be189c24b555e25 100644 (file)
@@ -40,7 +40,8 @@ OSM.Directions = function (map) {
         shadowUrl: OSM.MARKER_SHADOW,
         shadowSize: [41, 41]
       }),
         shadowUrl: OSM.MARKER_SHADOW,
         shadowSize: [41, 41]
       }),
-      draggable: true
+      draggable: true,
+      autoPan: true
     });
 
     endpoint.marker.on('drag dragend', function (e) {
     });
 
     endpoint.marker.on('drag dragend', function (e) {