openlayersdebug.htm 9.88 KB
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Category" content="i3Geo Mapa interativo MMA geoprocessamento sig mobile">
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1.0, user-scalable=0">
<title>i3GEO - OpenLayers</title>
<script src="../pacotes/ol3/ol-debug.js"></script>
<script src="../js/i3geonaocompacto.js"></script>
<link rel="stylesheet" type="text/css" href="../pacotes/ol3/ol.css">
<link rel="stylesheet" type="text/css" href="../css/black.css">
<style>
.ol-attribution img {
	display: none;
}

.ol-attribution.ol-uncollapsible {
	height: 2.1em;
	right: 24px;
	background: none;
	margin-bottom: 15px;
}
</style>
</head>
<body id="i3geo" style='background: white;'>

	<!-- inclui o nome do usuario logado -->
	<div id="i3GEONomeLogin"
		style="position: absolute; left: 10px; top: 12px; font-size: 11px; z-index: 50000"></div>
	<table id='mst' summary="" style='display: none;' width=100% cellspacing='0'>
		<tr>
			<td class=verdeclaro id=contemImg style="vertical-align: top; border-width: 0px;">
				<div id=corpoMapa style="position: relative; background-image: url('../imagens/i3geo1bw.jpg');"></div>
			</td>
		</tr>
	</table>
	<div id="i3GEOlogoMarca">
		<table>
			<tr>
				<td>
					<div id=versaoi3geo></div>
					<h1 class="i3GEOlogoMarca">i3Geo - Software livre para cria&ccedil;&atilde;o de mapas
						interativos e geoprocessamento</h1>
					<h1 class="i3GEOlogoMarca">Baseado no Mapserver, &eacute; licenciado sob GPL e integra o
						Portal do Software P&uacute;blico Brasileiro</h1>
				</td>
			</tr>
		</table>
		<img src='../imagens/logo_inicio.png'>
	</div>
	<div id="contemMenu">
		<!--menu suspenso-->
		<div id="menus"></div>
	</div>
	<!-- aqui ser&aacute; inclu&iacute;da a escala num&eacute;rica -->
	<div id=escala class=fundoRodape
		style="width: 100px; left: 7px; text-align: center; position: absolute; bottom: 0px; display: block;"></div>

	<!-- aqui ser&aacute; inclu&iacute;do o gadget que mostra a coordenada geogr&aacute;fica da posi&ccedil;&atilde;o do mouse -->
	<div id=localizarxy class=fundoRodape
		style="color: white; position: absolute; bottom: 0px; width: 320pt; left: 115px; text-align: left; font-size: 12pt; display: inline"></div>


	<div id="i3GEOguiaMovel"
		style="visibility: hidden; position: absolute; display: block; border: 0px solid white; text-align: left; z-index: 2000; background-color: none">
		<div
			style="cursor: pointer; position: absolute; top: 10px; width: 30px; z-index: 5000; left: 18px;">
			<div id="iconeGuia_temas"></div>
			<div id="iconeGuia_adiciona" style="margin-top: 3px;"></div>
			<div id="iconeGuia_legenda" style="margin-top: 3px;"></div>
			<div id="iconeGuia_dobraPagina" style="margin-top: 3px;"></div>
			<div id="iconeGuia_identificaBalao" style="margin-top: 3px;"></div>
			<div id="iconeGuia_identifica" style="margin-top: 3px;"></div>
		</div>
		<div id="i3GEOguiaMovelMolde"
			style="top: 0px; box-shadow: 0 2px 10px 0 #888888; position: absolute; display: none; border: 0px solid white; text-align: left; z-index: 1000; background-color: gray">
			<div id="i3GEOguiaMovelConteudo"
				style='top: 10px; overflow: auto; display: none; position: absolute; border-color: gray; border-width: 0px 0 0px 0px; left: 0px; height: 0px; background-color: white'>
				<div id='guia1obj' style='display: none;'>
					<div onclick="i3GEO.guias.guiaMovel.abreFecha('fecha');"
						style='cursor: pointer; left: 0px; top: 0px; width: 95%; text-align: right; font-size: 14pt;'>X</div>
					<!-- Esta div acrescenta a op&ccedil;&atilde;o de busca r&aacute;pida, caso vc queira coloc&aacute;-la em um lugar espec&iacute;fico -->
					<div style='left: 5px; top: 10px; width: 150px;' id=buscaRapida></div>
					<!--	Esta div acrescenta a lista de propriedades do mapa -->
					<!--<div id=listaPropriedades style='top:15px;' ></div>-->
					<!--	Esta div acrescenta a lista de de camadas do tipo 'baselayers' espec&iacute;ficas da interface Openlayers. Veja tamb&eacute;m a op&ccedil;&atilde;o i3GEO.Interface.openlayers.GADGETS.LayerSwitcher -->
					<div id=listaLayersBase style='top: 15px;'></div>
					<!--	Esta div acrescenta a lista de de camadas dispon&iacute;veis no mapa atual -->
					<div id=listaTemas style='top: 15px;'></div>
				</div>
				<div id='guia2obj' style='display: none;'>
					<div onclick="i3GEO.guias.guiaMovel.abreFecha('fecha');"
						style='cursor: pointer; left: 0px; top: 0px; width: 95%; text-align: right; font-size: 14pt;'>X</div>
					<div id="arvoreAdicionaTema">Aguarde...</div>
				</div>
				<div id='guia4obj' style='display: none; text-align: left'>
					<div onclick="i3GEO.guias.guiaMovel.abreFecha('fecha');"
						style='cursor: pointer; left: 0px; top: 0px; width: 95%; text-align: right; font-size: 14pt;'>X</div>
					<div id="arvoreLegenda" style='display: block; text-align: left'>Aguarde...</div>
				</div>
			</div>
		</div>
	</div>
	<script>
		i3GEO.configura.locaplic = i3GEO.util.protocolo() + "://"
				+ window.location.host + "/i3geo";
		i3GEO.configura.autotamanho = false;
		i3GEO.Interface.ATUAL = "openlayers";
		i3GEO.Interface.IDCORPO = "contemImg";
		i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.permiteLogin = true;

		i3GEO.Interface.openlayers.TILES = true;
		i3GEO.Interface.openlayers.googleLike = false;

		i3GEO.configura.guardaExtensao = true;
		i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.finaliza = 'if($i("omenudataInterface1")){i3GEOoMenuBar.getMenuItem("omenudataInterface1").cfg.setProperty("text", " ");}';

		i3GEO.cria();
		i3GEO.configura.mapaRefDisplay = "none";
		i3GEO.barraDeBotoes.ATIVA = true;
		i3GEO.barraDeBotoes.TIPO = "olhodepeixe";
		//ajusta o deslocamento da barra de botoes
		i3GEO.barraDeBotoes.OFFSET = 25;

		i3GEO.configura.oMenuData["submenus"]["janelas"] = [];
		i3GEO.ajuda.ATIVAJANELA = false;
		//i3GEO.arvoreDeTemas.TIPOBOTAO = "radio";
		i3GEO.arvoreDeTemas.OPCOESADICIONAIS.comentarios = true;
		i3GEO.arvoreDeCamadas.VERIFICAABRANGENCIATEMAS = true;
		i3GEO.arvoreDeCamadas.MOSTRALISTAKML = false;
		i3GEO.arvoreDeCamadas.MOSTRATITULO = true;
		i3GEO.mapa.AUTORESIZE = true;
		i3GEO.guias.TIPO = "movel";
		i3GEO.guias.guiaMovel.config.topGuiaMovel = 36;
		i3GEO.janela.ativaAlerta();
		i3GEO.finaliza = function() {
			if ($i("i3GEOlogoMarca")) {
				$i("i3GEOlogoMarca").style.display = "none";
			}
			//i3GEO.mapa.insereDobraPagina("googlemaps", "../imagens/dobragooglemaps.png");
		};
		//indica se a opcao de navegacao nas pastas do servidor sera ativada
		i3GEO.arvoreDeTemas.OPCOESADICIONAIS.navegacaoDir = true;
		i3GEO.janela.TRANSICAOSUAVE = true;
		//desliga a camada com o mapa mundi
		i3GEO.configura.mashuppar = "&desligar=mundo";
		(function() {
			var eng = new ol.layer.Tile(
					{
						title : "ESRI National Geographic",
						visible : true,
						isBaseLayer : true,
						name : "eng",
						source : new ol.source.TileArcGISRest(
								{
									url : "http://server.arcgisonline.com/ArcGIS/rest/services/NatGeo_World_Map/MapServer",
									attributions : [ new ol.Attribution(
											{
												html : 'Tiles &copy; <a href="http://server.arcgisonline.com/ArcGIS/rest/services/NatGeo_World_Map/MapServer">ArcGIS</a>'
											}) ]
								})
					});
			var oce = new ol.layer.Tile(
					{
						title : "ESRI Ocean Basemap",
						visible : false,
						isBaseLayer : true,
						name : "oce",
						source : new ol.source.TileArcGISRest(
								{
									url : "http://server.arcgisonline.com/ArcGIS/rest/services/Ocean_Basemap/MapServer",
									attributions : [ new ol.Attribution(
											{
												html : 'Tiles &copy; <a href="http://server.arcgisonline.com/ArcGIS/rest/services/Ocean_Basemap/MapServer">ArcGIS</a>'
											}) ]
								})
					});
			var ims = new ol.layer.Tile(
					{
						title : "ESRI Imagery World 2D",
						visible : false,
						isBaseLayer : true,
						name : "ims",
						source : new ol.source.TileArcGISRest(
								{
									url : "http://server.arcgisonline.com/ArcGIS/rest/services/ESRI_Imagery_World_2D/MapServer",
									attributions : [ new ol.Attribution(
											{
												html : 'Tiles &copy; <a href="http://server.arcgisonline.com/ArcGIS/rest/services/ESRI_Imagery_World_2D/MapServer">ArcGIS</a>'
											}) ]
								})
					});
			var wsm = new ol.layer.Tile(
					{
						title : "ESRI World Street Map",
						visible : false,
						isBaseLayer : true,
						name : "wsm",
						source : new ol.source.TileArcGISRest(
								{
									url : "http://server.arcgisonline.com/ArcGIS/rest/services/ESRI_StreetMap_World_2D/MapServer",
									attributions : [ new ol.Attribution(
											{
												html : 'Tiles &copy; <a href="http://server.arcgisonline.com/ArcGIS/rest/services/ESRI_StreetMap_World_2D/MapServer">ArcGIS</a>'
											}) ]
								})
					});
			var bra = new ol.layer.Tile(
					{
						title : "Base carto MMA",
						visible : false,
						isBaseLayer : true,
						name : "bra",
						source : new ol.source.TileWMS(
								{
									url : "http://mapas.mma.gov.br/cgi-bin/mapserv?map=/opt/www/html/webservices/baseraster.map&",
									params : {
										'layers' : "baseraster",
										'srs' : "EPSG:4326",
										'format' : "image/png"
									}
								})
					});
			var tms = new ol.layer.Tile(
					{
						title : "OSGEO",
						visible : false,
						isBaseLayer : true,
						name : "tms",
						source : new ol.source.TileWMS(
								{
									url : "http://tilecache.osgeo.org/wms-c/Basic.py/",
									params : {
										'layers' : "basic",
										'type' : "png",
										'srs' : "EPSG:4326",
										'format' : "image/png",
										'VERSION' : '1.1.1'
									},
									attributions : [ new ol.Attribution(
											{
												html : '&copy; <a href="http://www.tilecache.org/">2006-2010, TileCache Contributors</a>'
											}) ]
								})
					});
			i3GEO.Interface.openlayers.LAYERSADICIONAIS = [ eng, oce, ims, wsm,
					bra, tms ];
		})();
		i3GEO.inicia();
	</script>
</body>
</html>