]> git.openstreetmap.org Git - rails.git/blobdiff - public/openlayers/OpenStreetMap.js
Only add the data layer to the main map, and use the visibility changed
[rails.git] / public / openlayers / OpenStreetMap.js
index f472d3fc14631d543fd4215b8448b9cb71f78e0d..d6bc397d132ae517433ae494ad5956a0cc18cef1 100644 (file)
@@ -182,19 +182,3 @@ OpenLayers.Layer.OSM.Maplint = OpenLayers.Class(OpenLayers.Layer.OSM, {
 
     CLASS_NAME: "OpenLayers.Layer.OSM.Maplint"
 });
-
-OpenLayers.Layer.Data = OpenLayers.Class(OpenLayers.Layer, { 
-    setVisibility: function(vis) {
-        var oldvis = this.visibility;
-        OpenLayers.Layer.prototype.setVisibility.apply(this, arguments);
-        if (!this.map) { return; }
-        if (vis && !oldvis) {
-            new Ajax.Request('/browse/start', {asynchronous:true, evalScripts:true}); 
-        } else {
-            if (this.stopBrowse) {
-                this.stopBrowse();
-                closeSidebar(); 
-            }    
-        }    
-    }
-});