-if ( !Array.prototype.forEach ) {
- Array.prototype.forEach = function(fn, scope) {
- for(var i = 0, len = this.length; i < len; ++i) {
- fn.call(scope || this, this[i], i, this);
- }
- }
-}
-
-/*
- * 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,objtype,objid) {
- var decimals = Math.pow(10, Math.floor(zoom/3));
- var node;
-
- lat = Math.round(lat * decimals) / decimals;
- lon = Math.round(lon * decimals) / decimals;
-
- if (minlon) {
- minlon = Math.round(minlon * decimals) / decimals;
- minlat = Math.round(minlat * decimals) / decimals;
- maxlon = Math.round(maxlon * decimals) / decimals;
- maxlat = Math.round(maxlat * decimals) / decimals;
- }