Commit 34c6b428ea7c0918ff50f644785816e1d9ec1947

Authored by Edmar Moretti
1 parent 34a04822

--no commit message

mashups/openlayers.js.php
... ... @@ -173,7 +173,10 @@ i3GEO.editorOL = {
173 173 eval("i3GEO.editorOL."+fundo[i]+".setVisibility(false);");
174 174 eval("alayers.push(i3GEO.editorOL."+fundo[i]+");");
175 175 }
176   - catch(e){alayers[0].setVisibility(true);}
  176 + catch(e){
  177 + if(alayers[0])
  178 + alayers[0].setVisibility(true);
  179 + }
177 180 }
178 181 }
179 182 i3GEO.editorOL.mapa.addLayers(alayers);
... ... @@ -629,7 +632,7 @@ i3GEO.editorOL = {
629 632 button = new OpenLayers.Control.Button({
630 633 displayClass: "editorOLzoomtot",
631 634 trigger: function(){i3GEO.editorOL.mapa.zoomToMaxExtent();},
632   - title: "ajusta extensão"
  635 + title: "ajusta extensão"
633 636 });
634 637 controles.push(button);
635 638 adiciona = true;
... ...
mashups/openlayers.php
... ... @@ -292,10 +292,13 @@ i3GEO.editorOL.tiles = "<?php
292 292 echo "i3GEO.editorOL.numzoom = ".$numzoomlevels.";";
293 293 }
294 294 ?>
295   -<?php if(isset($maxextent)){
  295 +<?php
  296 +if(isset($maxextent)){
296 297 $maxextent = str_replace(" ",",",$maxextent);
297 298 echo "i3GEO.editorOL.maxext = new OpenLayers.Bounds(".$maxextent.");";
298 299 }
  300 +else
  301 +{echo "i3GEO.editorOL.maxext = new OpenLayers.Bounds(-76.5125927,-39.3925675209,-29.5851853,9.49014852081);";}
299 302 ?>
300 303 <?php if(isset($mapext)){
301 304 $mapext = str_replace(" ",",",$mapext);
... ...