Commit 6f8df691670bf6b3f34fd2d2734b74c897235346
1 parent
78784c1d
Exists in
master
and in
7 other branches
Conclusão da documentação
Showing
18 changed files
with
412 additions
and
173 deletions
Show diff stats
aplicmap/geral1.map
| ... | ... | @@ -51,6 +51,16 @@ MAP |
| 51 | 51 | # FORMATOPTION "QUANTIZE_COLORS=256" |
| 52 | 52 | #END |
| 53 | 53 | OUTPUTFORMAT |
| 54 | + NAME jpeg | |
| 55 | + DRIVER "GD/JPEG" | |
| 56 | + MIMETYPE "image/jpeg" | |
| 57 | + IMAGEMODE RGB | |
| 58 | + EXTENSION "jpg" | |
| 59 | + TRANSPARENT TRUE | |
| 60 | + EXTENSION jpg | |
| 61 | + FORMATOPTION "INTERLACE=OFF" | |
| 62 | + END | |
| 63 | + OUTPUTFORMAT | |
| 54 | 64 | NAME svg |
| 55 | 65 | MIMETYPE "image/svg+xml" |
| 56 | 66 | DRIVER svg |
| ... | ... | @@ -318,7 +328,7 @@ MAP |
| 318 | 328 | POINTS |
| 319 | 329 | 10 5 |
| 320 | 330 | END |
| 321 | - TEXT "-I3Geo" | |
| 331 | + TEXT "- i3Geo" | |
| 322 | 332 | END |
| 323 | 333 | END |
| 324 | 334 | END |
| 325 | 335 | \ No newline at end of file | ... | ... |
aplicmap/geral1windows.map
| ... | ... | @@ -56,6 +56,16 @@ SYMBOLSET "c:\ms4w\apache\htdocs\i3geo/symbols/simbolos.sym" |
| 56 | 56 | #FORMATOPTION "COMPRESSED_OUTPUT=TRUE" |
| 57 | 57 | #FORMATOPTION "FULL_RESOLUTION=TRUE" |
| 58 | 58 | END |
| 59 | + OUTPUTFORMAT | |
| 60 | + NAME jpeg | |
| 61 | + DRIVER "GD/JPEG" | |
| 62 | + MIMETYPE "image/jpeg" | |
| 63 | + IMAGEMODE RGB | |
| 64 | + EXTENSION "jpg" | |
| 65 | + TRANSPARENT TRUE | |
| 66 | + EXTENSION jpg | |
| 67 | + FORMATOPTION "INTERLACE=OFF" | |
| 68 | + END | |
| 59 | 69 | |
| 60 | 70 | OUTPUTFORMAT |
| 61 | 71 | NAME png1 |
| ... | ... | @@ -321,7 +331,7 @@ SYMBOLSET "c:\ms4w\apache\htdocs\i3geo/symbols/simbolos.sym" |
| 321 | 331 | POINTS |
| 322 | 332 | 10 5 |
| 323 | 333 | END |
| 324 | - TEXT "-I3Geo" | |
| 334 | + TEXT "- i3Geo" | |
| 325 | 335 | END |
| 326 | 336 | END |
| 327 | 337 | END |
| 328 | 338 | \ No newline at end of file | ... | ... |
classesjs/classe_eventos.js
classesjs/classe_i3geo.js
| ... | ... | @@ -76,7 +76,9 @@ i3GEO = { |
| 76 | 76 | |
| 77 | 77 | utilizacgi {sim|nao} - indica se o mapa atual está no modo CGI |
| 78 | 78 | |
| 79 | - versaoms {String} - versão do Mapserver instalado no servidor | |
| 79 | + versaoms {String} - versão do Mapserver instalado no servidor (maior) | |
| 80 | + | |
| 81 | + versaomscompleta {String} - versão do Mapserver instalado no servidor (completa) | |
| 80 | 82 | |
| 81 | 83 | mensagens {String} - mensagens para uso no letreiro |
| 82 | 84 | |
| ... | ... | @@ -109,6 +111,7 @@ i3GEO = { |
| 109 | 111 | listavisual: "", |
| 110 | 112 | utilizacgi:"", |
| 111 | 113 | versaoms:"", |
| 114 | + versaomscompleta: "", | |
| 112 | 115 | mensagens:"", |
| 113 | 116 | w: "", |
| 114 | 117 | h: "", |
| ... | ... | @@ -139,6 +142,16 @@ i3GEO = { |
| 139 | 142 | <i3GEO.interface> |
| 140 | 143 | */ |
| 141 | 144 | cria:function(){ |
| 145 | + if (window.location.href.split("?")[1]){ | |
| 146 | + i3GEO.configura.sid = window.location.href.split("?")[1]; | |
| 147 | + // | |
| 148 | + //a biblioteca YUI, por algum motivo, acrescenta # na URL. O # precisa ser removido, caso contrário, a opção de reload da página pelo browser as vezes não funciona | |
| 149 | + // | |
| 150 | + if (i3GEO.configura.sid.split("#")[0]) | |
| 151 | + {i3GEO.configura.sid = i3GEO.configura.sid.split("#")[0];} | |
| 152 | + } | |
| 153 | + else | |
| 154 | + {i3GEO.configura.sid = "";} | |
| 142 | 155 | //para efeitos de compatibilidade |
| 143 | 156 | g_panM = "nao"; |
| 144 | 157 | try {i3GEO.configura.locaplic = g_locaplic;} |
| ... | ... | @@ -206,6 +219,7 @@ i3GEO = { |
| 206 | 219 | listavisual: "", |
| 207 | 220 | utilizacgi:"", |
| 208 | 221 | versaoms:"", |
| 222 | + versaomscompleta:"", | |
| 209 | 223 | mensagens:"", |
| 210 | 224 | w: w, |
| 211 | 225 | h: h, |
| ... | ... | @@ -277,6 +291,8 @@ i3GEO = { |
| 277 | 291 | i3GEO.parametros.r = r; |
| 278 | 292 | i3GEO.parametros.locmapas = locmapas; |
| 279 | 293 | i3GEO.parametros.extentref = extentref; |
| 294 | + i3GEO.parametros.versaoms = versaoms; | |
| 295 | + i3GEO.parametros.versaomscompleta = versaomscompleta; | |
| 280 | 296 | i3GEO.gadgets.quadros.inicia(10); |
| 281 | 297 | i3GEO.gadgets.quadros.grava("extensao",mapexten); |
| 282 | 298 | i3GEO.arvoreDeCamadas.cria("",retorno.data.temas,i3GEO.configura.sid,i3GEO.configura.locaplic); | ... | ... |
classesjs/classe_interface.js
| ... | ... | @@ -416,16 +416,22 @@ i3GEO.interface = { |
| 416 | 416 | OPACIDADE: 0.8, |
| 417 | 417 | redesenha: function(){ |
| 418 | 418 | if(i3GeoMap != ""){ |
| 419 | - i3GeoMap.removeOverlay(i3GEOTileO); | |
| 420 | 419 | posfixo = posfixo + "&"; |
| 421 | - //wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS()+posfixo, i3GeoMap.getBounds()); | |
| 422 | - var i3GEOTile = new GTileLayer(null,0,18,{ | |
| 423 | - tileUrlTemplate:i3GEO.interface.googlemaps.criaTile()+posfixo, | |
| 424 | - isPng:true, | |
| 425 | - opacity:i3GEO.interface.googlemaps.OPACIDADE }); | |
| 426 | - i3GEOTileO = new GTileLayerOverlay(i3GEOTile); | |
| 427 | - i3GeoMap.addOverlay(i3GEOTileO); | |
| 428 | - //i3GeoMap.addOverlay(i3GEOTile); | |
| 420 | + if(tile == false){ | |
| 421 | + i3GeoMap.removeOverlay(wmsmap); | |
| 422 | + wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS()+posfixo, i3GeoMap.getBounds()); | |
| 423 | + i3GeoMap.addOverlay(wmsmap); | |
| 424 | + } | |
| 425 | + else{ | |
| 426 | + i3GeoMap.removeOverlay(i3GEOTileO); | |
| 427 | + | |
| 428 | + var i3GEOTile = new GTileLayer(null,0,18,{ | |
| 429 | + tileUrlTemplate:i3GEO.interface.googlemaps.criaTile()+posfixo, | |
| 430 | + isPng:true, | |
| 431 | + opacity:i3GEO.interface.googlemaps.OPACIDADE }); | |
| 432 | + i3GEOTileO = new GTileLayerOverlay(i3GEOTile); | |
| 433 | + i3GeoMap.addOverlay(i3GEOTileO); | |
| 434 | + } | |
| 429 | 435 | } |
| 430 | 436 | }, |
| 431 | 437 | cria: function(w,h){ |
| ... | ... | @@ -445,13 +451,17 @@ i3GEO.interface = { |
| 445 | 451 | i3GEO.interface.IDMAPA = "googlemaps"; |
| 446 | 452 | }, |
| 447 | 453 | inicia: function(){ |
| 448 | - i3GEO.janela.slider("i3GEO.interface.googlemaps.mudaOpacidade","150"); | |
| 454 | + tile = false; | |
| 455 | + var ver = i3GEO.parametros.versaomscompleta.split("."); | |
| 456 | + if(parseInt(i3GEO.parametros.versaoms) >= 5 && parseInt(ver[1]) > 1) | |
| 457 | + {tile = true;} | |
| 449 | 458 | var pol = i3GEO.parametros.mapexten; |
| 450 | 459 | var ret = pol.split(" "); |
| 451 | 460 | var pt1 = (( (ret[0] * -1) - (ret[2] * -1) ) / 2) + ret[0] *1; |
| 452 | 461 | var pt2 = (((ret[1] - ret[3]) / 2)* -1) + ret[1] *1; |
| 453 | 462 | i3GeoMap = new GMap2($i("googlemaps")); |
| 454 | 463 | i3GeoMap.setMapType(G_SATELLITE_MAP); |
| 464 | + //i3GeoMap.setMapType(G_SATELLITE_3D_MAP); | |
| 455 | 465 | i3GeoMap.addControl(new GLargeMapControl()); |
| 456 | 466 | i3GeoMap.addControl(new GMapTypeControl()); |
| 457 | 467 | var bottomLeft = new GControlPosition(G_ANCHOR_BOTTOM_LEFT,new GSize(0,40)); |
| ... | ... | @@ -459,30 +469,32 @@ i3GEO.interface = { |
| 459 | 469 | var bottomRight = new GControlPosition(G_ANCHOR_BOTTOM_RIGHT); |
| 460 | 470 | i3GeoMap.addControl(new GOverviewMapControl(),bottomRight); |
| 461 | 471 | i3GeoMap.setCenter(new GLatLng(pt2,pt1), 4); |
| 462 | - //wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 463 | - //i3GeoMap.addOverlay(wmsmap); | |
| 464 | - var i3GEOTile = new GTileLayer(null,0,18,{ | |
| 472 | + if(tile == false){ | |
| 473 | + wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 474 | + i3GeoMap.addOverlay(wmsmap); | |
| 475 | + GEvent.addListener(i3GeoMap, "zoomend", function() { | |
| 476 | + i3GeoMap.removeOverlay(wmsmap); | |
| 477 | + wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 478 | + i3GeoMap.addOverlay(wmsmap); | |
| 479 | + }); | |
| 480 | + GEvent.addListener(i3GeoMap, "dragend", function() { | |
| 481 | + i3GeoMap.removeOverlay(wmsmap); | |
| 482 | + wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 483 | + i3GeoMap.addOverlay(wmsmap); | |
| 484 | + }); | |
| 485 | + } | |
| 486 | + else{ | |
| 487 | + i3GEO.janela.slider("i3GEO.interface.googlemaps.mudaOpacidade","150"); | |
| 488 | + var i3GEOTile = new GTileLayer(null,0,18,{ | |
| 465 | 489 | tileUrlTemplate:i3GEO.interface.googlemaps.criaTile(), |
| 466 | 490 | isPng:true, |
| 467 | 491 | opacity:i3GEO.interface.googlemaps.OPACIDADE }); |
| 468 | 492 | |
| 469 | - i3GEOTileO = new GTileLayerOverlay(i3GEOTile); | |
| 470 | - i3GeoMap.addOverlay(i3GEOTileO); | |
| 471 | - var myMapType = new GMapType([i3GEOTile], new GMercatorProjection(18), 'i3Geo'); | |
| 472 | - i3GeoMap.addMapType(myMapType); | |
| 473 | - | |
| 474 | - /* | |
| 475 | - GEvent.addListener(i3GeoMap, "zoomend", function() { | |
| 476 | - i3GeoMap.removeOverlay(wmsmap); | |
| 477 | - wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 478 | - i3GeoMap.addOverlay(wmsmap); | |
| 479 | - }); | |
| 480 | - GEvent.addListener(i3GeoMap, "dragend", function() { | |
| 481 | - i3GeoMap.removeOverlay(wmsmap); | |
| 482 | - wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 483 | - i3GeoMap.addOverlay(wmsmap); | |
| 484 | - }); | |
| 485 | - */ | |
| 493 | + i3GEOTileO = new GTileLayerOverlay(i3GEOTile); | |
| 494 | + i3GeoMap.addOverlay(i3GEOTileO); | |
| 495 | + var myMapType = new GMapType([i3GEOTile], new GMercatorProjection(18), 'i3Geo'); | |
| 496 | + i3GeoMap.addMapType(myMapType); | |
| 497 | + } | |
| 486 | 498 | i3GEO.interface.googlemaps.ativaBotoes(); |
| 487 | 499 | i3GEO.eventos.ativa($i("googlemaps")); |
| 488 | 500 | i3GEO.gadgets.mostraCoordenadasGEO(); |
| ... | ... | @@ -565,9 +577,12 @@ i3GEO.interface = { |
| 565 | 577 | i3GEO.interface.IDMAPA = "googleearth"; |
| 566 | 578 | }, |
| 567 | 579 | inicia: function(){ |
| 568 | - //http://mapas.mma.gov.br/i3geo/pacotes/kmlmapserver/kmlservice.php?map=bioma&typename=bioma&request=kml | |
| 569 | - i3GeoMap.src = "http://www.gmodules.com/ig/ifr?url=http://hosting.gmodules.com/ig/gadgets/file/114026893455619160549/embedkmlgadget.xml&up_kml_url=http%3A%2F%2Fmapas.mma.gov.br%2Fi3geo%2Fpacotes%2Fkmlmapserver%2Fkmlservice.php%3Fmap%3Dbioma%26typename%3Dbioma%26request%3Dkml&up_view_mode=earth&up_earth_2d_fallback=0&up_earth_fly_from_space=1&up_earth_show_buildings=0&synd=open&w=320&h=400&title=Embedded+KML+Viewer&border=%23ffffff%7C3px%2C1px+solid+%23999999&source=http%3A%2F%2Fwww.gmodules.com%2Fig%2Fcreator%3Fsynd%3Dopen%26url%3Dhttp%3A%2F%2Fhosting.gmodules.com%2Fig%2Fgadgets%2Ffile%2F114026893455619160549%2Fembedkmlgadget.xml"; | |
| 570 | - | |
| 580 | + var src = "http://www.gmodules.com/ig/ifr?url=http://hosting.gmodules.com/ig/gadgets/file/114026893455619160549/embedkmlgadget.xml&up_kml_url="; | |
| 581 | + var i = i3GEO.configura.locaplic+"/pacotes/kmlmapserver/kmlservice.php?map="+i3GEO.parametros.mapfile+"&typename=estadosl&request=kml&mode=map&"; | |
| 582 | + //window.open(i) | |
| 583 | + src += escape(i); | |
| 584 | + src += "&up_view_mode=earth&up_earth_2d_fallback=0&up_earth_fly_from_space=1&up_earth_show_buildings=0&synd=open&w=320&h=400&title=Embedded+KML+Viewer&border=%23ffffff%7C3px%2C1px+solid+%23999999&source=http%3A%2F%2Fwww.gmodules.com%2Fig%2Fcreator%3Fsynd%3Dopen%26url%3Dhttp%3A%2F%2Fhosting.gmodules.com%2Fig%2Fgadgets%2Ffile%2F114026893455619160549%2Fembedkmlgadget.xml"; | |
| 585 | + i3GeoMap.src = src; | |
| 571 | 586 | }, |
| 572 | 587 | ativaBotoes: function(){ |
| 573 | 588 | } | ... | ... |
classesjs/classe_janela.js
| ... | ... | @@ -416,18 +416,21 @@ i3GEO.janela = { |
| 416 | 416 | catch(e){}; |
| 417 | 417 | } |
| 418 | 418 | else{ |
| 419 | - i3GEO.janela.fechaAguarde("ajaxdestaca"); | |
| 420 | - i3GEO.janela.fechaAguarde("ajaxabrelente"); | |
| 421 | - i3GEO.janela.fechaAguarde("ajaxiniciaParametros"); | |
| 422 | - i3GEO.janela.fechaAguarde("i3GEO.atualiza"); | |
| 423 | - i3GEO.janela.fechaAguarde("ajaxCorpoMapaEntorno"); | |
| 424 | - i3GEO.janela.fechaAguarde("ajaxCorpoMapa"); | |
| 425 | - i3GEO.janela.fechaAguarde("ajaxLegenda"); | |
| 426 | - i3GEO.janela.fechaAguarde("ajaxReferencia"); | |
| 427 | - i3GEO.janela.fechaAguarde("ajaxEscalaGrafica"); | |
| 428 | - i3GEO.janela.fechaAguarde("montaMapa"); | |
| 429 | - i3GEO.janela.fechaAguarde("aguardedoc"); | |
| 430 | - i3GEO.janela.fechaAguarde("ajaxCorpoMapa1"); | |
| 419 | + try{ | |
| 420 | + i3GEO.janela.fechaAguarde("ajaxdestaca"); | |
| 421 | + i3GEO.janela.fechaAguarde("ajaxabrelente"); | |
| 422 | + i3GEO.janela.fechaAguarde("ajaxiniciaParametros"); | |
| 423 | + i3GEO.janela.fechaAguarde("i3GEO.atualiza"); | |
| 424 | + i3GEO.janela.fechaAguarde("ajaxCorpoMapaEntorno"); | |
| 425 | + i3GEO.janela.fechaAguarde("ajaxCorpoMapa"); | |
| 426 | + i3GEO.janela.fechaAguarde("ajaxLegenda"); | |
| 427 | + i3GEO.janela.fechaAguarde("ajaxReferencia"); | |
| 428 | + i3GEO.janela.fechaAguarde("ajaxEscalaGrafica"); | |
| 429 | + i3GEO.janela.fechaAguarde("montaMapa"); | |
| 430 | + i3GEO.janela.fechaAguarde("aguardedoc"); | |
| 431 | + i3GEO.janela.fechaAguarde("ajaxCorpoMapa1"); | |
| 432 | + } | |
| 433 | + catch(e){} | |
| 431 | 434 | } |
| 432 | 435 | } |
| 433 | 436 | }; | ... | ... |
classesjs/compactados/classe_i3geo_compacto.js
| 1 | -i3GEO={parametros:{mapexten:"",mapscale:"",mapres:"",pixelsize:"",mapfile:"",cgi:"",extentTotal:"",mapimagem:"",geoip:"",listavisual:"",utilizacgi:"",versaoms:"",mensagens:"",w:"",h:"",locsistemas:"",locidentifica:"",r:"",locmapas:"",celularef:""},temaAtivo:"",cria:function(){g_panM="nao";try{i3GEO.configura.locaplic=g_locaplic}catch(e){g_locaplic=i3GEO.configura.locaplic};try{i3GEO.configura.diminuixM=g_diminuixM}catch(e){}try{i3GEO.configura.diminuixN=g_diminuixN}catch(e){}try{i3GEO.configura.diminuiyM=g_diminuiyM}catch(e){}try{i3GEO.configura.diminuiyN=g_diminuiyN}catch(e){}var diminuix=(navm)?i3GEO.configura.diminuixM:i3GEO.configura.diminuixN;var diminuiy=(navm)?i3GEO.configura.diminuiyM:i3GEO.configura.diminuiyN;if(e==undefined){var menos=0;if($i("contemFerramentas")){menos=menos+parseInt($i("contemFerramentas").style.width)}if($i("ferramentas")){menos=menos+parseInt($i("ferramentas").style.width)}var novow=parseInt(screen.availWidth)-diminuix;var novoh=parseInt(screen.availHeight)-diminuiy;if(novow>=1024){novow=1000}if(novoh>=700){novoh=700}try{if(document.body.style.width<400){var novow=parseInt(screen.availWidth)-diminuix;var novoh=parseInt(screen.availHeight)-diminuiy;window.resizeTo(screen.availWidth,screen.availHeight);window.moveTo(0,0)}}catch(e){var e=""}document.body.style.width=novow-diminuix;document.body.style.height=novoh;var w=novow-menos-diminuix;var h=novoh-diminuiy;if(document.getElementById("corpoMapa")){if(document.getElementById("corpoMapa").style.width){var w=parseInt(document.getElementById("corpoMapa").style.width);var h=parseInt(document.getElementById("corpoMapa").style.width)}if(document.getElementById("corpoMapa").style.height){var h=parseInt(document.getElementById("corpoMapa").style.height)}}}else{var w=document.body.offsetWidth-parseInt($i("contemFerramentas").style.width)-diminuix;var h=document.body.offsetHeight-diminuiy}if($i("contemImg")){$i("contemImg").style.height=h+"px";$i("contemImg").style.width=w+"px"}i3GEO.interface.cria(w,h);i3GEO.parametros={mapexten:"",mapscale:"",mapres:"",pixelsize:"",mapfile:"",cgi:"",extentTotal:"",mapimagem:"",geoip:"",listavisual:"",utilizacgi:"",versaoms:"",mensagens:"",w:w,h:h,locsistemas:"",locidentifica:"",r:"",locmapas:"",extentref:""}},inicia:function(){if(typeof("i3GEOmantemCompatibilidade")=='function')i3GEOmantemCompatibilidade();var montaMapa=function(retorno){if(retorno==""){alert("Ocorreu um erro no mapa - montaMapa");retorno={data:{erro:"erro"}}}if(retorno.data.erro){i3GEO.janela.fechaAguarde("montaMapa");document.body.style.backgroundColor="white";document.body.innerHTML="<br>Para abrir o i3Geo utilize o link:<br><a href="+i3GEO.configura.locaplic+"/ms_criamapa.php >"+i3GEO.configura.locaplic+"/ms_criamapa.php</a>";return("linkquebrado")}else{if(retorno.data.variaveis){var tempo="";var titulo="";eval(retorno.data.variaveis);try{if(titulo!=""){top.document.title=titulo}}catch(e){var e=""}i3GEO.ajuda.mostraJanela("Tempo de desenho em segundos: "+tempo,"");i3GEO.parametros.mapexten=mapexten;i3GEO.parametros.mapscale=parseInt(mapscale);i3GEO.parametros.mapres=mapres;i3GEO.parametros.pixelsize=g_celula;i3GEO.parametros.mapfile=mapfile;i3GEO.parametros.cgi=cgi;i3GEO.parametros.extentTotal=mapexten;i3GEO.parametros.mapimagem=mapimagem;i3GEO.parametros.geoip=geoip;i3GEO.parametros.listavisual=listavisual;i3GEO.parametros.utilizacgi=utilizacgi;i3GEO.parametros.versaoms=versaoms;i3GEO.parametros.mensagens=mensagens;i3GEO.parametros.locsistemas=locsistemas;i3GEO.parametros.locidentifica=locidentifica;i3GEO.parametros.r=r;i3GEO.parametros.locmapas=locmapas;i3GEO.parametros.extentref=extentref;i3GEO.gadgets.quadros.inicia(10);i3GEO.gadgets.quadros.grava("extensao",mapexten);i3GEO.arvoreDeCamadas.cria("",retorno.data.temas,i3GEO.configura.sid,i3GEO.configura.locaplic);i3GEO.util.arvore("<b>"+$trad("p13")+"</b>","listaPropriedades",i3GEO.configura.listaDePropriedadesDoMapa);i3GEO.gadgets.mostraBuscaRapida();i3GEO.guias.cria();if($i("arvoreAdicionaTema"))i3GEO.arvoreDeTemas.cria(i3GEO.configura.sid,i3GEO.configura.locaplic,"arvoreAdicionaTema");if($i("mst")){$i("mst").style.display="block"}i3GEO.atualiza(retorno);var temp=0;if($i("contemFerramentas")){temp=temp+parseInt($i("contemFerramentas").style.width)}if($i("ferramentas")){temp=temp+parseInt($i("ferramentas").style.width)}if($i("mst")){$i("mst").style.width=i3GEO.parametros.w+temp+"px"}if(i3GEO.configura.entorno=="sim"){i3GEO.configura.entorno=="nao";i3GEO.navega.entorno.ativaDesativa()}i3GEO.navega.autoRedesenho.ativa();if($i("i3geo_escalanum")){$i("i3geo_escalanum").value=i3GEO.parametros.mapscale}if((i3GEO.parametros.geoip=="nao")&&($i("ondeestou"))){$i("ondeestou").style.display="none"}i3GEO.interface.inicia();if(i3GEO.finaliza){eval(i3GEO.finaliza)}}else{alert("Erro. Impossivel criar o mapa "+retorno.data);return}if(document.getElementById("ajuda")){i3GEO.ajuda.DIVAJUDA="ajuda"}var abreJM="sim";if(i3GEO.util.pegaCookie("g_janelaMen")){var abreJM=i3GEO.util.pegaCookie("g_janelaMen");if(abreJM=="sim")i3GEO.configura.iniciaJanelaMensagens=true;else i3GEO.configura.iniciaJanelaMensagens=false}if(i3GEO.configura.iniciaJanelaMensagens==true){i3GEO.ajuda.abreJanela()}i3GEO.janela.fechaAguarde("montaMapa");if(i3GEO.configura.liberaGuias=="sim"){i3GEO.guias.libera()}}if($i("mst")){$i("mst").style.visibility="visible"}};if(!$i("i3geo")){document.body.id="i3geo"}$i("i3geo").className="yui-skin-sam";if($i("mst"))$i("mst").style.visibility="hidden";if(i3GEO.configura.sid==""){var mashup=function(retorno){i3GEO.configura.sid=retorno.data;i3GEO.inicia()};i3GEO.php.criamapa(mashup,i3GEO.configura.mashuppar)}else{i3GEO.janela.abreAguarde("montaMapa",$trad("o5"));i3GEO.php.inicia(montaMapa,i3GEO.configura.embedLegenda,i3GEO.parametros.w,i3GEO.parametros.h)}if(i3GEO.eventos.NAVEGAMAPA.toString().search("i3GEO.janela.fechaAguarde()")<0){i3GEO.eventos.NAVEGAMAPA.push("i3GEO.janela.fechaAguarde()")}},finaliza:"",atualiza:function(retorno){try{if(retorno.data=="erro"){alert("Erro no mapa. Sera feita uma tentativa de recuperacao.");i3GEO.mapa.recupera.inicia();return}}catch(e){}var erro=function(){var legimagem="";i3GEO.janela.abreAguarde("ajaxiniciaParametros",$trad("o1")+" atualizando");i3GEO.php.corpo(i3GEO.atualiza,i3GEO.configura.tipoimagem)}try{var teste=eval(retorno.data.variaveis)}catch(e){erro.call();return}if(arguments.length==0||retorno==""||retorno.data.variaveis==undefined){erro.call();return}else{if(arguments.length==0){return}i3GEO.mapa.corpo.verifica(retorno);var tempo="";if(i3GEO.desenho.richdraw){i3GEO.desenho.richdraw.clearWorkspace()}mapscale="";mapexten="";eval(retorno.data.variaveis);i3GEO.arvoreDeCamadas.atualiza(retorno.data.temas);if(i3GEO.parametros.mapscale!=mapscale)i3GEO.arvoreDeCamadas.atualizaFarol(mapscale);i3GEO.parametros.mapexten=mapexten;i3GEO.parametros.mapscale=mapscale;i3GEO.parametros.mapres=mapres;i3GEO.parametros.pixelsize=g_celula;i3GEO.parametros.mapimagem=mapimagem;i3GEO.interface.redesenha();g_operacao="";i3GEO.parametros.mapexten=mapexten;if($i("mensagemt")){$i("mensagemt").value=i3GEO.parametros.mapexten}i3GEO.arvoreDeCamadas.CAMADAS=retorno.data.temas;i3GEO.eventos.navegaMapa();if(i3GEO.configura.entorno=="sim"){i3GEO.navega.entorno.geraURL();i3GEO.navega.entorno.ajustaPosicao()}i3GEO.ajuda.mostraJanela("Tempo de redesenho em segundos: "+tempo,"")}}}; | |
| 2 | 1 | \ No newline at end of file |
| 2 | +i3GEO={parametros:{mapexten:"",mapscale:"",mapres:"",pixelsize:"",mapfile:"",cgi:"",extentTotal:"",mapimagem:"",geoip:"",listavisual:"",utilizacgi:"",versaoms:"",versaomscompleta:"",mensagens:"",w:"",h:"",locsistemas:"",locidentifica:"",r:"",locmapas:"",celularef:""},temaAtivo:"",cria:function(){if(window.location.href.split("?")[1]){i3GEO.configura.sid=window.location.href.split("?")[1];if(i3GEO.configura.sid.split("#")[0]){i3GEO.configura.sid=i3GEO.configura.sid.split("#")[0]}}else{i3GEO.configura.sid=""}g_panM="nao";try{i3GEO.configura.locaplic=g_locaplic}catch(e){g_locaplic=i3GEO.configura.locaplic};try{i3GEO.configura.diminuixM=g_diminuixM}catch(e){}try{i3GEO.configura.diminuixN=g_diminuixN}catch(e){}try{i3GEO.configura.diminuiyM=g_diminuiyM}catch(e){}try{i3GEO.configura.diminuiyN=g_diminuiyN}catch(e){}var diminuix=(navm)?i3GEO.configura.diminuixM:i3GEO.configura.diminuixN;var diminuiy=(navm)?i3GEO.configura.diminuiyM:i3GEO.configura.diminuiyN;if(e==undefined){var menos=0;if($i("contemFerramentas")){menos=menos+parseInt($i("contemFerramentas").style.width)}if($i("ferramentas")){menos=menos+parseInt($i("ferramentas").style.width)}var novow=parseInt(screen.availWidth)-diminuix;var novoh=parseInt(screen.availHeight)-diminuiy;if(novow>=1024){novow=1000}if(novoh>=700){novoh=700}try{if(document.body.style.width<400){var novow=parseInt(screen.availWidth)-diminuix;var novoh=parseInt(screen.availHeight)-diminuiy;window.resizeTo(screen.availWidth,screen.availHeight);window.moveTo(0,0)}}catch(e){var e=""}document.body.style.width=novow-diminuix;document.body.style.height=novoh;var w=novow-menos-diminuix;var h=novoh-diminuiy;if(document.getElementById("corpoMapa")){if(document.getElementById("corpoMapa").style.width){var w=parseInt(document.getElementById("corpoMapa").style.width);var h=parseInt(document.getElementById("corpoMapa").style.width)}if(document.getElementById("corpoMapa").style.height){var h=parseInt(document.getElementById("corpoMapa").style.height)}}}else{var w=document.body.offsetWidth-parseInt($i("contemFerramentas").style.width)-diminuix;var h=document.body.offsetHeight-diminuiy}if($i("contemImg")){$i("contemImg").style.height=h+"px";$i("contemImg").style.width=w+"px"}i3GEO.interface.cria(w,h);i3GEO.parametros={mapexten:"",mapscale:"",mapres:"",pixelsize:"",mapfile:"",cgi:"",extentTotal:"",mapimagem:"",geoip:"",listavisual:"",utilizacgi:"",versaoms:"",versaomscompleta:"",mensagens:"",w:w,h:h,locsistemas:"",locidentifica:"",r:"",locmapas:"",extentref:""}},inicia:function(){if(typeof("i3GEOmantemCompatibilidade")=='function')i3GEOmantemCompatibilidade();var montaMapa=function(retorno){if(retorno==""){alert("Ocorreu um erro no mapa - montaMapa");retorno={data:{erro:"erro"}}}if(retorno.data.erro){i3GEO.janela.fechaAguarde("montaMapa");document.body.style.backgroundColor="white";document.body.innerHTML="<br>Para abrir o i3Geo utilize o link:<br><a href="+i3GEO.configura.locaplic+"/ms_criamapa.php >"+i3GEO.configura.locaplic+"/ms_criamapa.php</a>";return("linkquebrado")}else{if(retorno.data.variaveis){var tempo="";var titulo="";eval(retorno.data.variaveis);try{if(titulo!=""){top.document.title=titulo}}catch(e){var e=""}i3GEO.ajuda.mostraJanela("Tempo de desenho em segundos: "+tempo,"");i3GEO.parametros.mapexten=mapexten;i3GEO.parametros.mapscale=parseInt(mapscale);i3GEO.parametros.mapres=mapres;i3GEO.parametros.pixelsize=g_celula;i3GEO.parametros.mapfile=mapfile;i3GEO.parametros.cgi=cgi;i3GEO.parametros.extentTotal=mapexten;i3GEO.parametros.mapimagem=mapimagem;i3GEO.parametros.geoip=geoip;i3GEO.parametros.listavisual=listavisual;i3GEO.parametros.utilizacgi=utilizacgi;i3GEO.parametros.versaoms=versaoms;i3GEO.parametros.mensagens=mensagens;i3GEO.parametros.locsistemas=locsistemas;i3GEO.parametros.locidentifica=locidentifica;i3GEO.parametros.r=r;i3GEO.parametros.locmapas=locmapas;i3GEO.parametros.extentref=extentref;i3GEO.parametros.versaoms=versaoms;i3GEO.parametros.versaomscompleta=versaomscompleta;i3GEO.gadgets.quadros.inicia(10);i3GEO.gadgets.quadros.grava("extensao",mapexten);i3GEO.arvoreDeCamadas.cria("",retorno.data.temas,i3GEO.configura.sid,i3GEO.configura.locaplic);i3GEO.util.arvore("<b>"+$trad("p13")+"</b>","listaPropriedades",i3GEO.configura.listaDePropriedadesDoMapa);i3GEO.gadgets.mostraBuscaRapida();i3GEO.guias.cria();if($i("arvoreAdicionaTema"))i3GEO.arvoreDeTemas.cria(i3GEO.configura.sid,i3GEO.configura.locaplic,"arvoreAdicionaTema");if($i("mst")){$i("mst").style.display="block"}i3GEO.atualiza(retorno);var temp=0;if($i("contemFerramentas")){temp=temp+parseInt($i("contemFerramentas").style.width)}if($i("ferramentas")){temp=temp+parseInt($i("ferramentas").style.width)}if($i("mst")){$i("mst").style.width=i3GEO.parametros.w+temp+"px"}if(i3GEO.configura.entorno=="sim"){i3GEO.configura.entorno=="nao";i3GEO.navega.entorno.ativaDesativa()}i3GEO.navega.autoRedesenho.ativa();if($i("i3geo_escalanum")){$i("i3geo_escalanum").value=i3GEO.parametros.mapscale}if((i3GEO.parametros.geoip=="nao")&&($i("ondeestou"))){$i("ondeestou").style.display="none"}i3GEO.interface.inicia();if(i3GEO.finaliza){eval(i3GEO.finaliza)}}else{alert("Erro. Impossivel criar o mapa "+retorno.data);return}if(document.getElementById("ajuda")){i3GEO.ajuda.DIVAJUDA="ajuda"}var abreJM="sim";if(i3GEO.util.pegaCookie("g_janelaMen")){var abreJM=i3GEO.util.pegaCookie("g_janelaMen");if(abreJM=="sim")i3GEO.configura.iniciaJanelaMensagens=true;else i3GEO.configura.iniciaJanelaMensagens=false}if(i3GEO.configura.iniciaJanelaMensagens==true){i3GEO.ajuda.abreJanela()}i3GEO.janela.fechaAguarde("montaMapa");if(i3GEO.configura.liberaGuias=="sim"){i3GEO.guias.libera()}}if($i("mst")){$i("mst").style.visibility="visible"}};if(!$i("i3geo")){document.body.id="i3geo"}$i("i3geo").className="yui-skin-sam";if($i("mst"))$i("mst").style.visibility="hidden";if(i3GEO.configura.sid==""){var mashup=function(retorno){i3GEO.configura.sid=retorno.data;i3GEO.inicia()};i3GEO.php.criamapa(mashup,i3GEO.configura.mashuppar)}else{i3GEO.janela.abreAguarde("montaMapa",$trad("o5"));i3GEO.php.inicia(montaMapa,i3GEO.configura.embedLegenda,i3GEO.parametros.w,i3GEO.parametros.h)}if(i3GEO.eventos.NAVEGAMAPA.toString().search("i3GEO.janela.fechaAguarde()")<0){i3GEO.eventos.NAVEGAMAPA.push("i3GEO.janela.fechaAguarde()")}},finaliza:"",atualiza:function(retorno){try{if(retorno.data=="erro"){alert("Erro no mapa. Sera feita uma tentativa de recuperacao.");i3GEO.mapa.recupera.inicia();return}}catch(e){}var erro=function(){var legimagem="";i3GEO.janela.abreAguarde("ajaxiniciaParametros",$trad("o1")+" atualizando");i3GEO.php.corpo(i3GEO.atualiza,i3GEO.configura.tipoimagem)}try{var teste=eval(retorno.data.variaveis)}catch(e){erro.call();return}if(arguments.length==0||retorno==""||retorno.data.variaveis==undefined){erro.call();return}else{if(arguments.length==0){return}i3GEO.mapa.corpo.verifica(retorno);var tempo="";if(i3GEO.desenho.richdraw){i3GEO.desenho.richdraw.clearWorkspace()}mapscale="";mapexten="";eval(retorno.data.variaveis);i3GEO.arvoreDeCamadas.atualiza(retorno.data.temas);if(i3GEO.parametros.mapscale!=mapscale)i3GEO.arvoreDeCamadas.atualizaFarol(mapscale);i3GEO.parametros.mapexten=mapexten;i3GEO.parametros.mapscale=mapscale;i3GEO.parametros.mapres=mapres;i3GEO.parametros.pixelsize=g_celula;i3GEO.parametros.mapimagem=mapimagem;i3GEO.interface.redesenha();g_operacao="";i3GEO.parametros.mapexten=mapexten;if($i("mensagemt")){$i("mensagemt").value=i3GEO.parametros.mapexten}i3GEO.arvoreDeCamadas.CAMADAS=retorno.data.temas;i3GEO.eventos.navegaMapa();if(i3GEO.configura.entorno=="sim"){i3GEO.navega.entorno.geraURL();i3GEO.navega.entorno.ajustaPosicao()}i3GEO.ajuda.mostraJanela("Tempo de redesenho em segundos: "+tempo,"")}}}; | |
| 3 | 3 | \ No newline at end of file | ... | ... |
classesjs/compactados/classe_interface_compacto.js
| 1 | -if(typeof(i3GEO)=='undefined'){i3GEO=new Array()}i3GEO.interface={ATUAL:"padrao",IDCORPO:"corpoMapa",IDMAPA:"",redesenha:function(){eval("i3GEO.interface."+i3GEO.interface.ATUAL+".redesenha()")},cria:function(w,h){eval("i3GEO.interface."+i3GEO.interface.ATUAL+".cria("+w+","+h+")")},inicia:function(w,h){eval("i3GEO.interface."+i3GEO.interface.ATUAL+".inicia()")},ativaBotoes:function(){eval("i3GEO.interface."+i3GEO.interface.ATUAL+".ativaBotoes()")},padrao:{redesenha:function(){$i("img").onload=function(){$i("img").onload="";i3GEO.gadgets.quadros.grava("imagem",i3GEO.parametros.mapimagem);i3GEO.gadgets.quadros.grava("extensao",i3GEO.parametros.mapexten);var temp=function(retorno){eval(retorno.data);i3GEO.gadgets.quadros.grava("legenda",legimagem)};i3GEO.mapa.legendaIMAGEM.obtem(temp);if($i("imgtemp")){$i("imgtemp").style.display="none"}if($i("imgClone"))$i("imgClone").style.display="none";$i("img").style.display="block";i3GEO.janela.fechaAguarde("ajaxCorpoMapa")};if(!$i("imgtemp")){var ndiv=document.createElement("div");ndiv.id="imgtemp";ndiv.style.position="absolute";ndiv.style.border="1px solid blue";document.getElementById("corpoMapa").appendChild(ndiv)}if(g_tipoacao=="pan"){$i("imgtemp").style.left=parseInt($i("img").style.left);$i("imgtemp").style.top=parseInt($i("img").style.top);$i("imgtemp").style.width=i3GEO.parametros.w;$i("imgtemp").style.height=i3GEO.parametros.h;$i("imgtemp").style.display="block";$i("imgtemp").style.backgroundImage='url("'+$i("img").src+'")'}$i("img").style.left=0;$i("img").style.top=0;$i("img").src=i3GEO.parametros.mapimagem},cria:function(){var ins="<table>";ins+="<tr><td class=verdeclaro ></td><td class=verdeclaro ><input style='display:none;position:relative' type=image src='' id='imgN' /></td><td class=verdeclaro ></td></tr>";ins+="<tr><td class=verdeclaro ><input style='display:none;position:relative' type=image src='' id='imgL' /></td><td class=verdeclaro ><input style='position:relative;top:0px;left:0px'' type=image src='' id='img' /></td><td class=verdeclaro ><input style='display:none;position:relative' type=image src='' id='imgO' /></td></tr>";ins+="<tr><td class=verdeclaro ></td><td class=verdeclaro ><input style='display:none;position:relative' type=image src='' id='imgS' /></td><td class=verdeclaro ></td></tr>";ins+="</table>";$i(i3GEO.interface.IDCORPO).innerHTML=ins;i3GEO.interface.IDMAPA="img"},inicia:function(){if($i("contemImg")){var elemento="contemImg"}else{var elemento="img"}i3GEO.mapa.ajustaPosicao(elemento);var i=$i("img");i.style.width=i3GEO.parametros.w+"px";i.style.height=i3GEO.parametros.h+"px";var estilo=$i(i3GEO.interface.IDCORPO).style;estilo.width=i3GEO.parametros.w+"px";estilo.height=i3GEO.parametros.h+"px";estilo.clip='rect('+0+" "+(i3GEO.parametros.w)+" "+(i3GEO.parametros.h)+" "+0+')';objmapaparado="nao";i3GEO.gadgets.mostraMenuSuspenso();i3GEO.eventos.ativa(i);i3GEO.gadgets.mostraCoordenadasGEO();i3GEO.gadgets.mostraCoordenadasUTM();i3GEO.gadgets.mostraEscalaNumerica();i3GEO.gadgets.mostraEscalaGrafica();i3GEO.gadgets.visual.inicia();i3GEO.idioma.mostraSeletor();i3GEO.ajuda.ativaLetreiro(i3GEO.parametros.mensagens);i3GEO.interface.padrao.ativaBotoes();if(i3GEO.configura.mapaRefDisplay!="none"){if(i3GEO.util.pegaCookie("i3GEO.configura.mapaRefDisplay")){i3GEO.configura.mapaRefDisplay=i3GEO.util.pegaCookie("i3GEO.configura.mapaRefDisplay")}if(i3GEO.configura.mapaRefDisplay=="block"){i3GEO.maparef.inicia()}}},ativaBotoes:function(){var imagemxy=i3GEO.util.pegaPosicaoObjeto($i(i3GEO.interface.IDCORPO));if($i("barraDeBotoes1")){var x1=imagemxy[0]+40;var y1=imagemxy[1]+10}if($i("barraDeBotoes2")){var x2=imagemxy[0];var y2=imagemxy[1]+10}else{if($i("barraDeBotoes1")){var x1=imagemxy[0];var x2=imagemxy[1]+10}}if($i("barraDeBotoes1"))i3GEO.barraDeBotoes.inicializaBarra("barraDeBotoes1","i3geo_barra1",true,x1,y1);if($i("barraDeBotoes2"))i3GEO.barraDeBotoes.inicializaBarra("barraDeBotoes2","i3geo_barra2",false,x2,y2);i3GEO.barraDeBotoes.ativaBotoes();if(document.getElementById("botao3d")){if(i3GEO.configura.map3d==""){document.getElementById("botao3d").style.display="none"}}}},flamingo:{redesenha:function(){var w=parseInt($i("flamingo").style.width);if(w==i3GEO.parametros.w){$i("flamingo").style.height=parseInt($i("flamingo").style.height)+1}else{$i("flamingo").style.height=parseInt($i("flamingo").style.height)-1}i3GEO.janela.fechaAguarde()},cria:function(w,h){var i=$i(i3GEO.interface.IDCORPO);if(i){var f=$i("flamingo");if(!f){var ins='<div id=flamingo style="width:0px;height:0px;text-align:left;background-image:url(/"'+i3GEO.configura.locaplic+'/imagens/i3geo1bw.jpg/")"></div>';i.innerHTML=ins}var f=$i("flamingo");f.style.width=w;f.style.height=h;i3GEO.interface.IDMAPA="flamingo"}},inicia:function(){var monta=function(retorno){$i("flamingo").style.height=i3GEO.parametros.h+45;childPopups=new Array();childPopupNr=0;var so=new SWFObject(i3GEO.configura.locaplic+"/pacotes/flamingo/flamingo/flamingo.swf?config="+retorno.data,"flamingoi","100%","100%","8","#eaeaea");so.addParam("wmode","transparent");so.write("flamingo")}i3GEO.php.flamingo(monta);i3GEO.eventos.ativa($i("flamingo"));i3GEO.maparef.atualiza();if(i3GEO.configura.mapaRefDisplay!="none"){if(i3GEO.util.pegaCookie("i3GEO.configura.mapaRefDisplay")){i3GEO.configura.mapaRefDisplay=i3GEO.util.pegaCookie("i3GEO.configura.mapaRefDisplay")}if(i3GEO.configura.mapaRefDisplay=="block"){i3GEO.maparef.inicia()}}},ativaBotoes:function(){}},openlayers:{redesenha:function(){if($i("openlayers_OpenLayers_Container")){var no=$i("openlayers_OpenLayers_Container");var divs1=no.getElementsByTagName("div");var n1=divs1.length;for(a=0;a<n1;a++){var divs2=divs1[a].getElementsByTagName("div");var n2=divs2.length;for(b=0;b<n2;b++){var imgs=divs2[b].getElementsByTagName("img");var nimg=imgs.length;for(c=0;c<nimg;c++){imgs[c].src+="&x"}}}}i3GEO.janela.fechaAguarde()},cria:function(w,h){var i=$i(i3GEO.interface.IDCORPO);if(i){var f=$i("openlayers");if(!f){var ins='<div id=openlayers style="width:0px;height:0px;text-align:left;background-image:url('+i3GEO.configura.locaplic+'/imagens/i3geo1bw.jpg)"></div>';i.innerHTML=ins}var f=$i("openlayers");f.style.width=w;f.style.height=h}i3GEO.interface.IDMAPA="openlayers"},inicia:function(){var montaMapa=function(){var url=window.location.protocol+"//"+window.location.host+i3GEO.parametros.cgi+"?";url+="map="+i3GEO.parametros.mapfile+"&mode=map&SRS=epsg:4326&";i3geoOL=new OpenLayers.Map('openlayers',{controls:[]});i3geoOLlayer=new OpenLayers.Layer.WMS("Temas I3Geo",url,{layers:'estadosl'},{'buffer':0},{isBaseLayer:true,opacity:1});i3geoOLlayer.setVisibility(true);i3geoOL.addLayer(i3geoOLlayer);i3geoOL.events.register("mousemove",i3geoOL,function(e){if(navm){var p=new OpenLayers.Pixel(e.x,e.y)}else{var p=e.xy}var lonlat=i3geoOL.getLonLatFromViewPortPx(p);var d=i3GEO.calculo.dd2dms(lonlat.lon,lonlat.lat);try{objposicaomouse.x=p.x;objposicaomouse.y=p.y;objposicaocursor.ddx=lonlat.lon;objposicaocursor.ddy=lonlat.lat;objposicaocursor.telax=p.x;objposicaocursor.telay=p.y;var dc=$i("i3geo");if($i("openlayers_OpenLayers_Container")){var dc=$i("openlayers_OpenLayers_Container")}while(dc.offsetParent){dc=dc.offsetParent;objposicaocursor.telax=objposicaocursor.telax+dc.offsetLeft;objposicaocursor.telay=objposicaocursor.telay+dc.offsetTop}}catch(e){}});var pz=new OpenLayers.Control.PanZoomBar({numZoomLevels:5});i3geoOL.addControl(pz);pz.div.style.zIndex=5000;$i("OpenLayers_Control_PanZoom_pandown").style.top=parseInt($i("OpenLayers_Control_PanZoom_pandown").style.top)+5;$i("OpenLayers_Control_PanZoom_panup").style.top=parseInt($i("OpenLayers_Control_PanZoom_panup").style.top)+5;$i("OpenLayers_Control_PanZoom_panleft").style.top=parseInt($i("OpenLayers_Control_PanZoom_panleft").style.top)+5;$i("OpenLayers_Control_PanZoom_panright").style.top=parseInt($i("OpenLayers_Control_PanZoom_panright").style.top)+5;var navc=new OpenLayers.Control.NavToolbar();i3geoOL.addControl(navc);navc.div.style.left="8px";navc.div.style.top="-20px";navc.div.onclick=function(){i3GEO.util.mudaCursor(i3GEO.configura.cursores,"pan","img",i3GEO.configura.locaplic);g_operacao="navega"};zb=new OpenLayers.Control.ZoomToMaxExtent();var botoesadic=new OpenLayers.Control.Panel();botoesadic.addControls([new OpenLayers.Control.ZoomToMaxExtent()]);i3geoOL.addControl(botoesadic);botoesadic.div.style.left="10px";botoesadic.div.style.top=parseInt($i("OpenLayers_Control_PanZoom_zoomout").style.top)+77;i3geoOL.addControl(new OpenLayers.Control.LayerSwitcher());var m=i3GEO.parametros.mapexten.split(" ");var b=new OpenLayers.Bounds(m[0],m[1],m[2],m[3]);i3geoOL.zoomToExtent(b);i3geoOL.addControl(new OpenLayers.Control.Scale("escalanumerica"));i3geoOL.addControl(new OpenLayers.Control.KeyboardDefaults());i3GEO.eventos.ativa($i("openlayers"));var pos=i3GEO.util.pegaPosicaoObjeto($i("openlayers"));if($i("aguarde")){$top("aguarde",pos[1]);$left("aguarde",pos[0])}};i3GEO.php.openlayers(montaMapa)},ativaBotoes:function(){}},googlemaps:{OPACIDADE:0.8,redesenha:function(){if(i3GeoMap!=""){i3GeoMap.removeOverlay(i3GEOTileO);posfixo=posfixo+"&";var i3GEOTile=new GTileLayer(null,0,18,{tileUrlTemplate:i3GEO.interface.googlemaps.criaTile()+posfixo,isPng:true,opacity:i3GEO.interface.googlemaps.OPACIDADE});i3GEOTileO=new GTileLayerOverlay(i3GEOTile);i3GeoMap.addOverlay(i3GEOTileO)}},cria:function(w,h){posfixo="&";var i=$i(i3GEO.interface.IDCORPO);if(i){var f=$i("googlemaps");if(!f){var ins='<div id=googlemaps style="width:0px;height:0px;text-align:left;background-image:url('+i3GEO.configura.locaplic+'/imagens/i3geo1bw.jpg)"></div>';i.innerHTML=ins}var f=$i("googlemaps");f.style.width=w;f.style.height=h}i3GeoMap="";i3GEO.interface.IDMAPA="googlemaps"},inicia:function(){i3GEO.janela.slider("i3GEO.interface.googlemaps.mudaOpacidade","150");var pol=i3GEO.parametros.mapexten;var ret=pol.split(" ");var pt1=(((ret[0]*-1)-(ret[2]*-1))/2)+ret[0]*1;var pt2=(((ret[1]-ret[3])/2)*-1)+ret[1]*1;i3GeoMap=new GMap2($i("googlemaps"));i3GeoMap.setMapType(G_SATELLITE_MAP);i3GeoMap.addControl(new GLargeMapControl());i3GeoMap.addControl(new GMapTypeControl());var bottomLeft=new GControlPosition(G_ANCHOR_BOTTOM_LEFT,new GSize(0,40));i3GeoMap.addControl(new GScaleControl(),bottomLeft);var bottomRight=new GControlPosition(G_ANCHOR_BOTTOM_RIGHT);i3GeoMap.addControl(new GOverviewMapControl(),bottomRight);i3GeoMap.setCenter(new GLatLng(pt2,pt1),4);var i3GEOTile=new GTileLayer(null,0,18,{tileUrlTemplate:i3GEO.interface.googlemaps.criaTile(),isPng:true,opacity:i3GEO.interface.googlemaps.OPACIDADE});i3GEOTileO=new GTileLayerOverlay(i3GEOTile);i3GeoMap.addOverlay(i3GEOTileO);var myMapType=new GMapType([i3GEOTile],new GMercatorProjection(18),'i3Geo');i3GeoMap.addMapType(myMapType);i3GEO.interface.googlemaps.ativaBotoes();i3GEO.eventos.ativa($i("googlemaps"));i3GEO.gadgets.mostraCoordenadasGEO();i3GEO.gadgets.mostraMenuSuspenso();var pos=i3GEO.util.pegaPosicaoObjeto($i("googlemaps"));GEvent.addListener(i3GeoMap,"mousemove",function(ponto){var teladms=i3GEO.calculo.dd2dms(ponto.lng(),ponto.lat());var tela=i3GeoMap.fromLatLngToContainerPixel(ponto);objposicaocursor={ddx:ponto.lng(),ddy:ponto.lat(),dmsx:teladms[0],dmsy:teladms[1],imgx:tela.x,imgy:tela.y,telax:tela.x+pos[0],telay:tela.y+pos[1]}})},bbox:function(){var bd=i3GeoMap.getBounds();var so=bd.getSouthWest();var ne=bd.getNorthEast();var bbox=so.lng()+" "+so.lat()+" "+ne.lng()+" "+ne.lat();return(bbox)},criaWMS:function(){var cgi=i3GEO.configura.locaplic+"/classesphp/parse_cgi.php?g_sid="+i3GEO.configura.sid;var parametros="&map_size="+parseInt($i("googlemaps").style.width);parametros+=","+parseInt($i("googlemaps").style.height);parametros+="&mapext="+i3GEO.interface.googlemaps.bbox();parametros+="&map_imagecolor=-1 -1 -1&map_transparent=on";return(cgi+parametros)},criaTile:function(){var cgi=i3GEO.util.protocolo()+"://"+window.location.host+i3GEO.parametros.cgi+"?";var parametros="map="+i3GEO.parametros.mapfile;parametros+='&mode=tile';parametros+='&tilemode=gmap';parametros+='&tile={X}+{Y}+{Z}';return(cgi+parametros)},ativaBotoes:function(){var imagemxy=i3GEO.util.pegaPosicaoObjeto($i(i3GEO.interface.IDCORPO));if($i("barraDeBotoes2")){var x2=imagemxy[0]+80;var y2=imagemxy[1]+10}if($i("barraDeBotoes2"))i3GEO.barraDeBotoes.inicializaBarra("barraDeBotoes2","i3geo_barra2",false,x2,y2);i3GEO.barraDeBotoes.ativaBotoes()},mudaOpacidade:function(valor){i3GEO.interface.googlemaps.OPACIDADE=valor/200;i3GEO.interface.googlemaps.redesenha()}},googleearth:{redesenha:function(){},cria:function(w,h){var i=$i(i3GEO.interface.IDCORPO);if(i){i3GeoMap=document.createElement("iframe");i3GeoMap.style.width=w;i3GeoMap.style.height=h;i.appendChild(i3GeoMap)}i3GEO.interface.IDMAPA="googleearth"},inicia:function(){i3GeoMap.src="http://www.gmodules.com/ig/ifr?url=http://hosting.gmodules.com/ig/gadgets/file/114026893455619160549/embedkmlgadget.xml&up_kml_url=http%3A%2F%2Fmapas.mma.gov.br%2Fi3geo%2Fpacotes%2Fkmlmapserver%2Fkmlservice.php%3Fmap%3Dbioma%26typename%3Dbioma%26request%3Dkml&up_view_mode=earth&up_earth_2d_fallback=0&up_earth_fly_from_space=1&up_earth_show_buildings=0&synd=open&w=320&h=400&title=Embedded+KML+Viewer&border=%23ffffff%7C3px%2C1px+solid+%23999999&source=http%3A%2F%2Fwww.gmodules.com%2Fig%2Fcreator%3Fsynd%3Dopen%26url%3Dhttp%3A%2F%2Fhosting.gmodules.com%2Fig%2Fgadgets%2Ffile%2F114026893455619160549%2Fembedkmlgadget.xml"},ativaBotoes:function(){}}}; | |
| 2 | 1 | \ No newline at end of file |
| 2 | +if(typeof(i3GEO)=='undefined'){i3GEO=new Array()}i3GEO.interface={ATUAL:"padrao",IDCORPO:"corpoMapa",IDMAPA:"",redesenha:function(){eval("i3GEO.interface."+i3GEO.interface.ATUAL+".redesenha()")},cria:function(w,h){eval("i3GEO.interface."+i3GEO.interface.ATUAL+".cria("+w+","+h+")")},inicia:function(w,h){eval("i3GEO.interface."+i3GEO.interface.ATUAL+".inicia()")},ativaBotoes:function(){eval("i3GEO.interface."+i3GEO.interface.ATUAL+".ativaBotoes()")},padrao:{redesenha:function(){$i("img").onload=function(){$i("img").onload="";i3GEO.gadgets.quadros.grava("imagem",i3GEO.parametros.mapimagem);i3GEO.gadgets.quadros.grava("extensao",i3GEO.parametros.mapexten);var temp=function(retorno){eval(retorno.data);i3GEO.gadgets.quadros.grava("legenda",legimagem)};i3GEO.mapa.legendaIMAGEM.obtem(temp);if($i("imgtemp")){$i("imgtemp").style.display="none"}if($i("imgClone"))$i("imgClone").style.display="none";$i("img").style.display="block";i3GEO.janela.fechaAguarde("ajaxCorpoMapa")};if(!$i("imgtemp")){var ndiv=document.createElement("div");ndiv.id="imgtemp";ndiv.style.position="absolute";ndiv.style.border="1px solid blue";document.getElementById("corpoMapa").appendChild(ndiv)}if(g_tipoacao=="pan"){$i("imgtemp").style.left=parseInt($i("img").style.left);$i("imgtemp").style.top=parseInt($i("img").style.top);$i("imgtemp").style.width=i3GEO.parametros.w;$i("imgtemp").style.height=i3GEO.parametros.h;$i("imgtemp").style.display="block";$i("imgtemp").style.backgroundImage='url("'+$i("img").src+'")'}$i("img").style.left=0;$i("img").style.top=0;$i("img").src=i3GEO.parametros.mapimagem},cria:function(){var ins="<table>";ins+="<tr><td class=verdeclaro ></td><td class=verdeclaro ><input style='display:none;position:relative' type=image src='' id='imgN' /></td><td class=verdeclaro ></td></tr>";ins+="<tr><td class=verdeclaro ><input style='display:none;position:relative' type=image src='' id='imgL' /></td><td class=verdeclaro ><input style='position:relative;top:0px;left:0px'' type=image src='' id='img' /></td><td class=verdeclaro ><input style='display:none;position:relative' type=image src='' id='imgO' /></td></tr>";ins+="<tr><td class=verdeclaro ></td><td class=verdeclaro ><input style='display:none;position:relative' type=image src='' id='imgS' /></td><td class=verdeclaro ></td></tr>";ins+="</table>";$i(i3GEO.interface.IDCORPO).innerHTML=ins;i3GEO.interface.IDMAPA="img"},inicia:function(){if($i("contemImg")){var elemento="contemImg"}else{var elemento="img"}i3GEO.mapa.ajustaPosicao(elemento);var i=$i("img");i.style.width=i3GEO.parametros.w+"px";i.style.height=i3GEO.parametros.h+"px";var estilo=$i(i3GEO.interface.IDCORPO).style;estilo.width=i3GEO.parametros.w+"px";estilo.height=i3GEO.parametros.h+"px";estilo.clip='rect('+0+" "+(i3GEO.parametros.w)+" "+(i3GEO.parametros.h)+" "+0+')';objmapaparado="nao";i3GEO.gadgets.mostraMenuSuspenso();i3GEO.eventos.ativa(i);i3GEO.gadgets.mostraCoordenadasGEO();i3GEO.gadgets.mostraCoordenadasUTM();i3GEO.gadgets.mostraEscalaNumerica();i3GEO.gadgets.mostraEscalaGrafica();i3GEO.gadgets.visual.inicia();i3GEO.idioma.mostraSeletor();i3GEO.ajuda.ativaLetreiro(i3GEO.parametros.mensagens);i3GEO.interface.padrao.ativaBotoes();if(i3GEO.configura.mapaRefDisplay!="none"){if(i3GEO.util.pegaCookie("i3GEO.configura.mapaRefDisplay")){i3GEO.configura.mapaRefDisplay=i3GEO.util.pegaCookie("i3GEO.configura.mapaRefDisplay")}if(i3GEO.configura.mapaRefDisplay=="block"){i3GEO.maparef.inicia()}}},ativaBotoes:function(){var imagemxy=i3GEO.util.pegaPosicaoObjeto($i(i3GEO.interface.IDCORPO));if($i("barraDeBotoes1")){var x1=imagemxy[0]+40;var y1=imagemxy[1]+10}if($i("barraDeBotoes2")){var x2=imagemxy[0];var y2=imagemxy[1]+10}else{if($i("barraDeBotoes1")){var x1=imagemxy[0];var x2=imagemxy[1]+10}}if($i("barraDeBotoes1"))i3GEO.barraDeBotoes.inicializaBarra("barraDeBotoes1","i3geo_barra1",true,x1,y1);if($i("barraDeBotoes2"))i3GEO.barraDeBotoes.inicializaBarra("barraDeBotoes2","i3geo_barra2",false,x2,y2);i3GEO.barraDeBotoes.ativaBotoes();if(document.getElementById("botao3d")){if(i3GEO.configura.map3d==""){document.getElementById("botao3d").style.display="none"}}}},flamingo:{redesenha:function(){var w=parseInt($i("flamingo").style.width);if(w==i3GEO.parametros.w){$i("flamingo").style.height=parseInt($i("flamingo").style.height)+1}else{$i("flamingo").style.height=parseInt($i("flamingo").style.height)-1}i3GEO.janela.fechaAguarde()},cria:function(w,h){var i=$i(i3GEO.interface.IDCORPO);if(i){var f=$i("flamingo");if(!f){var ins='<div id=flamingo style="width:0px;height:0px;text-align:left;background-image:url(/"'+i3GEO.configura.locaplic+'/imagens/i3geo1bw.jpg/")"></div>';i.innerHTML=ins}var f=$i("flamingo");f.style.width=w;f.style.height=h;i3GEO.interface.IDMAPA="flamingo"}},inicia:function(){var monta=function(retorno){$i("flamingo").style.height=i3GEO.parametros.h+45;childPopups=new Array();childPopupNr=0;var so=new SWFObject(i3GEO.configura.locaplic+"/pacotes/flamingo/flamingo/flamingo.swf?config="+retorno.data,"flamingoi","100%","100%","8","#eaeaea");so.addParam("wmode","transparent");so.write("flamingo")}i3GEO.php.flamingo(monta);i3GEO.eventos.ativa($i("flamingo"));i3GEO.maparef.atualiza();if(i3GEO.configura.mapaRefDisplay!="none"){if(i3GEO.util.pegaCookie("i3GEO.configura.mapaRefDisplay")){i3GEO.configura.mapaRefDisplay=i3GEO.util.pegaCookie("i3GEO.configura.mapaRefDisplay")}if(i3GEO.configura.mapaRefDisplay=="block"){i3GEO.maparef.inicia()}}},ativaBotoes:function(){}},openlayers:{redesenha:function(){if($i("openlayers_OpenLayers_Container")){var no=$i("openlayers_OpenLayers_Container");var divs1=no.getElementsByTagName("div");var n1=divs1.length;for(a=0;a<n1;a++){var divs2=divs1[a].getElementsByTagName("div");var n2=divs2.length;for(b=0;b<n2;b++){var imgs=divs2[b].getElementsByTagName("img");var nimg=imgs.length;for(c=0;c<nimg;c++){imgs[c].src+="&x"}}}}i3GEO.janela.fechaAguarde()},cria:function(w,h){var i=$i(i3GEO.interface.IDCORPO);if(i){var f=$i("openlayers");if(!f){var ins='<div id=openlayers style="width:0px;height:0px;text-align:left;background-image:url('+i3GEO.configura.locaplic+'/imagens/i3geo1bw.jpg)"></div>';i.innerHTML=ins}var f=$i("openlayers");f.style.width=w;f.style.height=h}i3GEO.interface.IDMAPA="openlayers"},inicia:function(){var montaMapa=function(){var url=window.location.protocol+"//"+window.location.host+i3GEO.parametros.cgi+"?";url+="map="+i3GEO.parametros.mapfile+"&mode=map&SRS=epsg:4326&";i3geoOL=new OpenLayers.Map('openlayers',{controls:[]});i3geoOLlayer=new OpenLayers.Layer.MapServer("Temas I3Geo",url,{layers:'estadosl'},{'buffer':1},{isBaseLayer:true,opacity:1});i3geoOLlayer.setVisibility(true);i3geoOL.addLayer(i3geoOLlayer);i3geoOL.events.register("mousemove",i3geoOL,function(e){if(navm){var p=new OpenLayers.Pixel(e.x,e.y)}else{var p=e.xy}var lonlat=i3geoOL.getLonLatFromViewPortPx(p);var d=i3GEO.calculo.dd2dms(lonlat.lon,lonlat.lat);try{objposicaomouse.x=p.x;objposicaomouse.y=p.y;objposicaocursor.ddx=lonlat.lon;objposicaocursor.ddy=lonlat.lat;objposicaocursor.telax=p.x;objposicaocursor.telay=p.y;var dc=$i("i3geo");if($i("openlayers_OpenLayers_Container")){var dc=$i("openlayers_OpenLayers_Container")}while(dc.offsetParent){dc=dc.offsetParent;objposicaocursor.telax=objposicaocursor.telax+dc.offsetLeft;objposicaocursor.telay=objposicaocursor.telay+dc.offsetTop}}catch(e){}});var pz=new OpenLayers.Control.PanZoomBar({numZoomLevels:5});i3geoOL.addControl(pz);pz.div.style.zIndex=5000;var navc=new OpenLayers.Control.NavToolbar();i3geoOL.addControl(navc);navc.div.style.left="8px";navc.div.style.top="-20px";navc.div.onclick=function(){i3GEO.util.mudaCursor(i3GEO.configura.cursores,"pan","img",i3GEO.configura.locaplic);g_operacao="navega"};zb=new OpenLayers.Control.ZoomToMaxExtent();var botoesadic=new OpenLayers.Control.Panel();botoesadic.addControls([new OpenLayers.Control.ZoomToMaxExtent()]);i3geoOL.addControl(botoesadic);botoesadic.div.style.left="10px";i3geoOL.addControl(new OpenLayers.Control.LayerSwitcher());var m=i3GEO.parametros.mapexten.split(" ");var b=new OpenLayers.Bounds(m[0],m[1],m[2],m[3]);i3geoOL.zoomToExtent(b);i3geoOL.addControl(new OpenLayers.Control.Scale("escalanumerica"));i3geoOL.addControl(new OpenLayers.Control.KeyboardDefaults());i3GEO.eventos.ativa($i("openlayers"));var pos=i3GEO.util.pegaPosicaoObjeto($i("openlayers"));if($i("aguarde")){$top("aguarde",pos[1]);$left("aguarde",pos[0])}};i3GEO.php.openlayers(montaMapa)},ativaBotoes:function(){}},googlemaps:{OPACIDADE:0.8,redesenha:function(){if(i3GeoMap!=""){posfixo=posfixo+"&";if(tile==false){i3GeoMap.removeOverlay(wmsmap);wmsmap=new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS()+posfixo,i3GeoMap.getBounds());i3GeoMap.addOverlay(wmsmap)}else{i3GeoMap.removeOverlay(i3GEOTileO);var i3GEOTile=new GTileLayer(null,0,18,{tileUrlTemplate:i3GEO.interface.googlemaps.criaTile()+posfixo,isPng:true,opacity:i3GEO.interface.googlemaps.OPACIDADE});i3GEOTileO=new GTileLayerOverlay(i3GEOTile);i3GeoMap.addOverlay(i3GEOTileO)}}},cria:function(w,h){posfixo="&";var i=$i(i3GEO.interface.IDCORPO);if(i){var f=$i("googlemaps");if(!f){var ins='<div id=googlemaps style="width:0px;height:0px;text-align:left;background-image:url('+i3GEO.configura.locaplic+'/imagens/i3geo1bw.jpg)"></div>';i.innerHTML=ins}var f=$i("googlemaps");f.style.width=w;f.style.height=h}i3GeoMap="";i3GEO.interface.IDMAPA="googlemaps"},inicia:function(){tile=false;var ver=i3GEO.parametros.versaomscompleta.split(".");if(parseInt(i3GEO.parametros.versaoms)>=5&&parseInt(ver[1])>1){tile=true}var pol=i3GEO.parametros.mapexten;var ret=pol.split(" ");var pt1=(((ret[0]*-1)-(ret[2]*-1))/2)+ret[0]*1;var pt2=(((ret[1]-ret[3])/2)*-1)+ret[1]*1;i3GeoMap=new GMap2($i("googlemaps"));i3GeoMap.setMapType(G_SATELLITE_MAP);i3GeoMap.addControl(new GLargeMapControl());i3GeoMap.addControl(new GMapTypeControl());var bottomLeft=new GControlPosition(G_ANCHOR_BOTTOM_LEFT,new GSize(0,40));i3GeoMap.addControl(new GScaleControl(),bottomLeft);var bottomRight=new GControlPosition(G_ANCHOR_BOTTOM_RIGHT);i3GeoMap.addControl(new GOverviewMapControl(),bottomRight);i3GeoMap.setCenter(new GLatLng(pt2,pt1),4);if(tile==false){wmsmap=new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(),i3GeoMap.getBounds());i3GeoMap.addOverlay(wmsmap);GEvent.addListener(i3GeoMap,"zoomend",function(){i3GeoMap.removeOverlay(wmsmap);wmsmap=new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(),i3GeoMap.getBounds());i3GeoMap.addOverlay(wmsmap)});GEvent.addListener(i3GeoMap,"dragend",function(){i3GeoMap.removeOverlay(wmsmap);wmsmap=new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(),i3GeoMap.getBounds());i3GeoMap.addOverlay(wmsmap)})}else{i3GEO.janela.slider("i3GEO.interface.googlemaps.mudaOpacidade","150");var i3GEOTile=new GTileLayer(null,0,18,{tileUrlTemplate:i3GEO.interface.googlemaps.criaTile(),isPng:true,opacity:i3GEO.interface.googlemaps.OPACIDADE});i3GEOTileO=new GTileLayerOverlay(i3GEOTile);i3GeoMap.addOverlay(i3GEOTileO);var myMapType=new GMapType([i3GEOTile],new GMercatorProjection(18),'i3Geo');i3GeoMap.addMapType(myMapType)}i3GEO.interface.googlemaps.ativaBotoes();i3GEO.eventos.ativa($i("googlemaps"));i3GEO.gadgets.mostraCoordenadasGEO();i3GEO.gadgets.mostraMenuSuspenso();var pos=i3GEO.util.pegaPosicaoObjeto($i("googlemaps"));GEvent.addListener(i3GeoMap,"mousemove",function(ponto){var teladms=i3GEO.calculo.dd2dms(ponto.lng(),ponto.lat());var tela=i3GeoMap.fromLatLngToContainerPixel(ponto);objposicaocursor={ddx:ponto.lng(),ddy:ponto.lat(),dmsx:teladms[0],dmsy:teladms[1],imgx:tela.x,imgy:tela.y,telax:tela.x+pos[0],telay:tela.y+pos[1]}})},bbox:function(){var bd=i3GeoMap.getBounds();var so=bd.getSouthWest();var ne=bd.getNorthEast();var bbox=so.lng()+" "+so.lat()+" "+ne.lng()+" "+ne.lat();return(bbox)},criaWMS:function(){var cgi=i3GEO.configura.locaplic+"/classesphp/parse_cgi.php?g_sid="+i3GEO.configura.sid;var parametros="&map_size="+parseInt($i("googlemaps").style.width);parametros+=","+parseInt($i("googlemaps").style.height);parametros+="&mapext="+i3GEO.interface.googlemaps.bbox();parametros+="&map_imagecolor=-1 -1 -1&map_transparent=on";return(cgi+parametros)},criaTile:function(){var cgi=i3GEO.util.protocolo()+"://"+window.location.host+i3GEO.parametros.cgi+"?";var parametros="map="+i3GEO.parametros.mapfile;parametros+='&mode=tile';parametros+='&tilemode=gmap';parametros+='&tile={X}+{Y}+{Z}';return(cgi+parametros)},ativaBotoes:function(){var imagemxy=i3GEO.util.pegaPosicaoObjeto($i(i3GEO.interface.IDCORPO));if($i("barraDeBotoes2")){var x2=imagemxy[0]+80;var y2=imagemxy[1]+10}if($i("barraDeBotoes2"))i3GEO.barraDeBotoes.inicializaBarra("barraDeBotoes2","i3geo_barra2",false,x2,y2);i3GEO.barraDeBotoes.ativaBotoes()},mudaOpacidade:function(valor){i3GEO.interface.googlemaps.OPACIDADE=valor/200;i3GEO.interface.googlemaps.redesenha()}},googleearth:{redesenha:function(){},cria:function(w,h){var i=$i(i3GEO.interface.IDCORPO);if(i){i3GeoMap=document.createElement("iframe");i3GeoMap.style.width=w;i3GeoMap.style.height=h;i.appendChild(i3GeoMap)}i3GEO.interface.IDMAPA="googleearth"},inicia:function(){var src="http://www.gmodules.com/ig/ifr?url=http://hosting.gmodules.com/ig/gadgets/file/114026893455619160549/embedkmlgadget.xml&up_kml_url=";var i=i3GEO.configura.locaplic+"/pacotes/kmlmapserver/kmlservice.php?map="+i3GEO.parametros.mapfile+"&typename=estadosl&request=kml&mode=map&";src+=escape(i);src+="&up_view_mode=earth&up_earth_2d_fallback=0&up_earth_fly_from_space=1&up_earth_show_buildings=0&synd=open&w=320&h=400&title=Embedded+KML+Viewer&border=%23ffffff%7C3px%2C1px+solid+%23999999&source=http%3A%2F%2Fwww.gmodules.com%2Fig%2Fcreator%3Fsynd%3Dopen%26url%3Dhttp%3A%2F%2Fhosting.gmodules.com%2Fig%2Fgadgets%2Ffile%2F114026893455619160549%2Fembedkmlgadget.xml";i3GeoMap.src=src},ativaBotoes:function(){}}}; | |
| 3 | 3 | \ No newline at end of file | ... | ... |
classesjs/compactados/classe_janela_compacto.js
| 1 | -if(typeof(i3GEO)=='undefined'){i3GEO=new Array()}i3GEO.janela={TIPS:new Array(),ANTESCRIA:new Array("i3GEO.janela.prepara()"),ANTESFECHA:new Array(),prepara:function(){i3GEO.util.escondePin();i3GEO.util.escondeBox()},cria:function(wlargura,waltura,wsrc,nx,ny,texto,id,modal){if(i3GEO.janela.ANTESCRIA){for(i=0;i<i3GEO.janela.ANTESCRIA.length;i++){eval(i3GEO.janela.ANTESCRIA[i])}}if(arguments.length<7||id==""){var id="wdoca";var modal=false}if(arguments.length==7){var modal=false}var wlargura_=parseInt(wlargura)+0+"px";YAHOO.namespace("janelaDoca.xp");if($i(id)){YAHOO.janelaDoca.xp.panel.destroy()}var ins='<div id="'+id+'_cabecalho" class="hd">'+texto+'</div><div id="'+id+'_corpo" class="bd">';if(wsrc!="")ins+='<iframe name="'+id+'i" id="'+id+'i" valign="top" style="border:0px white solid"></iframe>';ins+='</div>';var novoel=document.createElement("div");novoel.id=id;novoel.style.display="block";novoel.innerHTML=ins;if($i("i3geo")){$i("i3geo").appendChild(novoel)}else{document.body.appendChild(novoel)}var wdocaiframe=$i(id+"i");if(wdocaiframe){with(wdocaiframe.style){width="100%";height=waltura};wdocaiframe.style.display="block";wdocaiframe.src=wsrc}var fix=false;if(nx==""||nx=="center"){var fix=true}if(waltura=="auto")YAHOO.janelaDoca.xp.panel=new YAHOO.widget.Panel(id,{zIndex:5000,modal:modal,width:wlargura_,underlay:"none",fixedcenter:fix,constraintoviewport:false,visible:true,iframe:false});else YAHOO.janelaDoca.xp.panel=new YAHOO.widget.ResizePanel(id,{zIndex:5000,modal:modal,width:wlargura_,fixedcenter:fix,constraintoviewport:false,visible:true,iframe:false});if(nx!=""&&nx!="center"){var pos=new Array(nx,ny);YAHOO.janelaDoca.xp.panel.moveTo(pos[0],pos[1]+50)}YAHOO.janelaDoca.xp.panel.render();YAHOO.util.Event.addListener(YAHOO.janelaDoca.xp.panel.close,"click",i3GEO.janela.fecha,id);return(new Array(YAHOO.janelaDoca.xp.panel,$i(id+"_cabecalho"),$i(id+"_corpo")))},fecha:function(r,id){i3GEO.util.escondePin();i3GEO.util.escondeBox();if($i("divGeometriasTemp")){i3GEO.desenho.richdraw.fecha()}if($i("flamingoi")){$i("flamingoi").style.display="block"}if(i3GEO.janela.ANTESFECHA){for(i=0;i<i3GEO.janela.ANTESFECHA.length;i++){eval(i3GEO.janela.ANTESFECHA[i])}}document.body.removeChild($i(id+"_c"))},alteraTamanho:function(w,h,id){if(arguments.length==3){var i=$i(id)}else{var i=$i("wdoca")}if(i){i.style.width=w;i.style.height=h}},abreAguarde:function(id,texto){if($i(id+"_mask")){document.body.removeChild($i(id+"_mask"))}if($i(id+"_c")){document.body.removeChild($i(id+"_c"))}YAHOO.namespace("aguarde."+id);var pos=[0,0];if($i("corpoMapa")){var pos=YAHOO.util.Dom.getXY($i("corpoMapa"))}else if($i("contemImg")){var pos=YAHOO.util.Dom.getXY($i("contemImg"))}eval('YAHOO.aguarde.'+id+' = new YAHOO.widget.Panel("'+id+'",{width:"240px",fixedcenter:false,underlay:"none",close:true,draggable:false,modal:true})');eval('YAHOO.aguarde.'+id+'.setBody("<span style=font-size:12px; >"+texto+"</span>")');eval('YAHOO.aguarde.'+id+'.body.style.height="20px"');eval('YAHOO.aguarde.'+id+'.setHeader("<span><img src=\'"+i3GEO.configura.locaplic+"/imagens/aguarde.gif\' /></span>")');eval('YAHOO.aguarde.'+id+'.render(document.body)');if($i("flamingo")){eval('YAHOO.aguarde.'+id+'.moveTo(0,0)')}else{eval('YAHOO.aguarde.'+id+'.moveTo('+pos[0]+','+pos[1]+')')}eval('YAHOO.aguarde.'+id+'.show()');if($i(id+"_mask")){$i(id+"_mask").style.zIndex=5000}if($i(id+"_c")){$i(id+"_c").style.zIndex=6000}},tip:function(cabecalho){if(arguments.length==0){var cabecalho="fixar"}var Nid=YAHOO.util.Dom.generateId();var i=$i("i3geo_rosa");if(i)i.style.display="none";if($i("img")){$i("img").title=""}var novoel=document.createElement("div");novoel.id=Nid;novoel.style.position="absolute";novoel.style.zIndex=5000;novoel.style.textAlign="left";novoel.style.background="white";if(navm){novoel.style.filter="alpha(opacity=90)"}else{novoel.style.opacity=".9"}document.body.appendChild(novoel);i3GEO.janela.TIPS.push($i(Nid));var res="<div id='"+Nid+"cabecatip' style='text-align:left;background-color:rgb(240,240,240)'>";res+="<span style='color:navy;cursor:pointer;text-align:left' onclick='javascript:$i(\""+Nid+"cabecatip\").innerHTML =\"\";' >"+cabecalho+"</span></div>";novoel.innerHTML="<table style='text-align:left'><tr><td style='text-align:left'>"+res+"</td></tr></table>";ist=novoel.style;ist.top=objposicaocursor.telay-10;ist.left=objposicaocursor.telax-4;ist.display="block";if(i3GEO.eventos.NAVEGAMAPA.toString().search("i3GEO.janela.excluiTips('todos')")<0){i3GEO.eventos.NAVEGAMAPA.push("i3GEO.janela.excluiTips('todos')")}if(i3GEO.eventos.MOUSEMOVE.toString().search("i3GEO.janela.excluiTips('naofixos')")<0){i3GEO.eventos.MOUSEMOVE.push("i3GEO.janela.excluiTips('naofixos')")}return(Nid)},excluiTips:function(tipo){if(i3GEO.janela.TIPS.length>0){var ot=i3GEO.janela.TIPS.length-1;if(ot>=0){do{if(tipo=='todos'){if(i3GEO.janela.TIPS[ot]){var i=$i(i3GEO.janela.TIPS[ot].id);document.body.removeChild(i)}}if(tipo=='naofixos'){if($i(i3GEO.janela.TIPS[ot])){if($i(i3GEO.janela.TIPS[ot].id+"cabecatip").innerHTML!=""){document.body.removeChild($i(i3GEO.janela.TIPS[ot].id))}}}}while(ot--)if(tipo=="todos"){i3GEO.janela.TIPS=new Array()}}}},slider:function(funcao,inicial){var janela=i3GEO.janela.cria(230,200,"","","","Opacidade","opacidadeG");var novoel=document.createElement("div");novoel.id="slider-bg";novoel.tabindex="-1";novoel.innerHTML='<div style="cursor:default;position:absolute;top:4px" id="slider-thumb"><img src="'+i3GEO.configura.locaplic+'/imagens/thumb-n.gif"></div>';janela[2].appendChild(novoel);var Event=YAHOO.util.Event;var Dom=YAHOO.util.Dom;var lang=YAHOO.lang;var slider;var bg="slider-bg";var thumb="slider-thumb";var valuearea="slider-value";var textfield="slider-converted-value";novoel.style.position="relative";novoel.style.background='url('+i3GEO.configura.locaplic+'/imagens/bg-fader.gif) 5px 0 no-repeat';novoel.style.height="28px";novoel.style.width="228px";var topConstraint=0;var bottomConstraint=200;var scaleFactor=1;var keyIncrement=20;var tickSize=20;Event.onDOMReady(function(){slider=YAHOO.widget.Slider.getHorizSlider(bg,thumb,topConstraint,bottomConstraint,20);slider.setValue(parseInt(inicial));slider.getRealValue=function(){return Math.round(this.getValue()*scaleFactor)}slider.subscribe("slideEnd",function(offsetFromStart){var actualValue=slider.getRealValue();eval(funcao+"("+actualValue+")")})});Event.on("putval","click",function(e){slider.setValue(100,false)})},fechaAguarde:function(id){if(arguments.length>0){try{eval('YAHOO.aguarde.'+id+'.destroy()')}catch(e){}}else{i3GEO.janela.fechaAguarde("ajaxdestaca");i3GEO.janela.fechaAguarde("ajaxabrelente");i3GEO.janela.fechaAguarde("ajaxiniciaParametros");i3GEO.janela.fechaAguarde("i3GEO.atualiza");i3GEO.janela.fechaAguarde("ajaxCorpoMapaEntorno");i3GEO.janela.fechaAguarde("ajaxCorpoMapa");i3GEO.janela.fechaAguarde("ajaxLegenda");i3GEO.janela.fechaAguarde("ajaxReferencia");i3GEO.janela.fechaAguarde("ajaxEscalaGrafica");i3GEO.janela.fechaAguarde("montaMapa");i3GEO.janela.fechaAguarde("aguardedoc");i3GEO.janela.fechaAguarde("ajaxCorpoMapa1")}}};try{YAHOO.widget.ResizePanel=function(el,userConfig){if(arguments.length>0){YAHOO.widget.ResizePanel.superclass.constructor.call(this,el,userConfig)}};YAHOO.widget.ResizePanel.CSS_PANEL_RESIZE="yui-resizepanel";YAHOO.widget.ResizePanel.CSS_RESIZE_HANDLE="resizehandle";YAHOO.extend(YAHOO.widget.ResizePanel,YAHOO.widget.Panel,{init:function(el,userConfig){YAHOO.widget.ResizePanel.superclass.init.call(this,el);this.beforeInitEvent.fire(YAHOO.widget.ResizePanel);var Dom=YAHOO.util.Dom,Event=YAHOO.util.Event,oInnerElement=this.innerElement,oResizeHandle=document.createElement("DIV"),sResizeHandleId=this.id+"_resizehandle";oResizeHandle.id=sResizeHandleId;oResizeHandle.className=YAHOO.widget.ResizePanel.CSS_RESIZE_HANDLE;Dom.addClass(oInnerElement,YAHOO.widget.ResizePanel.CSS_PANEL_RESIZE);this.resizeHandle=oResizeHandle;function initResizeFunctionality(){var me=this,oHeader=this.header,oBody=this.body,oFooter=this.footer,nStartWidth,nStartHeight,aStartPos,nBodyBorderTopWidth,nBodyBorderBottomWidth,nBodyTopPadding,nBodyBottomPadding,nBodyOffset;oInnerElement.appendChild(oResizeHandle);this.ddResize=new YAHOO.util.DragDrop(sResizeHandleId,this.id);this.ddResize.setHandleElId(sResizeHandleId);this.ddResize.onMouseDown=function(e){nStartWidth=oInnerElement.offsetWidth;nStartHeight=oInnerElement.offsetHeight;if(YAHOO.env.ua.ie&&document.compatMode=="BackCompat"){nBodyOffset=0}else{nBodyBorderTopWidth=parseInt(Dom.getStyle(oBody,"borderTopWidth"),10);nBodyBorderBottomWidth=parseInt(Dom.getStyle(oBody,"borderBottomWidth"),10);nBodyTopPadding=parseInt(Dom.getStyle(oBody,"paddingTop"),10);nBodyBottomPadding=parseInt(Dom.getStyle(oBody,"paddingBottom"),10);nBodyOffset=nBodyBorderTopWidth+nBodyBorderBottomWidth+nBodyTopPadding+nBodyBottomPadding}me.cfg.setProperty("width",nStartWidth+"px");aStartPos=[Event.getPageX(e),Event.getPageY(e)]};this.ddResize.onDrag=function(e){var aNewPos=[Event.getPageX(e),Event.getPageY(e)],nOffsetX=aNewPos[0]-aStartPos[0],nOffsetY=aNewPos[1]-aStartPos[1],nNewWidth=Math.max(nStartWidth+nOffsetX,10),nNewHeight=Math.max(nStartHeight+nOffsetY,10),nBodyHeight=(nNewHeight-(oFooter.offsetHeight+oHeader.offsetHeight+nBodyOffset));me.cfg.setProperty("width",nNewWidth+"px");if(nBodyHeight<0){nBodyHeight=0}oBody.style.height=nBodyHeight+"px";if($i("wdocai")){$i("wdocai").style.height=nBodyHeight}}};function onBeforeShow(){initResizeFunctionality.call(this);this.unsubscribe("beforeShow",onBeforeShow)};function onBeforeRender(){if(!this.footer){this.setFooter("")}if(this.cfg.getProperty("visible")){initResizeFunctionality.call(this)}else{this.subscribe("beforeShow",onBeforeShow)}this.unsubscribe("beforeRender",onBeforeRender)};this.subscribe("beforeRender",onBeforeRender);if(userConfig){this.cfg.applyConfig(userConfig,true)}this.initEvent.fire(YAHOO.widget.ResizePanel)},toString:function(){return"ResizePanel "+this.id}})}catch(e){}; | |
| 2 | 1 | \ No newline at end of file |
| 2 | +if(typeof(i3GEO)=='undefined'){i3GEO=new Array()}i3GEO.janela={TIPS:new Array(),ANTESCRIA:new Array("i3GEO.janela.prepara()"),ANTESFECHA:new Array(),prepara:function(){i3GEO.util.escondePin();i3GEO.util.escondeBox()},cria:function(wlargura,waltura,wsrc,nx,ny,texto,id,modal){if(i3GEO.janela.ANTESCRIA){for(i=0;i<i3GEO.janela.ANTESCRIA.length;i++){eval(i3GEO.janela.ANTESCRIA[i])}}if(arguments.length<7||id==""){var id="wdoca";var modal=false}if(arguments.length==7){var modal=false}var wlargura_=parseInt(wlargura)+0+"px";YAHOO.namespace("janelaDoca.xp");if($i(id)){YAHOO.janelaDoca.xp.panel.destroy()}var ins='<div id="'+id+'_cabecalho" class="hd">'+texto+'</div><div id="'+id+'_corpo" class="bd">';if(wsrc!="")ins+='<iframe name="'+id+'i" id="'+id+'i" valign="top" style="border:0px white solid"></iframe>';ins+='</div>';var novoel=document.createElement("div");novoel.id=id;novoel.style.display="block";novoel.innerHTML=ins;if($i("i3geo")){$i("i3geo").appendChild(novoel)}else{document.body.appendChild(novoel)}var wdocaiframe=$i(id+"i");if(wdocaiframe){with(wdocaiframe.style){width="100%";height=waltura};wdocaiframe.style.display="block";wdocaiframe.src=wsrc}var fix=false;if(nx==""||nx=="center"){var fix=true}if(waltura=="auto")YAHOO.janelaDoca.xp.panel=new YAHOO.widget.Panel(id,{zIndex:5000,modal:modal,width:wlargura_,underlay:"none",fixedcenter:fix,constraintoviewport:false,visible:true,iframe:false});else YAHOO.janelaDoca.xp.panel=new YAHOO.widget.ResizePanel(id,{zIndex:5000,modal:modal,width:wlargura_,fixedcenter:fix,constraintoviewport:false,visible:true,iframe:false});if(nx!=""&&nx!="center"){var pos=new Array(nx,ny);YAHOO.janelaDoca.xp.panel.moveTo(pos[0],pos[1]+50)}YAHOO.janelaDoca.xp.panel.render();YAHOO.util.Event.addListener(YAHOO.janelaDoca.xp.panel.close,"click",i3GEO.janela.fecha,id);return(new Array(YAHOO.janelaDoca.xp.panel,$i(id+"_cabecalho"),$i(id+"_corpo")))},fecha:function(r,id){i3GEO.util.escondePin();i3GEO.util.escondeBox();if($i("divGeometriasTemp")){i3GEO.desenho.richdraw.fecha()}if($i("flamingoi")){$i("flamingoi").style.display="block"}if(i3GEO.janela.ANTESFECHA){for(i=0;i<i3GEO.janela.ANTESFECHA.length;i++){eval(i3GEO.janela.ANTESFECHA[i])}}document.body.removeChild($i(id+"_c"))},alteraTamanho:function(w,h,id){if(arguments.length==3){var i=$i(id)}else{var i=$i("wdoca")}if(i){i.style.width=w;i.style.height=h}},abreAguarde:function(id,texto){if($i(id+"_mask")){document.body.removeChild($i(id+"_mask"))}if($i(id+"_c")){document.body.removeChild($i(id+"_c"))}YAHOO.namespace("aguarde."+id);var pos=[0,0];if($i("corpoMapa")){var pos=YAHOO.util.Dom.getXY($i("corpoMapa"))}else if($i("contemImg")){var pos=YAHOO.util.Dom.getXY($i("contemImg"))}eval('YAHOO.aguarde.'+id+' = new YAHOO.widget.Panel("'+id+'",{width:"240px",fixedcenter:false,underlay:"none",close:true,draggable:false,modal:true})');eval('YAHOO.aguarde.'+id+'.setBody("<span style=font-size:12px; >"+texto+"</span>")');eval('YAHOO.aguarde.'+id+'.body.style.height="20px"');eval('YAHOO.aguarde.'+id+'.setHeader("<span><img src=\'"+i3GEO.configura.locaplic+"/imagens/aguarde.gif\' /></span>")');eval('YAHOO.aguarde.'+id+'.render(document.body)');if($i("flamingo")){eval('YAHOO.aguarde.'+id+'.moveTo(0,0)')}else{eval('YAHOO.aguarde.'+id+'.moveTo('+pos[0]+','+pos[1]+')')}eval('YAHOO.aguarde.'+id+'.show()');if($i(id+"_mask")){$i(id+"_mask").style.zIndex=5000}if($i(id+"_c")){$i(id+"_c").style.zIndex=6000}},tip:function(cabecalho){if(arguments.length==0){var cabecalho="fixar"}var Nid=YAHOO.util.Dom.generateId();var i=$i("i3geo_rosa");if(i)i.style.display="none";if($i("img")){$i("img").title=""}var novoel=document.createElement("div");novoel.id=Nid;novoel.style.position="absolute";novoel.style.zIndex=5000;novoel.style.textAlign="left";novoel.style.background="white";if(navm){novoel.style.filter="alpha(opacity=90)"}else{novoel.style.opacity=".9"}document.body.appendChild(novoel);i3GEO.janela.TIPS.push($i(Nid));var res="<div id='"+Nid+"cabecatip' style='text-align:left;background-color:rgb(240,240,240)'>";res+="<span style='color:navy;cursor:pointer;text-align:left' onclick='javascript:$i(\""+Nid+"cabecatip\").innerHTML =\"\";' >"+cabecalho+"</span></div>";novoel.innerHTML="<table style='text-align:left'><tr><td style='text-align:left'>"+res+"</td></tr></table>";ist=novoel.style;ist.top=objposicaocursor.telay-10;ist.left=objposicaocursor.telax-4;ist.display="block";if(i3GEO.eventos.NAVEGAMAPA.toString().search("i3GEO.janela.excluiTips('todos')")<0){i3GEO.eventos.NAVEGAMAPA.push("i3GEO.janela.excluiTips('todos')")}if(i3GEO.eventos.MOUSEMOVE.toString().search("i3GEO.janela.excluiTips('naofixos')")<0){i3GEO.eventos.MOUSEMOVE.push("i3GEO.janela.excluiTips('naofixos')")}return(Nid)},excluiTips:function(tipo){if(i3GEO.janela.TIPS.length>0){var ot=i3GEO.janela.TIPS.length-1;if(ot>=0){do{if(tipo=='todos'){if(i3GEO.janela.TIPS[ot]){var i=$i(i3GEO.janela.TIPS[ot].id);document.body.removeChild(i)}}if(tipo=='naofixos'){if($i(i3GEO.janela.TIPS[ot])){if($i(i3GEO.janela.TIPS[ot].id+"cabecatip").innerHTML!=""){document.body.removeChild($i(i3GEO.janela.TIPS[ot].id))}}}}while(ot--)if(tipo=="todos"){i3GEO.janela.TIPS=new Array()}}}},slider:function(funcao,inicial){var janela=i3GEO.janela.cria(230,200,"","","","Opacidade","opacidadeG");var novoel=document.createElement("div");novoel.id="slider-bg";novoel.tabindex="-1";novoel.innerHTML='<div style="cursor:default;position:absolute;top:4px" id="slider-thumb"><img src="'+i3GEO.configura.locaplic+'/imagens/thumb-n.gif"></div>';janela[2].appendChild(novoel);var Event=YAHOO.util.Event;var Dom=YAHOO.util.Dom;var lang=YAHOO.lang;var slider;var bg="slider-bg";var thumb="slider-thumb";var valuearea="slider-value";var textfield="slider-converted-value";novoel.style.position="relative";novoel.style.background='url('+i3GEO.configura.locaplic+'/imagens/bg-fader.gif) 5px 0 no-repeat';novoel.style.height="28px";novoel.style.width="228px";var topConstraint=0;var bottomConstraint=200;var scaleFactor=1;var keyIncrement=20;var tickSize=20;Event.onDOMReady(function(){slider=YAHOO.widget.Slider.getHorizSlider(bg,thumb,topConstraint,bottomConstraint,20);slider.setValue(parseInt(inicial));slider.getRealValue=function(){return Math.round(this.getValue()*scaleFactor)}slider.subscribe("slideEnd",function(offsetFromStart){var actualValue=slider.getRealValue();eval(funcao+"("+actualValue+")")})});Event.on("putval","click",function(e){slider.setValue(100,false)})},fechaAguarde:function(id){if(arguments.length>0){try{eval('YAHOO.aguarde.'+id+'.destroy()')}catch(e){}}else{try{i3GEO.janela.fechaAguarde("ajaxdestaca");i3GEO.janela.fechaAguarde("ajaxabrelente");i3GEO.janela.fechaAguarde("ajaxiniciaParametros");i3GEO.janela.fechaAguarde("i3GEO.atualiza");i3GEO.janela.fechaAguarde("ajaxCorpoMapaEntorno");i3GEO.janela.fechaAguarde("ajaxCorpoMapa");i3GEO.janela.fechaAguarde("ajaxLegenda");i3GEO.janela.fechaAguarde("ajaxReferencia");i3GEO.janela.fechaAguarde("ajaxEscalaGrafica");i3GEO.janela.fechaAguarde("montaMapa");i3GEO.janela.fechaAguarde("aguardedoc");i3GEO.janela.fechaAguarde("ajaxCorpoMapa1")}catch(e){}}}};try{YAHOO.widget.ResizePanel=function(el,userConfig){if(arguments.length>0){YAHOO.widget.ResizePanel.superclass.constructor.call(this,el,userConfig)}};YAHOO.widget.ResizePanel.CSS_PANEL_RESIZE="yui-resizepanel";YAHOO.widget.ResizePanel.CSS_RESIZE_HANDLE="resizehandle";YAHOO.extend(YAHOO.widget.ResizePanel,YAHOO.widget.Panel,{init:function(el,userConfig){YAHOO.widget.ResizePanel.superclass.init.call(this,el);this.beforeInitEvent.fire(YAHOO.widget.ResizePanel);var Dom=YAHOO.util.Dom,Event=YAHOO.util.Event,oInnerElement=this.innerElement,oResizeHandle=document.createElement("DIV"),sResizeHandleId=this.id+"_resizehandle";oResizeHandle.id=sResizeHandleId;oResizeHandle.className=YAHOO.widget.ResizePanel.CSS_RESIZE_HANDLE;Dom.addClass(oInnerElement,YAHOO.widget.ResizePanel.CSS_PANEL_RESIZE);this.resizeHandle=oResizeHandle;function initResizeFunctionality(){var me=this,oHeader=this.header,oBody=this.body,oFooter=this.footer,nStartWidth,nStartHeight,aStartPos,nBodyBorderTopWidth,nBodyBorderBottomWidth,nBodyTopPadding,nBodyBottomPadding,nBodyOffset;oInnerElement.appendChild(oResizeHandle);this.ddResize=new YAHOO.util.DragDrop(sResizeHandleId,this.id);this.ddResize.setHandleElId(sResizeHandleId);this.ddResize.onMouseDown=function(e){nStartWidth=oInnerElement.offsetWidth;nStartHeight=oInnerElement.offsetHeight;if(YAHOO.env.ua.ie&&document.compatMode=="BackCompat"){nBodyOffset=0}else{nBodyBorderTopWidth=parseInt(Dom.getStyle(oBody,"borderTopWidth"),10);nBodyBorderBottomWidth=parseInt(Dom.getStyle(oBody,"borderBottomWidth"),10);nBodyTopPadding=parseInt(Dom.getStyle(oBody,"paddingTop"),10);nBodyBottomPadding=parseInt(Dom.getStyle(oBody,"paddingBottom"),10);nBodyOffset=nBodyBorderTopWidth+nBodyBorderBottomWidth+nBodyTopPadding+nBodyBottomPadding}me.cfg.setProperty("width",nStartWidth+"px");aStartPos=[Event.getPageX(e),Event.getPageY(e)]};this.ddResize.onDrag=function(e){var aNewPos=[Event.getPageX(e),Event.getPageY(e)],nOffsetX=aNewPos[0]-aStartPos[0],nOffsetY=aNewPos[1]-aStartPos[1],nNewWidth=Math.max(nStartWidth+nOffsetX,10),nNewHeight=Math.max(nStartHeight+nOffsetY,10),nBodyHeight=(nNewHeight-(oFooter.offsetHeight+oHeader.offsetHeight+nBodyOffset));me.cfg.setProperty("width",nNewWidth+"px");if(nBodyHeight<0){nBodyHeight=0}oBody.style.height=nBodyHeight+"px";if($i("wdocai")){$i("wdocai").style.height=nBodyHeight}}};function onBeforeShow(){initResizeFunctionality.call(this);this.unsubscribe("beforeShow",onBeforeShow)};function onBeforeRender(){if(!this.footer){this.setFooter("")}if(this.cfg.getProperty("visible")){initResizeFunctionality.call(this)}else{this.subscribe("beforeShow",onBeforeShow)}this.unsubscribe("beforeRender",onBeforeRender)};this.subscribe("beforeRender",onBeforeRender);if(userConfig){this.cfg.applyConfig(userConfig,true)}this.initEvent.fire(YAHOO.widget.ResizePanel)},toString:function(){return"ResizePanel "+this.id}})}catch(e){}; | |
| 3 | 3 | \ No newline at end of file | ... | ... |
classesjs/i3geo_tudo_compacto.js
| ... | ... | @@ -3744,7 +3744,7 @@ Balloon.prototype.isKonqueror = function() { |
| 3744 | 3744 | } |
| 3745 | 3745 | |
| 3746 | 3746 | /* |
| 3747 | -Title: I3Geo | |
| 3747 | +Title: i3Geo | |
| 3748 | 3748 | |
| 3749 | 3749 | File: i3geo/classesjs/classe_i3geo.js |
| 3750 | 3750 | |
| ... | ... | @@ -3788,7 +3788,14 @@ i3GEO = { |
| 3788 | 3788 | /* |
| 3789 | 3789 | Variable: parametros |
| 3790 | 3790 | |
| 3791 | - Parâmetros obtidos do mapa atual | |
| 3791 | + Parâmetros obtidos do mapa atual. Os parâmetros são fornecidos pelos programas | |
| 3792 | + PHP de redesenho e criação do mapa e atualizados sempre que o mapa é alterado. | |
| 3793 | + | |
| 3794 | + Exemplos: | |
| 3795 | + | |
| 3796 | + Para acessar um valor, utilize por exemplo | |
| 3797 | + | |
| 3798 | + alert(i3GEO.parametros.mapexten) | |
| 3792 | 3799 | |
| 3793 | 3800 | Parameters: |
| 3794 | 3801 | |
| ... | ... | @@ -3808,13 +3815,15 @@ i3GEO = { |
| 3808 | 3815 | |
| 3809 | 3816 | mapimagem {String} - URL da imagem que compõe o mapa |
| 3810 | 3817 | |
| 3811 | - geoip {sim|nao} - indica se o geoip está instalado, podendo ou não ser utilizado | |
| 3818 | + geoip {sim|nao} - indica se o geoip está instalado | |
| 3812 | 3819 | |
| 3813 | 3820 | listavisual {String} - lista de visuais disponíveis |
| 3814 | 3821 | |
| 3815 | 3822 | utilizacgi {sim|nao} - indica se o mapa atual está no modo CGI |
| 3816 | 3823 | |
| 3817 | - versaoms {String} - versão do Mapserver instalado no servidor | |
| 3824 | + versaoms {String} - versão do Mapserver instalado no servidor (maior) | |
| 3825 | + | |
| 3826 | + versaomscompleta {String} - versão do Mapserver instalado no servidor (completa) | |
| 3818 | 3827 | |
| 3819 | 3828 | mensagens {String} - mensagens para uso no letreiro |
| 3820 | 3829 | |
| ... | ... | @@ -3847,6 +3856,7 @@ i3GEO = { |
| 3847 | 3856 | listavisual: "", |
| 3848 | 3857 | utilizacgi:"", |
| 3849 | 3858 | versaoms:"", |
| 3859 | + versaomscompleta: "", | |
| 3850 | 3860 | mensagens:"", |
| 3851 | 3861 | w: "", |
| 3852 | 3862 | h: "", |
| ... | ... | @@ -3865,7 +3875,28 @@ i3GEO = { |
| 3865 | 3875 | para outra, os menus reflitam a última escolha |
| 3866 | 3876 | */ |
| 3867 | 3877 | temaAtivo: "", |
| 3878 | + /* | |
| 3879 | + Function: cria | |
| 3880 | + | |
| 3881 | + Cria e configura a visualização do mapa, definindo posicionamentos, tamanho etc | |
| 3882 | + | |
| 3883 | + Após as definições básicas, é executado o programa <i3GEO.interface.cria> que irá | |
| 3884 | + realizar as operações conforme a interface atualmente em uso. A interface é definida | |
| 3885 | + em <i3GEO.interface.ATUAL> | |
| 3886 | + | |
| 3887 | + <i3GEO.interface> | |
| 3888 | + */ | |
| 3868 | 3889 | cria:function(){ |
| 3890 | + if (window.location.href.split("?")[1]){ | |
| 3891 | + i3GEO.configura.sid = window.location.href.split("?")[1]; | |
| 3892 | + // | |
| 3893 | + //a biblioteca YUI, por algum motivo, acrescenta # na URL. O # precisa ser removido, caso contrário, a opção de reload da página pelo browser as vezes não funciona | |
| 3894 | + // | |
| 3895 | + if (i3GEO.configura.sid.split("#")[0]) | |
| 3896 | + {i3GEO.configura.sid = i3GEO.configura.sid.split("#")[0];} | |
| 3897 | + } | |
| 3898 | + else | |
| 3899 | + {i3GEO.configura.sid = "";} | |
| 3869 | 3900 | //para efeitos de compatibilidade |
| 3870 | 3901 | g_panM = "nao"; |
| 3871 | 3902 | try {i3GEO.configura.locaplic = g_locaplic;} |
| ... | ... | @@ -3933,6 +3964,7 @@ i3GEO = { |
| 3933 | 3964 | listavisual: "", |
| 3934 | 3965 | utilizacgi:"", |
| 3935 | 3966 | versaoms:"", |
| 3967 | + versaomscompleta:"", | |
| 3936 | 3968 | mensagens:"", |
| 3937 | 3969 | w: w, |
| 3938 | 3970 | h: h, |
| ... | ... | @@ -3943,6 +3975,22 @@ i3GEO = { |
| 3943 | 3975 | extentref:"" |
| 3944 | 3976 | }; |
| 3945 | 3977 | }, |
| 3978 | + /* | |
| 3979 | + Function: inicia | |
| 3980 | + | |
| 3981 | + Inicializa o mapa após ter sido criado com i3GEO.cria() | |
| 3982 | + | |
| 3983 | + Verifica se o mapa apresenta algum problema no processamento no lado do servidor e | |
| 3984 | + realiza as operações de tentativa de recuperação, se for o caso | |
| 3985 | + | |
| 3986 | + No início do processo é executada a função <i3GEOmantemCompatibilidade> | |
| 3987 | + para realizar as operações necessárias de manutenção de compatibilidade da versão atual para as anteriores | |
| 3988 | + | |
| 3989 | + A inicialização é baseada em <i3GEO.php.inicia> cujo retorno é utilizado para definir a | |
| 3990 | + variável <i3GEO.parametrso> | |
| 3991 | + | |
| 3992 | + Após a inicialização é executado <i3GEO.interface.inicia> | |
| 3993 | + */ | |
| 3946 | 3994 | inicia:function(){ |
| 3947 | 3995 | if(typeof("i3GEOmantemCompatibilidade") == 'function') |
| 3948 | 3996 | i3GEOmantemCompatibilidade(); |
| ... | ... | @@ -3988,6 +4036,8 @@ i3GEO = { |
| 3988 | 4036 | i3GEO.parametros.r = r; |
| 3989 | 4037 | i3GEO.parametros.locmapas = locmapas; |
| 3990 | 4038 | i3GEO.parametros.extentref = extentref; |
| 4039 | + i3GEO.parametros.versaoms = versaoms; | |
| 4040 | + i3GEO.parametros.versaomscompleta = versaomscompleta; | |
| 3991 | 4041 | i3GEO.gadgets.quadros.inicia(10); |
| 3992 | 4042 | i3GEO.gadgets.quadros.grava("extensao",mapexten); |
| 3993 | 4043 | i3GEO.arvoreDeCamadas.cria("",retorno.data.temas,i3GEO.configura.sid,i3GEO.configura.locaplic); |
| ... | ... | @@ -4067,11 +4117,22 @@ i3GEO = { |
| 4067 | 4117 | {i3GEO.eventos.NAVEGAMAPA.push("i3GEO.janela.fechaAguarde()");} |
| 4068 | 4118 | }, |
| 4069 | 4119 | finaliza:"", |
| 4070 | - | |
| 4071 | 4120 | /* |
| 4072 | 4121 | Function: atualiza |
| 4073 | 4122 | |
| 4074 | - Atualiza o mapa atual, alterando a imagem do mapa e os gadgets ativos | |
| 4123 | + Atualiza o mapa atual, alterando a imagem do mapa os gadgets ativos e os parâmetros e | |
| 4124 | + verifica a integridade do mapa em uso (arquivo mapfile) | |
| 4125 | + | |
| 4126 | + O processo executa também a função de atualização específica da interface atual em uso, veja | |
| 4127 | + <i3GEO.interface.redesenha> | |
| 4128 | + | |
| 4129 | + Os seguintes gadgets são processados | |
| 4130 | + | |
| 4131 | + <i3GEO.arvoreDeCamadas.atualiza> | |
| 4132 | + | |
| 4133 | + <i3GEO.arvoreDeCamadas.atualizaFarol> | |
| 4134 | + | |
| 4135 | + Os eventos definidos em <i3GEO.eventos.navegaMapa> são executados | |
| 4075 | 4136 | |
| 4076 | 4137 | Parameters: |
| 4077 | 4138 | |
| ... | ... | @@ -10285,7 +10346,7 @@ i3GEO.interface = { |
| 10285 | 10346 | var url = window.location.protocol+"//"+window.location.host+i3GEO.parametros.cgi+"?"; |
| 10286 | 10347 | url += "map="+i3GEO.parametros.mapfile+"&mode=map&SRS=epsg:4326&"; |
| 10287 | 10348 | i3geoOL = new OpenLayers.Map('openlayers', { controls: [] }); |
| 10288 | - i3geoOLlayer = new OpenLayers.Layer.WMS( "Temas I3Geo", url,{layers:'estadosl'},{'buffer':0},{isBaseLayer:true, opacity: 1}); | |
| 10349 | + i3geoOLlayer = new OpenLayers.Layer.MapServer( "Temas I3Geo", url,{layers:'estadosl'},{'buffer':1},{isBaseLayer:true, opacity: 1}); | |
| 10289 | 10350 | i3geoOLlayer.setVisibility(true); |
| 10290 | 10351 | i3geoOL.addLayer(i3geoOLlayer); |
| 10291 | 10352 | i3geoOL.events.register("mousemove", i3geoOL, function(e){ |
| ... | ... | @@ -10318,10 +10379,12 @@ i3GEO.interface = { |
| 10318 | 10379 | var pz = new OpenLayers.Control.PanZoomBar({numZoomLevels: 5}); |
| 10319 | 10380 | i3geoOL.addControl(pz); |
| 10320 | 10381 | pz.div.style.zIndex = 5000; |
| 10382 | + /* | |
| 10321 | 10383 | $i("OpenLayers_Control_PanZoom_pandown").style.top=parseInt($i("OpenLayers_Control_PanZoom_pandown").style.top)+5; |
| 10322 | 10384 | $i("OpenLayers_Control_PanZoom_panup").style.top=parseInt($i("OpenLayers_Control_PanZoom_panup").style.top)+5; |
| 10323 | 10385 | $i("OpenLayers_Control_PanZoom_panleft").style.top=parseInt($i("OpenLayers_Control_PanZoom_panleft").style.top)+5; |
| 10324 | 10386 | $i("OpenLayers_Control_PanZoom_panright").style.top=parseInt($i("OpenLayers_Control_PanZoom_panright").style.top)+5; |
| 10387 | + */ | |
| 10325 | 10388 | var navc = new OpenLayers.Control.NavToolbar(); |
| 10326 | 10389 | i3geoOL.addControl(navc); |
| 10327 | 10390 | navc.div.style.left="8px"; |
| ... | ... | @@ -10339,7 +10402,7 @@ i3GEO.interface = { |
| 10339 | 10402 | ]); |
| 10340 | 10403 | i3geoOL.addControl(botoesadic); |
| 10341 | 10404 | botoesadic.div.style.left="10px"; |
| 10342 | - botoesadic.div.style.top=parseInt($i("OpenLayers_Control_PanZoom_zoomout").style.top)+77; | |
| 10405 | + //botoesadic.div.style.top=parseInt($i("OpenLayers_Control_PanZoom_zoomout").style.top)+77; | |
| 10343 | 10406 | |
| 10344 | 10407 | i3geoOL.addControl(new OpenLayers.Control.LayerSwitcher()); |
| 10345 | 10408 | |
| ... | ... | @@ -10389,16 +10452,22 @@ i3GEO.interface = { |
| 10389 | 10452 | OPACIDADE: 0.8, |
| 10390 | 10453 | redesenha: function(){ |
| 10391 | 10454 | if(i3GeoMap != ""){ |
| 10392 | - i3GeoMap.removeOverlay(i3GEOTileO); | |
| 10393 | 10455 | posfixo = posfixo + "&"; |
| 10394 | - //wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS()+posfixo, i3GeoMap.getBounds()); | |
| 10395 | - var i3GEOTile = new GTileLayer(null,0,18,{ | |
| 10396 | - tileUrlTemplate:i3GEO.interface.googlemaps.criaTile()+posfixo, | |
| 10397 | - isPng:true, | |
| 10398 | - opacity:i3GEO.interface.googlemaps.OPACIDADE }); | |
| 10399 | - i3GEOTileO = new GTileLayerOverlay(i3GEOTile); | |
| 10400 | - i3GeoMap.addOverlay(i3GEOTileO); | |
| 10401 | - //i3GeoMap.addOverlay(i3GEOTile); | |
| 10456 | + if(tile == false){ | |
| 10457 | + i3GeoMap.removeOverlay(wmsmap); | |
| 10458 | + wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS()+posfixo, i3GeoMap.getBounds()); | |
| 10459 | + i3GeoMap.addOverlay(wmsmap); | |
| 10460 | + } | |
| 10461 | + else{ | |
| 10462 | + i3GeoMap.removeOverlay(i3GEOTileO); | |
| 10463 | + | |
| 10464 | + var i3GEOTile = new GTileLayer(null,0,18,{ | |
| 10465 | + tileUrlTemplate:i3GEO.interface.googlemaps.criaTile()+posfixo, | |
| 10466 | + isPng:true, | |
| 10467 | + opacity:i3GEO.interface.googlemaps.OPACIDADE }); | |
| 10468 | + i3GEOTileO = new GTileLayerOverlay(i3GEOTile); | |
| 10469 | + i3GeoMap.addOverlay(i3GEOTileO); | |
| 10470 | + } | |
| 10402 | 10471 | } |
| 10403 | 10472 | }, |
| 10404 | 10473 | cria: function(w,h){ |
| ... | ... | @@ -10418,13 +10487,17 @@ i3GEO.interface = { |
| 10418 | 10487 | i3GEO.interface.IDMAPA = "googlemaps"; |
| 10419 | 10488 | }, |
| 10420 | 10489 | inicia: function(){ |
| 10421 | - i3GEO.janela.slider("i3GEO.interface.googlemaps.mudaOpacidade","150"); | |
| 10490 | + tile = false; | |
| 10491 | + var ver = i3GEO.parametros.versaomscompleta.split("."); | |
| 10492 | + if(parseInt(i3GEO.parametros.versaoms) >= 5 && parseInt(ver[1]) > 1) | |
| 10493 | + {tile = true;} | |
| 10422 | 10494 | var pol = i3GEO.parametros.mapexten; |
| 10423 | 10495 | var ret = pol.split(" "); |
| 10424 | 10496 | var pt1 = (( (ret[0] * -1) - (ret[2] * -1) ) / 2) + ret[0] *1; |
| 10425 | 10497 | var pt2 = (((ret[1] - ret[3]) / 2)* -1) + ret[1] *1; |
| 10426 | 10498 | i3GeoMap = new GMap2($i("googlemaps")); |
| 10427 | 10499 | i3GeoMap.setMapType(G_SATELLITE_MAP); |
| 10500 | + //i3GeoMap.setMapType(G_SATELLITE_3D_MAP); | |
| 10428 | 10501 | i3GeoMap.addControl(new GLargeMapControl()); |
| 10429 | 10502 | i3GeoMap.addControl(new GMapTypeControl()); |
| 10430 | 10503 | var bottomLeft = new GControlPosition(G_ANCHOR_BOTTOM_LEFT,new GSize(0,40)); |
| ... | ... | @@ -10432,30 +10505,32 @@ i3GEO.interface = { |
| 10432 | 10505 | var bottomRight = new GControlPosition(G_ANCHOR_BOTTOM_RIGHT); |
| 10433 | 10506 | i3GeoMap.addControl(new GOverviewMapControl(),bottomRight); |
| 10434 | 10507 | i3GeoMap.setCenter(new GLatLng(pt2,pt1), 4); |
| 10435 | - //wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 10436 | - //i3GeoMap.addOverlay(wmsmap); | |
| 10437 | - var i3GEOTile = new GTileLayer(null,0,18,{ | |
| 10508 | + if(tile == false){ | |
| 10509 | + wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 10510 | + i3GeoMap.addOverlay(wmsmap); | |
| 10511 | + GEvent.addListener(i3GeoMap, "zoomend", function() { | |
| 10512 | + i3GeoMap.removeOverlay(wmsmap); | |
| 10513 | + wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 10514 | + i3GeoMap.addOverlay(wmsmap); | |
| 10515 | + }); | |
| 10516 | + GEvent.addListener(i3GeoMap, "dragend", function() { | |
| 10517 | + i3GeoMap.removeOverlay(wmsmap); | |
| 10518 | + wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 10519 | + i3GeoMap.addOverlay(wmsmap); | |
| 10520 | + }); | |
| 10521 | + } | |
| 10522 | + else{ | |
| 10523 | + i3GEO.janela.slider("i3GEO.interface.googlemaps.mudaOpacidade","150"); | |
| 10524 | + var i3GEOTile = new GTileLayer(null,0,18,{ | |
| 10438 | 10525 | tileUrlTemplate:i3GEO.interface.googlemaps.criaTile(), |
| 10439 | 10526 | isPng:true, |
| 10440 | 10527 | opacity:i3GEO.interface.googlemaps.OPACIDADE }); |
| 10441 | 10528 | |
| 10442 | - i3GEOTileO = new GTileLayerOverlay(i3GEOTile); | |
| 10443 | - i3GeoMap.addOverlay(i3GEOTileO); | |
| 10444 | - var myMapType = new GMapType([i3GEOTile], new GMercatorProjection(18), 'i3Geo'); | |
| 10445 | - i3GeoMap.addMapType(myMapType); | |
| 10446 | - | |
| 10447 | - /* | |
| 10448 | - GEvent.addListener(i3GeoMap, "zoomend", function() { | |
| 10449 | - i3GeoMap.removeOverlay(wmsmap); | |
| 10450 | - wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 10451 | - i3GeoMap.addOverlay(wmsmap); | |
| 10452 | - }); | |
| 10453 | - GEvent.addListener(i3GeoMap, "dragend", function() { | |
| 10454 | - i3GeoMap.removeOverlay(wmsmap); | |
| 10455 | - wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 10456 | - i3GeoMap.addOverlay(wmsmap); | |
| 10457 | - }); | |
| 10458 | - */ | |
| 10529 | + i3GEOTileO = new GTileLayerOverlay(i3GEOTile); | |
| 10530 | + i3GeoMap.addOverlay(i3GEOTileO); | |
| 10531 | + var myMapType = new GMapType([i3GEOTile], new GMercatorProjection(18), 'i3Geo'); | |
| 10532 | + i3GeoMap.addMapType(myMapType); | |
| 10533 | + } | |
| 10459 | 10534 | i3GEO.interface.googlemaps.ativaBotoes(); |
| 10460 | 10535 | i3GEO.eventos.ativa($i("googlemaps")); |
| 10461 | 10536 | i3GEO.gadgets.mostraCoordenadasGEO(); |
| ... | ... | @@ -10538,9 +10613,12 @@ i3GEO.interface = { |
| 10538 | 10613 | i3GEO.interface.IDMAPA = "googleearth"; |
| 10539 | 10614 | }, |
| 10540 | 10615 | inicia: function(){ |
| 10541 | - //http://mapas.mma.gov.br/i3geo/pacotes/kmlmapserver/kmlservice.php?map=bioma&typename=bioma&request=kml | |
| 10542 | - i3GeoMap.src = "http://www.gmodules.com/ig/ifr?url=http://hosting.gmodules.com/ig/gadgets/file/114026893455619160549/embedkmlgadget.xml&up_kml_url=http%3A%2F%2Fmapas.mma.gov.br%2Fi3geo%2Fpacotes%2Fkmlmapserver%2Fkmlservice.php%3Fmap%3Dbioma%26typename%3Dbioma%26request%3Dkml&up_view_mode=earth&up_earth_2d_fallback=0&up_earth_fly_from_space=1&up_earth_show_buildings=0&synd=open&w=320&h=400&title=Embedded+KML+Viewer&border=%23ffffff%7C3px%2C1px+solid+%23999999&source=http%3A%2F%2Fwww.gmodules.com%2Fig%2Fcreator%3Fsynd%3Dopen%26url%3Dhttp%3A%2F%2Fhosting.gmodules.com%2Fig%2Fgadgets%2Ffile%2F114026893455619160549%2Fembedkmlgadget.xml"; | |
| 10543 | - | |
| 10616 | + var src = "http://www.gmodules.com/ig/ifr?url=http://hosting.gmodules.com/ig/gadgets/file/114026893455619160549/embedkmlgadget.xml&up_kml_url="; | |
| 10617 | + var i = i3GEO.configura.locaplic+"/pacotes/kmlmapserver/kmlservice.php?map="+i3GEO.parametros.mapfile+"&typename=estadosl&request=kml&mode=map&"; | |
| 10618 | + //window.open(i) | |
| 10619 | + src += escape(i); | |
| 10620 | + src += "&up_view_mode=earth&up_earth_2d_fallback=0&up_earth_fly_from_space=1&up_earth_show_buildings=0&synd=open&w=320&h=400&title=Embedded+KML+Viewer&border=%23ffffff%7C3px%2C1px+solid+%23999999&source=http%3A%2F%2Fwww.gmodules.com%2Fig%2Fcreator%3Fsynd%3Dopen%26url%3Dhttp%3A%2F%2Fhosting.gmodules.com%2Fig%2Fgadgets%2Ffile%2F114026893455619160549%2Fembedkmlgadget.xml"; | |
| 10621 | + i3GeoMap.src = src; | |
| 10544 | 10622 | }, |
| 10545 | 10623 | ativaBotoes: function(){ |
| 10546 | 10624 | } |
| ... | ... | @@ -12083,7 +12161,9 @@ i3GEO.ajuda = { |
| 12083 | 12161 | |
| 12084 | 12162 | Define se a janela de mensagens pode ou não ser aberta. |
| 12085 | 12163 | |
| 12086 | - Default: true | |
| 12164 | + Default: | |
| 12165 | + | |
| 12166 | + true | |
| 12087 | 12167 | |
| 12088 | 12168 | Type: |
| 12089 | 12169 | {Boolean} |
| ... | ... | @@ -12097,7 +12177,8 @@ i3GEO.ajuda = { |
| 12097 | 12177 | Se esse DIV for encontrado no mapa, os textos serão mostrados em seu interior. |
| 12098 | 12178 | |
| 12099 | 12179 | Default: |
| 12100 | - "i3geo_ajuda" | |
| 12180 | + | |
| 12181 | + i3geo_ajuda | |
| 12101 | 12182 | |
| 12102 | 12183 | Type: |
| 12103 | 12184 | {String} |
| ... | ... | @@ -12111,7 +12192,8 @@ i3GEO.ajuda = { |
| 12111 | 12192 | Esse tipo de mensagem é obtida do METADATA "MENSAGEM" que pode ser incluído em um layer. |
| 12112 | 12193 | |
| 12113 | 12194 | Default: |
| 12114 | - "bannerMensagem" | |
| 12195 | + | |
| 12196 | + i3geo_letreiro | |
| 12115 | 12197 | |
| 12116 | 12198 | Type: |
| 12117 | 12199 | {String} |
| ... | ... | @@ -12720,18 +12802,21 @@ i3GEO.janela = { |
| 12720 | 12802 | catch(e){}; |
| 12721 | 12803 | } |
| 12722 | 12804 | else{ |
| 12723 | - i3GEO.janela.fechaAguarde("ajaxdestaca"); | |
| 12724 | - i3GEO.janela.fechaAguarde("ajaxabrelente"); | |
| 12725 | - i3GEO.janela.fechaAguarde("ajaxiniciaParametros"); | |
| 12726 | - i3GEO.janela.fechaAguarde("i3GEO.atualiza"); | |
| 12727 | - i3GEO.janela.fechaAguarde("ajaxCorpoMapaEntorno"); | |
| 12728 | - i3GEO.janela.fechaAguarde("ajaxCorpoMapa"); | |
| 12729 | - i3GEO.janela.fechaAguarde("ajaxLegenda"); | |
| 12730 | - i3GEO.janela.fechaAguarde("ajaxReferencia"); | |
| 12731 | - i3GEO.janela.fechaAguarde("ajaxEscalaGrafica"); | |
| 12732 | - i3GEO.janela.fechaAguarde("montaMapa"); | |
| 12733 | - i3GEO.janela.fechaAguarde("aguardedoc"); | |
| 12734 | - i3GEO.janela.fechaAguarde("ajaxCorpoMapa1"); | |
| 12805 | + try{ | |
| 12806 | + i3GEO.janela.fechaAguarde("ajaxdestaca"); | |
| 12807 | + i3GEO.janela.fechaAguarde("ajaxabrelente"); | |
| 12808 | + i3GEO.janela.fechaAguarde("ajaxiniciaParametros"); | |
| 12809 | + i3GEO.janela.fechaAguarde("i3GEO.atualiza"); | |
| 12810 | + i3GEO.janela.fechaAguarde("ajaxCorpoMapaEntorno"); | |
| 12811 | + i3GEO.janela.fechaAguarde("ajaxCorpoMapa"); | |
| 12812 | + i3GEO.janela.fechaAguarde("ajaxLegenda"); | |
| 12813 | + i3GEO.janela.fechaAguarde("ajaxReferencia"); | |
| 12814 | + i3GEO.janela.fechaAguarde("ajaxEscalaGrafica"); | |
| 12815 | + i3GEO.janela.fechaAguarde("montaMapa"); | |
| 12816 | + i3GEO.janela.fechaAguarde("aguardedoc"); | |
| 12817 | + i3GEO.janela.fechaAguarde("ajaxCorpoMapa1"); | |
| 12818 | + } | |
| 12819 | + catch(e){} | |
| 12735 | 12820 | } |
| 12736 | 12821 | } |
| 12737 | 12822 | }; | ... | ... |
classesjs/i3geo_tudo_compacto.js.php
| ... | ... | @@ -3744,7 +3744,7 @@ Balloon.prototype.isKonqueror = function() { |
| 3744 | 3744 | } |
| 3745 | 3745 | |
| 3746 | 3746 | /* |
| 3747 | -Title: I3Geo | |
| 3747 | +Title: i3Geo | |
| 3748 | 3748 | |
| 3749 | 3749 | File: i3geo/classesjs/classe_i3geo.js |
| 3750 | 3750 | |
| ... | ... | @@ -3788,7 +3788,14 @@ i3GEO = { |
| 3788 | 3788 | /* |
| 3789 | 3789 | Variable: parametros |
| 3790 | 3790 | |
| 3791 | - Parâmetros obtidos do mapa atual | |
| 3791 | + Parâmetros obtidos do mapa atual. Os parâmetros são fornecidos pelos programas | |
| 3792 | + PHP de redesenho e criação do mapa e atualizados sempre que o mapa é alterado. | |
| 3793 | + | |
| 3794 | + Exemplos: | |
| 3795 | + | |
| 3796 | + Para acessar um valor, utilize por exemplo | |
| 3797 | + | |
| 3798 | + alert(i3GEO.parametros.mapexten) | |
| 3792 | 3799 | |
| 3793 | 3800 | Parameters: |
| 3794 | 3801 | |
| ... | ... | @@ -3808,13 +3815,15 @@ i3GEO = { |
| 3808 | 3815 | |
| 3809 | 3816 | mapimagem {String} - URL da imagem que compõe o mapa |
| 3810 | 3817 | |
| 3811 | - geoip {sim|nao} - indica se o geoip está instalado, podendo ou não ser utilizado | |
| 3818 | + geoip {sim|nao} - indica se o geoip está instalado | |
| 3812 | 3819 | |
| 3813 | 3820 | listavisual {String} - lista de visuais disponíveis |
| 3814 | 3821 | |
| 3815 | 3822 | utilizacgi {sim|nao} - indica se o mapa atual está no modo CGI |
| 3816 | 3823 | |
| 3817 | - versaoms {String} - versão do Mapserver instalado no servidor | |
| 3824 | + versaoms {String} - versão do Mapserver instalado no servidor (maior) | |
| 3825 | + | |
| 3826 | + versaomscompleta {String} - versão do Mapserver instalado no servidor (completa) | |
| 3818 | 3827 | |
| 3819 | 3828 | mensagens {String} - mensagens para uso no letreiro |
| 3820 | 3829 | |
| ... | ... | @@ -3847,6 +3856,7 @@ i3GEO = { |
| 3847 | 3856 | listavisual: "", |
| 3848 | 3857 | utilizacgi:"", |
| 3849 | 3858 | versaoms:"", |
| 3859 | + versaomscompleta: "", | |
| 3850 | 3860 | mensagens:"", |
| 3851 | 3861 | w: "", |
| 3852 | 3862 | h: "", |
| ... | ... | @@ -3865,7 +3875,28 @@ i3GEO = { |
| 3865 | 3875 | para outra, os menus reflitam a última escolha |
| 3866 | 3876 | */ |
| 3867 | 3877 | temaAtivo: "", |
| 3878 | + /* | |
| 3879 | + Function: cria | |
| 3880 | + | |
| 3881 | + Cria e configura a visualização do mapa, definindo posicionamentos, tamanho etc | |
| 3882 | + | |
| 3883 | + Após as definições básicas, é executado o programa <i3GEO.interface.cria> que irá | |
| 3884 | + realizar as operações conforme a interface atualmente em uso. A interface é definida | |
| 3885 | + em <i3GEO.interface.ATUAL> | |
| 3886 | + | |
| 3887 | + <i3GEO.interface> | |
| 3888 | + */ | |
| 3868 | 3889 | cria:function(){ |
| 3890 | + if (window.location.href.split("?")[1]){ | |
| 3891 | + i3GEO.configura.sid = window.location.href.split("?")[1]; | |
| 3892 | + // | |
| 3893 | + //a biblioteca YUI, por algum motivo, acrescenta # na URL. O # precisa ser removido, caso contrário, a opção de reload da página pelo browser as vezes não funciona | |
| 3894 | + // | |
| 3895 | + if (i3GEO.configura.sid.split("#")[0]) | |
| 3896 | + {i3GEO.configura.sid = i3GEO.configura.sid.split("#")[0];} | |
| 3897 | + } | |
| 3898 | + else | |
| 3899 | + {i3GEO.configura.sid = "";} | |
| 3869 | 3900 | //para efeitos de compatibilidade |
| 3870 | 3901 | g_panM = "nao"; |
| 3871 | 3902 | try {i3GEO.configura.locaplic = g_locaplic;} |
| ... | ... | @@ -3933,6 +3964,7 @@ i3GEO = { |
| 3933 | 3964 | listavisual: "", |
| 3934 | 3965 | utilizacgi:"", |
| 3935 | 3966 | versaoms:"", |
| 3967 | + versaomscompleta:"", | |
| 3936 | 3968 | mensagens:"", |
| 3937 | 3969 | w: w, |
| 3938 | 3970 | h: h, |
| ... | ... | @@ -3943,6 +3975,22 @@ i3GEO = { |
| 3943 | 3975 | extentref:"" |
| 3944 | 3976 | }; |
| 3945 | 3977 | }, |
| 3978 | + /* | |
| 3979 | + Function: inicia | |
| 3980 | + | |
| 3981 | + Inicializa o mapa após ter sido criado com i3GEO.cria() | |
| 3982 | + | |
| 3983 | + Verifica se o mapa apresenta algum problema no processamento no lado do servidor e | |
| 3984 | + realiza as operações de tentativa de recuperação, se for o caso | |
| 3985 | + | |
| 3986 | + No início do processo é executada a função <i3GEOmantemCompatibilidade> | |
| 3987 | + para realizar as operações necessárias de manutenção de compatibilidade da versão atual para as anteriores | |
| 3988 | + | |
| 3989 | + A inicialização é baseada em <i3GEO.php.inicia> cujo retorno é utilizado para definir a | |
| 3990 | + variável <i3GEO.parametrso> | |
| 3991 | + | |
| 3992 | + Após a inicialização é executado <i3GEO.interface.inicia> | |
| 3993 | + */ | |
| 3946 | 3994 | inicia:function(){ |
| 3947 | 3995 | if(typeof("i3GEOmantemCompatibilidade") == 'function') |
| 3948 | 3996 | i3GEOmantemCompatibilidade(); |
| ... | ... | @@ -3988,6 +4036,8 @@ i3GEO = { |
| 3988 | 4036 | i3GEO.parametros.r = r; |
| 3989 | 4037 | i3GEO.parametros.locmapas = locmapas; |
| 3990 | 4038 | i3GEO.parametros.extentref = extentref; |
| 4039 | + i3GEO.parametros.versaoms = versaoms; | |
| 4040 | + i3GEO.parametros.versaomscompleta = versaomscompleta; | |
| 3991 | 4041 | i3GEO.gadgets.quadros.inicia(10); |
| 3992 | 4042 | i3GEO.gadgets.quadros.grava("extensao",mapexten); |
| 3993 | 4043 | i3GEO.arvoreDeCamadas.cria("",retorno.data.temas,i3GEO.configura.sid,i3GEO.configura.locaplic); |
| ... | ... | @@ -4067,11 +4117,22 @@ i3GEO = { |
| 4067 | 4117 | {i3GEO.eventos.NAVEGAMAPA.push("i3GEO.janela.fechaAguarde()");} |
| 4068 | 4118 | }, |
| 4069 | 4119 | finaliza:"", |
| 4070 | - | |
| 4071 | 4120 | /* |
| 4072 | 4121 | Function: atualiza |
| 4073 | 4122 | |
| 4074 | - Atualiza o mapa atual, alterando a imagem do mapa e os gadgets ativos | |
| 4123 | + Atualiza o mapa atual, alterando a imagem do mapa os gadgets ativos e os parâmetros e | |
| 4124 | + verifica a integridade do mapa em uso (arquivo mapfile) | |
| 4125 | + | |
| 4126 | + O processo executa também a função de atualização específica da interface atual em uso, veja | |
| 4127 | + <i3GEO.interface.redesenha> | |
| 4128 | + | |
| 4129 | + Os seguintes gadgets são processados | |
| 4130 | + | |
| 4131 | + <i3GEO.arvoreDeCamadas.atualiza> | |
| 4132 | + | |
| 4133 | + <i3GEO.arvoreDeCamadas.atualizaFarol> | |
| 4134 | + | |
| 4135 | + Os eventos definidos em <i3GEO.eventos.navegaMapa> são executados | |
| 4075 | 4136 | |
| 4076 | 4137 | Parameters: |
| 4077 | 4138 | |
| ... | ... | @@ -10285,7 +10346,7 @@ i3GEO.interface = { |
| 10285 | 10346 | var url = window.location.protocol+"//"+window.location.host+i3GEO.parametros.cgi+"?"; |
| 10286 | 10347 | url += "map="+i3GEO.parametros.mapfile+"&mode=map&SRS=epsg:4326&"; |
| 10287 | 10348 | i3geoOL = new OpenLayers.Map('openlayers', { controls: [] }); |
| 10288 | - i3geoOLlayer = new OpenLayers.Layer.WMS( "Temas I3Geo", url,{layers:'estadosl'},{'buffer':0},{isBaseLayer:true, opacity: 1}); | |
| 10349 | + i3geoOLlayer = new OpenLayers.Layer.MapServer( "Temas I3Geo", url,{layers:'estadosl'},{'buffer':1},{isBaseLayer:true, opacity: 1}); | |
| 10289 | 10350 | i3geoOLlayer.setVisibility(true); |
| 10290 | 10351 | i3geoOL.addLayer(i3geoOLlayer); |
| 10291 | 10352 | i3geoOL.events.register("mousemove", i3geoOL, function(e){ |
| ... | ... | @@ -10318,10 +10379,12 @@ i3GEO.interface = { |
| 10318 | 10379 | var pz = new OpenLayers.Control.PanZoomBar({numZoomLevels: 5}); |
| 10319 | 10380 | i3geoOL.addControl(pz); |
| 10320 | 10381 | pz.div.style.zIndex = 5000; |
| 10382 | + /* | |
| 10321 | 10383 | $i("OpenLayers_Control_PanZoom_pandown").style.top=parseInt($i("OpenLayers_Control_PanZoom_pandown").style.top)+5; |
| 10322 | 10384 | $i("OpenLayers_Control_PanZoom_panup").style.top=parseInt($i("OpenLayers_Control_PanZoom_panup").style.top)+5; |
| 10323 | 10385 | $i("OpenLayers_Control_PanZoom_panleft").style.top=parseInt($i("OpenLayers_Control_PanZoom_panleft").style.top)+5; |
| 10324 | 10386 | $i("OpenLayers_Control_PanZoom_panright").style.top=parseInt($i("OpenLayers_Control_PanZoom_panright").style.top)+5; |
| 10387 | + */ | |
| 10325 | 10388 | var navc = new OpenLayers.Control.NavToolbar(); |
| 10326 | 10389 | i3geoOL.addControl(navc); |
| 10327 | 10390 | navc.div.style.left="8px"; |
| ... | ... | @@ -10339,7 +10402,7 @@ i3GEO.interface = { |
| 10339 | 10402 | ]); |
| 10340 | 10403 | i3geoOL.addControl(botoesadic); |
| 10341 | 10404 | botoesadic.div.style.left="10px"; |
| 10342 | - botoesadic.div.style.top=parseInt($i("OpenLayers_Control_PanZoom_zoomout").style.top)+77; | |
| 10405 | + //botoesadic.div.style.top=parseInt($i("OpenLayers_Control_PanZoom_zoomout").style.top)+77; | |
| 10343 | 10406 | |
| 10344 | 10407 | i3geoOL.addControl(new OpenLayers.Control.LayerSwitcher()); |
| 10345 | 10408 | |
| ... | ... | @@ -10389,16 +10452,22 @@ i3GEO.interface = { |
| 10389 | 10452 | OPACIDADE: 0.8, |
| 10390 | 10453 | redesenha: function(){ |
| 10391 | 10454 | if(i3GeoMap != ""){ |
| 10392 | - i3GeoMap.removeOverlay(i3GEOTileO); | |
| 10393 | 10455 | posfixo = posfixo + "&"; |
| 10394 | - //wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS()+posfixo, i3GeoMap.getBounds()); | |
| 10395 | - var i3GEOTile = new GTileLayer(null,0,18,{ | |
| 10396 | - tileUrlTemplate:i3GEO.interface.googlemaps.criaTile()+posfixo, | |
| 10397 | - isPng:true, | |
| 10398 | - opacity:i3GEO.interface.googlemaps.OPACIDADE }); | |
| 10399 | - i3GEOTileO = new GTileLayerOverlay(i3GEOTile); | |
| 10400 | - i3GeoMap.addOverlay(i3GEOTileO); | |
| 10401 | - //i3GeoMap.addOverlay(i3GEOTile); | |
| 10456 | + if(tile == false){ | |
| 10457 | + i3GeoMap.removeOverlay(wmsmap); | |
| 10458 | + wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS()+posfixo, i3GeoMap.getBounds()); | |
| 10459 | + i3GeoMap.addOverlay(wmsmap); | |
| 10460 | + } | |
| 10461 | + else{ | |
| 10462 | + i3GeoMap.removeOverlay(i3GEOTileO); | |
| 10463 | + | |
| 10464 | + var i3GEOTile = new GTileLayer(null,0,18,{ | |
| 10465 | + tileUrlTemplate:i3GEO.interface.googlemaps.criaTile()+posfixo, | |
| 10466 | + isPng:true, | |
| 10467 | + opacity:i3GEO.interface.googlemaps.OPACIDADE }); | |
| 10468 | + i3GEOTileO = new GTileLayerOverlay(i3GEOTile); | |
| 10469 | + i3GeoMap.addOverlay(i3GEOTileO); | |
| 10470 | + } | |
| 10402 | 10471 | } |
| 10403 | 10472 | }, |
| 10404 | 10473 | cria: function(w,h){ |
| ... | ... | @@ -10418,13 +10487,17 @@ i3GEO.interface = { |
| 10418 | 10487 | i3GEO.interface.IDMAPA = "googlemaps"; |
| 10419 | 10488 | }, |
| 10420 | 10489 | inicia: function(){ |
| 10421 | - i3GEO.janela.slider("i3GEO.interface.googlemaps.mudaOpacidade","150"); | |
| 10490 | + tile = false; | |
| 10491 | + var ver = i3GEO.parametros.versaomscompleta.split("."); | |
| 10492 | + if(parseInt(i3GEO.parametros.versaoms) >= 5 && parseInt(ver[1]) > 1) | |
| 10493 | + {tile = true;} | |
| 10422 | 10494 | var pol = i3GEO.parametros.mapexten; |
| 10423 | 10495 | var ret = pol.split(" "); |
| 10424 | 10496 | var pt1 = (( (ret[0] * -1) - (ret[2] * -1) ) / 2) + ret[0] *1; |
| 10425 | 10497 | var pt2 = (((ret[1] - ret[3]) / 2)* -1) + ret[1] *1; |
| 10426 | 10498 | i3GeoMap = new GMap2($i("googlemaps")); |
| 10427 | 10499 | i3GeoMap.setMapType(G_SATELLITE_MAP); |
| 10500 | + //i3GeoMap.setMapType(G_SATELLITE_3D_MAP); | |
| 10428 | 10501 | i3GeoMap.addControl(new GLargeMapControl()); |
| 10429 | 10502 | i3GeoMap.addControl(new GMapTypeControl()); |
| 10430 | 10503 | var bottomLeft = new GControlPosition(G_ANCHOR_BOTTOM_LEFT,new GSize(0,40)); |
| ... | ... | @@ -10432,30 +10505,32 @@ i3GEO.interface = { |
| 10432 | 10505 | var bottomRight = new GControlPosition(G_ANCHOR_BOTTOM_RIGHT); |
| 10433 | 10506 | i3GeoMap.addControl(new GOverviewMapControl(),bottomRight); |
| 10434 | 10507 | i3GeoMap.setCenter(new GLatLng(pt2,pt1), 4); |
| 10435 | - //wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 10436 | - //i3GeoMap.addOverlay(wmsmap); | |
| 10437 | - var i3GEOTile = new GTileLayer(null,0,18,{ | |
| 10508 | + if(tile == false){ | |
| 10509 | + wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 10510 | + i3GeoMap.addOverlay(wmsmap); | |
| 10511 | + GEvent.addListener(i3GeoMap, "zoomend", function() { | |
| 10512 | + i3GeoMap.removeOverlay(wmsmap); | |
| 10513 | + wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 10514 | + i3GeoMap.addOverlay(wmsmap); | |
| 10515 | + }); | |
| 10516 | + GEvent.addListener(i3GeoMap, "dragend", function() { | |
| 10517 | + i3GeoMap.removeOverlay(wmsmap); | |
| 10518 | + wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 10519 | + i3GeoMap.addOverlay(wmsmap); | |
| 10520 | + }); | |
| 10521 | + } | |
| 10522 | + else{ | |
| 10523 | + i3GEO.janela.slider("i3GEO.interface.googlemaps.mudaOpacidade","150"); | |
| 10524 | + var i3GEOTile = new GTileLayer(null,0,18,{ | |
| 10438 | 10525 | tileUrlTemplate:i3GEO.interface.googlemaps.criaTile(), |
| 10439 | 10526 | isPng:true, |
| 10440 | 10527 | opacity:i3GEO.interface.googlemaps.OPACIDADE }); |
| 10441 | 10528 | |
| 10442 | - i3GEOTileO = new GTileLayerOverlay(i3GEOTile); | |
| 10443 | - i3GeoMap.addOverlay(i3GEOTileO); | |
| 10444 | - var myMapType = new GMapType([i3GEOTile], new GMercatorProjection(18), 'i3Geo'); | |
| 10445 | - i3GeoMap.addMapType(myMapType); | |
| 10446 | - | |
| 10447 | - /* | |
| 10448 | - GEvent.addListener(i3GeoMap, "zoomend", function() { | |
| 10449 | - i3GeoMap.removeOverlay(wmsmap); | |
| 10450 | - wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 10451 | - i3GeoMap.addOverlay(wmsmap); | |
| 10452 | - }); | |
| 10453 | - GEvent.addListener(i3GeoMap, "dragend", function() { | |
| 10454 | - i3GeoMap.removeOverlay(wmsmap); | |
| 10455 | - wmsmap = new GGroundOverlay(i3GEO.interface.googlemaps.criaWMS(), i3GeoMap.getBounds()); | |
| 10456 | - i3GeoMap.addOverlay(wmsmap); | |
| 10457 | - }); | |
| 10458 | - */ | |
| 10529 | + i3GEOTileO = new GTileLayerOverlay(i3GEOTile); | |
| 10530 | + i3GeoMap.addOverlay(i3GEOTileO); | |
| 10531 | + var myMapType = new GMapType([i3GEOTile], new GMercatorProjection(18), 'i3Geo'); | |
| 10532 | + i3GeoMap.addMapType(myMapType); | |
| 10533 | + } | |
| 10459 | 10534 | i3GEO.interface.googlemaps.ativaBotoes(); |
| 10460 | 10535 | i3GEO.eventos.ativa($i("googlemaps")); |
| 10461 | 10536 | i3GEO.gadgets.mostraCoordenadasGEO(); |
| ... | ... | @@ -10538,9 +10613,12 @@ i3GEO.interface = { |
| 10538 | 10613 | i3GEO.interface.IDMAPA = "googleearth"; |
| 10539 | 10614 | }, |
| 10540 | 10615 | inicia: function(){ |
| 10541 | - //http://mapas.mma.gov.br/i3geo/pacotes/kmlmapserver/kmlservice.php?map=bioma&typename=bioma&request=kml | |
| 10542 | - i3GeoMap.src = "http://www.gmodules.com/ig/ifr?url=http://hosting.gmodules.com/ig/gadgets/file/114026893455619160549/embedkmlgadget.xml&up_kml_url=http%3A%2F%2Fmapas.mma.gov.br%2Fi3geo%2Fpacotes%2Fkmlmapserver%2Fkmlservice.php%3Fmap%3Dbioma%26typename%3Dbioma%26request%3Dkml&up_view_mode=earth&up_earth_2d_fallback=0&up_earth_fly_from_space=1&up_earth_show_buildings=0&synd=open&w=320&h=400&title=Embedded+KML+Viewer&border=%23ffffff%7C3px%2C1px+solid+%23999999&source=http%3A%2F%2Fwww.gmodules.com%2Fig%2Fcreator%3Fsynd%3Dopen%26url%3Dhttp%3A%2F%2Fhosting.gmodules.com%2Fig%2Fgadgets%2Ffile%2F114026893455619160549%2Fembedkmlgadget.xml"; | |
| 10543 | - | |
| 10616 | + var src = "http://www.gmodules.com/ig/ifr?url=http://hosting.gmodules.com/ig/gadgets/file/114026893455619160549/embedkmlgadget.xml&up_kml_url="; | |
| 10617 | + var i = i3GEO.configura.locaplic+"/pacotes/kmlmapserver/kmlservice.php?map="+i3GEO.parametros.mapfile+"&typename=estadosl&request=kml&mode=map&"; | |
| 10618 | + //window.open(i) | |
| 10619 | + src += escape(i); | |
| 10620 | + src += "&up_view_mode=earth&up_earth_2d_fallback=0&up_earth_fly_from_space=1&up_earth_show_buildings=0&synd=open&w=320&h=400&title=Embedded+KML+Viewer&border=%23ffffff%7C3px%2C1px+solid+%23999999&source=http%3A%2F%2Fwww.gmodules.com%2Fig%2Fcreator%3Fsynd%3Dopen%26url%3Dhttp%3A%2F%2Fhosting.gmodules.com%2Fig%2Fgadgets%2Ffile%2F114026893455619160549%2Fembedkmlgadget.xml"; | |
| 10621 | + i3GeoMap.src = src; | |
| 10544 | 10622 | }, |
| 10545 | 10623 | ativaBotoes: function(){ |
| 10546 | 10624 | } |
| ... | ... | @@ -12083,7 +12161,9 @@ i3GEO.ajuda = { |
| 12083 | 12161 | |
| 12084 | 12162 | Define se a janela de mensagens pode ou não ser aberta. |
| 12085 | 12163 | |
| 12086 | - Default: true | |
| 12164 | + Default: | |
| 12165 | + | |
| 12166 | + true | |
| 12087 | 12167 | |
| 12088 | 12168 | Type: |
| 12089 | 12169 | {Boolean} |
| ... | ... | @@ -12097,7 +12177,8 @@ i3GEO.ajuda = { |
| 12097 | 12177 | Se esse DIV for encontrado no mapa, os textos serão mostrados em seu interior. |
| 12098 | 12178 | |
| 12099 | 12179 | Default: |
| 12100 | - "i3geo_ajuda" | |
| 12180 | + | |
| 12181 | + i3geo_ajuda | |
| 12101 | 12182 | |
| 12102 | 12183 | Type: |
| 12103 | 12184 | {String} |
| ... | ... | @@ -12111,7 +12192,8 @@ i3GEO.ajuda = { |
| 12111 | 12192 | Esse tipo de mensagem é obtida do METADATA "MENSAGEM" que pode ser incluído em um layer. |
| 12112 | 12193 | |
| 12113 | 12194 | Default: |
| 12114 | - "bannerMensagem" | |
| 12195 | + | |
| 12196 | + i3geo_letreiro | |
| 12115 | 12197 | |
| 12116 | 12198 | Type: |
| 12117 | 12199 | {String} |
| ... | ... | @@ -12720,18 +12802,21 @@ i3GEO.janela = { |
| 12720 | 12802 | catch(e){}; |
| 12721 | 12803 | } |
| 12722 | 12804 | else{ |
| 12723 | - i3GEO.janela.fechaAguarde("ajaxdestaca"); | |
| 12724 | - i3GEO.janela.fechaAguarde("ajaxabrelente"); | |
| 12725 | - i3GEO.janela.fechaAguarde("ajaxiniciaParametros"); | |
| 12726 | - i3GEO.janela.fechaAguarde("i3GEO.atualiza"); | |
| 12727 | - i3GEO.janela.fechaAguarde("ajaxCorpoMapaEntorno"); | |
| 12728 | - i3GEO.janela.fechaAguarde("ajaxCorpoMapa"); | |
| 12729 | - i3GEO.janela.fechaAguarde("ajaxLegenda"); | |
| 12730 | - i3GEO.janela.fechaAguarde("ajaxReferencia"); | |
| 12731 | - i3GEO.janela.fechaAguarde("ajaxEscalaGrafica"); | |
| 12732 | - i3GEO.janela.fechaAguarde("montaMapa"); | |
| 12733 | - i3GEO.janela.fechaAguarde("aguardedoc"); | |
| 12734 | - i3GEO.janela.fechaAguarde("ajaxCorpoMapa1"); | |
| 12805 | + try{ | |
| 12806 | + i3GEO.janela.fechaAguarde("ajaxdestaca"); | |
| 12807 | + i3GEO.janela.fechaAguarde("ajaxabrelente"); | |
| 12808 | + i3GEO.janela.fechaAguarde("ajaxiniciaParametros"); | |
| 12809 | + i3GEO.janela.fechaAguarde("i3GEO.atualiza"); | |
| 12810 | + i3GEO.janela.fechaAguarde("ajaxCorpoMapaEntorno"); | |
| 12811 | + i3GEO.janela.fechaAguarde("ajaxCorpoMapa"); | |
| 12812 | + i3GEO.janela.fechaAguarde("ajaxLegenda"); | |
| 12813 | + i3GEO.janela.fechaAguarde("ajaxReferencia"); | |
| 12814 | + i3GEO.janela.fechaAguarde("ajaxEscalaGrafica"); | |
| 12815 | + i3GEO.janela.fechaAguarde("montaMapa"); | |
| 12816 | + i3GEO.janela.fechaAguarde("aguardedoc"); | |
| 12817 | + i3GEO.janela.fechaAguarde("ajaxCorpoMapa1"); | |
| 12818 | + } | |
| 12819 | + catch(e){} | |
| 12735 | 12820 | } |
| 12736 | 12821 | } |
| 12737 | 12822 | }; | ... | ... |
classesphp/mapa_inicia.php
| ... | ... | @@ -78,7 +78,7 @@ function iniciaMapa() |
| 78 | 78 | //pega o xml com os sietmas para identificação |
| 79 | 79 | // |
| 80 | 80 | if(!isset($interface)){$interface = "";} |
| 81 | - if($interface == "googlemaps") | |
| 81 | + if($interface == "googlemaps" || $interface == "googleearth") | |
| 82 | 82 | { |
| 83 | 83 | $m = ms_newMapObj($map_file); |
| 84 | 84 | $c = $m->numlayers; |
| ... | ... | @@ -107,7 +107,17 @@ function iniciaMapa() |
| 107 | 107 | $temp->set("status",MS_OFF); |
| 108 | 108 | $c = $m->imagecolor; |
| 109 | 109 | $c->setrgb(255,255,255); |
| 110 | - $of = $m->outputformat; | |
| 110 | + if($interface == "googleearth") | |
| 111 | + { | |
| 112 | + $m->selectOutputFormat("jpeg"); | |
| 113 | + $of = $m->outputformat; | |
| 114 | + $of->set("imagemode",MS_IMAGEMODE_RGBA); | |
| 115 | + $of->set("driver","AGG/PNG"); | |
| 116 | + } | |
| 117 | + else | |
| 118 | + { | |
| 119 | + $of = $m->outputformat; | |
| 120 | + } | |
| 111 | 121 | $of->set("transparent",MS_ON); |
| 112 | 122 | $m->save($map_file); |
| 113 | 123 | } |
| ... | ... | @@ -187,6 +197,7 @@ function iniciaMapa() |
| 187 | 197 | $res .= ";var titulo='".$tituloInstituicao."'"; |
| 188 | 198 | $versao = versao(); |
| 189 | 199 | $res .= ";var versaoms ='".$versao["principal"]."'"; |
| 200 | + $res .= ";var versaomscompleta ='".$versao["completa"]."'"; | |
| 190 | 201 | //Pega os estilos disponíveis |
| 191 | 202 | $visual = (file_exists($locaplic."/imagens/visual")) ? implode(",",listaDiretorios($locaplic."/imagens/visual")) : ""; |
| 192 | 203 | $res .= ";var listavisual='".$visual."'"; | ... | ... |
ferramentas/funcoes.js
| ... | ... | @@ -20,7 +20,7 @@ Free Software Foundation, Inc., no endereço |
| 20 | 20 | 59 Temple Street, Suite 330, Boston, MA 02111-1307 USA. |
| 21 | 21 | */ |
| 22 | 22 | // |
| 23 | -g_sid = window.parent.g_sid; | |
| 23 | +g_sid = window.parent.i3GEO.configura.sid; | |
| 24 | 24 | $i = function(id) |
| 25 | 25 | {return document.getElementById(id);} |
| 26 | 26 | cabecalhojanela = ""; | ... | ... |
ferramentas/funcoes_compacto.js
| 1 | - g_sid=window.parent.g_sid;$i=function(id){return document.getElementById(id);} | |
| 1 | + g_sid=window.parent.i3GEO.configura.sid;$i=function(id){return document.getElementById(id);} | |
| 2 | 2 | cabecalhojanela="";var h=0;if(window.parent.document.getElementById("wdocai")){var h=parseInt(window.parent.document.getElementById("wdocai").style.height);} |
| 3 | 3 | navm=false;navn=false;var app=navigator.appName.substring(0,1);if(app=='N')navn=true;else navm=true;if(!$i("mascaraaguarde")){ if(navm){var s="filter:'alpha(opacity=20)'";} |
| 4 | 4 | if(navn){var s="opacity:.2";} | ... | ... |
ferramentas/i3geo_tudo_compacto.js
| 1 | 1 | $i = function(id){return document.getElementById(id);} |
| 2 | - g_sid=window.parent.g_sid;$i=function(id){return document.getElementById(id);} | |
| 2 | + g_sid=window.parent.i3GEO.configura.sid;$i=function(id){return document.getElementById(id);} | |
| 3 | 3 | cabecalhojanela="";var h=0;if(window.parent.document.getElementById("wdocai")){var h=parseInt(window.parent.document.getElementById("wdocai").style.height);} |
| 4 | 4 | navm=false;navn=false;var app=navigator.appName.substring(0,1);if(app=='N')navn=true;else navm=true;if(!$i("mascaraaguarde")){ if(navm){var s="filter:'alpha(opacity=20)'";} |
| 5 | 5 | if(navn){var s="opacity:.2";} | ... | ... |
ferramentas/i3geo_tudo_compacto.js.php
| 1 | 1 | <?php if(extension_loaded('zlib')){ob_start('ob_gzhandler');} header("Content-type: text/javascript"); ?>$i = function(id){return document.getElementById(id);} |
| 2 | - g_sid=window.parent.g_sid;$i=function(id){return document.getElementById(id);} | |
| 2 | + g_sid=window.parent.i3GEO.configura.sid;$i=function(id){return document.getElementById(id);} | |
| 3 | 3 | cabecalhojanela="";var h=0;if(window.parent.document.getElementById("wdocai")){var h=parseInt(window.parent.document.getElementById("wdocai").style.height);} |
| 4 | 4 | navm=false;navn=false;var app=navigator.appName.substring(0,1);if(app=='N')navn=true;else navm=true;if(!$i("mascaraaguarde")){ if(navm){var s="filter:'alpha(opacity=20)'";} |
| 5 | 5 | if(navn){var s="opacity:.2";} | ... | ... |
ferramentas/nuvemtags/index.js
| ... | ... | @@ -69,7 +69,7 @@ function montaNuvem(r) |
| 69 | 69 | } |
| 70 | 70 | } |
| 71 | 71 | tags += "<span> </span> <span onmouseout='this.style.textDecoration=\"none\"' onmouseover='this.style.textDecoration=\"underline\"' onclick='procurar(\""+retorno.data[i].tag+"\")' style='cursor:pointer;vertical-align:middle;color:rgb("+cor+");font-size:"+h+"pt;'>"+retorno.data[i].tag+"</span>"+linkrss |
| 72 | - if(h > 10) | |
| 72 | + if(h > 7) | |
| 73 | 73 | tagsFlash += "<a href='index.htm?palavra="+retorno.data[i].tag+"' target='_top' style='font-size:"+(h - 15)+"px;color:red;' >"+retorno.data[i].tag+"</a>" |
| 74 | 74 | } |
| 75 | 75 | } | ... | ... |
pacotes/kmlmapserver/classes/layerserver.class.php
| ... | ... | @@ -314,7 +314,7 @@ class LayerServer { |
| 314 | 314 | // Add parameters to OGC server call |
| 315 | 315 | // Fix & |
| 316 | 316 | $wms_link = preg_replace('/&/', '&', $wms_link); |
| 317 | - $wms_link .= 'VERSION=1.1.1&REQUEST=GetMap&SRS=EPSG:4326&STYLES=&BGCOLOR=0xFFFFFF&FORMAT=image/png&TRANSPARENT=TRUE&'; | |
| 317 | + $wms_link .= 'VERSION=1.1.1&REQUEST=GetMap&SRS=EPSG:4291&STYLES=&FORMAT=image/jpeg&TRANSPARENT=TRUE&'; | |
| 318 | 318 | // Link ok, create folder |
| 319 | 319 | //$folder =& $this->_xml->Document->addChild('GroundOverlay'); |
| 320 | 320 | $folder =& $this->simplexml_addChild($this->_xml->Document,'GroundOverlay'); |
| ... | ... | @@ -876,7 +876,11 @@ class LayerServer { |
| 876 | 876 | else |
| 877 | 877 | { |
| 878 | 878 | $this->map_object = ms_newMapObj($this->map); |
| 879 | - $this->map_object->setmetadata('wms_onlineresource',$servidor.":80/cgi-bin/mapserv?map=".$temp."&width=1500&height=1500&"); | |
| 879 | + if(file_exists("ms_configura.php")) | |
| 880 | + {include_once("ms_configura.php");} | |
| 881 | + else | |
| 882 | + {include_once("../../ms_configura.php");} | |
| 883 | + $this->map_object->setmetadata('wms_onlineresource',$servidor.":80".$locmapserv."?map=".$temp."&width=1500&height=1500&"); | |
| 880 | 884 | for ($i=0;$i < ($this->map_object->numlayers);$i++) |
| 881 | 885 | { |
| 882 | 886 | $l = $this->map_object->getlayer($i); | ... | ... |