]> git.openstreetmap.org Git - rails.git/blobdiff - public/javascripts/site.js
Change the feature commited in [16174] to use the main map view
[rails.git] / public / javascripts / site.js
index aefd9c8b68fd2044119c255b6048f8698c41ca18..5340ea99eeb4b3a64ae1aa31060319dc2c002702 100644 (file)
@@ -2,7 +2,7 @@
  * Called as the user scrolls/zooms around to aniplate hrefs of the
  * view tab and various other links
  */
-function updatelinks(lon,lat,zoom,layers,minlon,minlat,maxlon,maxlat) {
+function updatelinks(lon,lat,zoom,layers,minlon,minlat,maxlon,maxlat, obj_type, obj_id) {
   var decimals = Math.pow(10, Math.floor(zoom/3));
   var node;
 
@@ -18,6 +18,9 @@ function updatelinks(lon,lat,zoom,layers,minlon,minlat,maxlon,maxlat) {
     if (layers) {
       args["layers"] = layers;
     }
+    if (obj_type && obj_id) {
+      args[obj_type] = obj_id;
+    }
     node.href = setArgs(node.href, args);
   }