Don't process overlay layers in old-style layer configurations
authorTom Hughes <tom@compton.nu>
Thu, 12 Aug 2010 23:09:41 +0000 (00:09 +0100)
committerTom Hughes <tom@compton.nu>
Fri, 13 Aug 2010 14:13:30 +0000 (15:13 +0100)
There are no overlay layers that we actually want to be persistent, and
the removal of the maplint layer means that old configurations generally
open the wrong overlays now anyway.

public/javascripts/map.js

index 272913d203c2ae8462888ff84ae1e85b748d2f7e..0668b8ab055c532460f0062ad22c1b8768657af9 100644 (file)
@@ -244,20 +244,6 @@ function setMapLayers(layerConfig) {
             map.setBaseLayer(layers[i]);
          }
       }
-
-      while (layerConfig.charAt(l) == "B" || layerConfig.charAt(l) == "0") {
-         l++;
-      }
-
-      for (var layers = map.getLayersBy("isBaseLayer", false), i = 0; i < layers.length; i++) {
-         var c = layerConfig.charAt(l++);
-
-         if (c == "T") {
-            layers[i].setVisibility(true);
-         } else if(c == "F") {
-            layers[i].setVisibility(false);
-         }
-      }
    } else {
       for (var i = 0; i < map.layers.length; i++) {
          if (map.layers[i].layerCode) {