rem: var zoom = this.getZoom(); this.zoom = null; if (zoom > this.baseLayer.numZoomLevels - 1) { zoom = this.baseLayer.numZoomLevels - 1; } 
add: var oldResolution = oldBaseLayer.getResolution(); var zoom = this.baseLayer.getZoomForResolution(oldResolution); 
context:     setBaseLayer: function(newBaseLayer, noEvent) {        if (newBaseLayer != this.baseLayer) {                      // is newBaseLayer an already loaded layer?            if (this.layers.indexOf(newBaseLayer) != -1) {                // make the old base layer invisible                 if (this.baseLayer != null) {                    this.baseLayer.setVisibility(false, noEvent);                }                // set new baselayer and make it visible                this.baseLayer = newBaseLayer;                this.baseLayer.setVisibility(true, noEvent);                //redraw all layers                var center = this.getCenter();                if (center != null) {                    var zoom = this.getZoom();                    this.zoom = null;                    if (zoom > this.baseLayer.numZoomLevels - 1) {                        zoom = this.baseLayer.numZoomLevels - 1;                    }                        this.setCenter(center, zoom);                                            }                if ((noEvent == null) || (noEvent == false)) {                    this.events.triggerEvent("changebaselayer");                }            }                }    },
meta: 1027	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/1027/1414f0f656c45dacd4651a8ca41b117e14afac3d/Map.js/clean/lib/OpenLayers/Map.js