]> git.openstreetmap.org Git - rails.git/blobdiff - app/assets/javascripts/index.js
Using GraphHopper new API
[rails.git] / app / assets / javascripts / index.js
index 2b5f23ef17d2f9487956d7332eb4e90603c49048..52b8b4c2300c1386a93b518976ddbee10b8920a0 100644 (file)
@@ -355,6 +355,7 @@ $(document).ready(function () {
     e.preventDefault();
     $(".search").hide();
     $(".routing").show();
+    $(".search_form input[type='submit']").addClass("routing_submit");
     $(".query_wrapper.routing [name=route_from]").focus();
     $("#map").on('dragend dragover',function(e) { e.preventDefault(); });
     $("#map").on('drop',function(e) { OSM.routing.handleDrop(e); e.preventDefault(); });
@@ -372,6 +373,7 @@ $(document).ready(function () {
     e.preventDefault();
     $(".search").show();
     $(".routing").hide();
+    $(".search_form input[type='submit']").removeClass("routing_submit");
     OSM.routing.close();
     $("#map").off('dragend drop dragover');
     $(".routing_marker").off('dragstart');