Commit c9635e2339821264ea27a92e53916cb97d1b05d3
1 parent
00edf7fc
Exists in
master
and in
7 other branches
Ajustes no estilo do ícone de busca
Showing
7 changed files
with
701 additions
and
837 deletions
Show diff stats
classesjs/classe_gadgets.js
@@ -15,900 +15,764 @@ | @@ -15,900 +15,764 @@ | ||
15 | */ | 15 | */ |
16 | 16 | ||
17 | /** | 17 | /** |
18 | - * | 18 | + * |
19 | * Licença | 19 | * Licença |
20 | - * | 20 | + * |
21 | * GPL2 | 21 | * GPL2 |
22 | - * | 22 | + * |
23 | * i3Geo Interface Integrada de Ferramentas de Geoprocessamento para Internet | 23 | * i3Geo Interface Integrada de Ferramentas de Geoprocessamento para Internet |
24 | - * | ||
25 | - * Direitos Autorais Reservados (c) 2006 Ministério do Meio Ambiente | ||
26 | - * Brasil Desenvolvedor: Edmar Moretti edmar.moretti@gmail.com | ||
27 | - * | ||
28 | - * Este programa é software livre; você pode redistribuí-lo | ||
29 | - * e/ou modificá-lo sob os termos da Licença Pública Geral | ||
30 | - * GNU conforme publicada pela Free Software Foundation; | ||
31 | - * | ||
32 | - * Este programa é distribuído na expectativa de que seja | ||
33 | - * útil, porém, SEM NENHUMA GARANTIA; nem mesmo a garantia | ||
34 | - * implícita de COMERCIABILIDADE OU ADEQUACAtilde;O A UMA FINALIDADE | ||
35 | - * ESPECÍFICA. Consulte a Licença Pública Geral do GNU para | ||
36 | - * mais detalhes. Você deve ter recebido uma cópia da | ||
37 | - * Licença Pública Geral do GNU junto com este programa; se | ||
38 | - * não, escreva para a Free Software Foundation, Inc., no endereço | ||
39 | - * 59 Temple Street, Suite 330, Boston, MA 02111-1307 USA. | 24 | + * |
25 | + * Direitos Autorais Reservados (c) 2006 Ministério do Meio Ambiente Brasil Desenvolvedor: Edmar Moretti edmar.moretti@gmail.com | ||
26 | + * | ||
27 | + * Este programa é software livre; você pode redistribuí-lo e/ou modificá-lo sob os termos da Licença | ||
28 | + * Pública Geral GNU conforme publicada pela Free Software Foundation; | ||
29 | + * | ||
30 | + * Este programa é distribuído na expectativa de que seja útil, porém, SEM NENHUMA GARANTIA; nem mesmo a | ||
31 | + * garantia implícita de COMERCIABILIDADE OU ADEQUACAtilde;O A UMA FINALIDADE ESPECÍFICA. Consulte a Licença | ||
32 | + * Pública Geral do GNU para mais detalhes. Você deve ter recebido uma cópia da Licença Pública Geral do | ||
33 | + * GNU junto com este programa; se não, escreva para a Free Software Foundation, Inc., no endereço 59 Temple Street, Suite | ||
34 | + * 330, Boston, MA 02111-1307 USA. | ||
40 | */ | 35 | */ |
41 | if (typeof (i3GEO) === 'undefined') { | 36 | if (typeof (i3GEO) === 'undefined') { |
42 | var i3GEO = {}; | 37 | var i3GEO = {}; |
43 | } | 38 | } |
44 | -i3GEO.gadgets = { | ||
45 | - /** | ||
46 | - * Propriedade: PARAMETROS | ||
47 | - * | ||
48 | - * Parâmetros de inicialização dos gadgets. | ||
49 | - * | ||
50 | - * Essa variável define os parametros individuais de cada gadget e o | ||
51 | - * ID do elemento HTML onde o gadget será incluído (parametro | ||
52 | - * "idhtml"). | ||
53 | - * | ||
54 | - * Cada tipo de gadget pode ter parametros específicos, descritos a | ||
55 | - * seguir. | ||
56 | - * | ||
57 | - * Você pode acessar os parâmetros da seguinte forma: | ||
58 | - * | ||
59 | - * i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.deslocaEsquerda = 400; | ||
60 | - * | ||
61 | - * Para evitar o funcionamento de um gadget experimente utilizar | ||
62 | - * | ||
63 | - * Exemplo: | ||
64 | - * | ||
65 | - * i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml = ""; | ||
66 | - * | ||
67 | - * Default: | ||
68 | - * | ||
69 | - * (start code) | ||
70 | - * | ||
71 | - * i3GEO.gadgets.PARAMETROS = { "mostraInserirKml" : { idhtml : "inserirKml" }, | ||
72 | - * "mostraEscalaNumerica" : { idhtml : "escala" }, "mostraEscalaGrafica" : { | ||
73 | - * idhtml : "escalaGrafica" }, "mostraBuscaRapida" : { idhtml : | ||
74 | - * "buscaRapida", servicosexternos : true, temasmapa : false, google : true }, | ||
75 | - * "mostraVisual" : { idhtml : "" }, "mostraHistoricoZoom" : { idhtml : | ||
76 | - * "historicozoom" }, "mostraMenuSuspenso" : { permiteLogin : true, | ||
77 | - * marcadores : true, idhtml : "menus", deslocaEsquerda : 0, parametrosYUI : { | ||
78 | - * iframe : false, autosubmenudisplay : false, showdelay : 200, hidedelay : | ||
79 | - * 500, lazyload : false } }, "mostraMenuLista" : { idhtml : "menuLista" }, | ||
80 | - * "mostraVersao" : { idhtml : "versaoi3geo" }, "mostraEmail" : { idhtml : | ||
81 | - * "emailInstituicao" } }; | ||
82 | - * | ||
83 | - * (end) | ||
84 | - */ | ||
85 | - PARAMETROS : { | ||
86 | - "mostraInserirKml" : { | ||
87 | - idhtml : "inserirKml" | ||
88 | - }, | ||
89 | - "mostraEscalaNumerica" : { | ||
90 | - idhtml : "escala" | ||
91 | - }, | ||
92 | - "mostraEscalaGrafica" : { | ||
93 | - idhtml : "escalaGrafica" | ||
94 | - }, | ||
95 | - "mostraBuscaRapida" : { | ||
96 | - idhtml : "buscaRapida", | ||
97 | - servicosexternos : true, | ||
98 | - temasmapa : false, | ||
99 | - google : true | ||
100 | - }, | ||
101 | - "mostraVisual" : { | ||
102 | - idhtml : "" | ||
103 | - }, | ||
104 | - "mostraHistoricoZoom" : { | ||
105 | - idhtml : "historicozoom" | ||
106 | - }, | ||
107 | - "mostraMenuSuspenso" : { | ||
108 | - permiteLogin : true, | ||
109 | - marcadores : true, | ||
110 | - idhtml : "menus", | ||
111 | - deslocaEsquerda : 0, | ||
112 | - parametrosYUI : { | ||
113 | - iframe : false, | ||
114 | - autosubmenudisplay : false, | ||
115 | - showdelay : 200, | ||
116 | - hidedelay : 500, | ||
117 | - lazyload : false | 39 | +i3GEO.gadgets = |
40 | + { | ||
41 | + /** | ||
42 | + * Propriedade: PARAMETROS | ||
43 | + * | ||
44 | + * Parâmetros de inicialização dos gadgets. | ||
45 | + * | ||
46 | + * Essa variável define os parametros individuais de cada gadget e o ID do elemento HTML onde o gadget será | ||
47 | + * incluído (parametro "idhtml"). | ||
48 | + * | ||
49 | + * Cada tipo de gadget pode ter parametros específicos, descritos a seguir. | ||
50 | + * | ||
51 | + * Você pode acessar os parâmetros da seguinte forma: | ||
52 | + * | ||
53 | + * i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.deslocaEsquerda = 400; | ||
54 | + * | ||
55 | + * Para evitar o funcionamento de um gadget experimente utilizar | ||
56 | + * | ||
57 | + * Exemplo: | ||
58 | + * | ||
59 | + * i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml = ""; | ||
60 | + * | ||
61 | + * Default: | ||
62 | + * | ||
63 | + * (start code) | ||
64 | + * | ||
65 | + * i3GEO.gadgets.PARAMETROS = { "mostraInserirKml" : { idhtml : "inserirKml" }, "mostraEscalaNumerica" : { idhtml : "escala" }, | ||
66 | + * "mostraEscalaGrafica" : { idhtml : "escalaGrafica" }, "mostraBuscaRapida" : { idhtml : "buscaRapida", servicosexternos : true, | ||
67 | + * temasmapa : false, google : true }, "mostraVisual" : { idhtml : "" }, "mostraHistoricoZoom" : { idhtml : "historicozoom" }, | ||
68 | + * "mostraMenuSuspenso" : { permiteLogin : true, marcadores : true, idhtml : "menus", deslocaEsquerda : 0, parametrosYUI : { iframe : | ||
69 | + * false, autosubmenudisplay : false, showdelay : 200, hidedelay : 500, lazyload : false } }, "mostraMenuLista" : { idhtml : | ||
70 | + * "menuLista" }, "mostraVersao" : { idhtml : "versaoi3geo" }, "mostraEmail" : { idhtml : "emailInstituicao" } }; | ||
71 | + * | ||
72 | + * (end) | ||
73 | + */ | ||
74 | + PARAMETROS : { | ||
75 | + "mostraInserirKml" : { | ||
76 | + idhtml : "inserirKml" | ||
77 | + }, | ||
78 | + "mostraEscalaNumerica" : { | ||
79 | + idhtml : "escala" | ||
80 | + }, | ||
81 | + "mostraEscalaGrafica" : { | ||
82 | + idhtml : "escalaGrafica" | ||
83 | + }, | ||
84 | + "mostraBuscaRapida" : { | ||
85 | + idhtml : "buscaRapida", | ||
86 | + servicosexternos : true, | ||
87 | + temasmapa : false, | ||
88 | + google : true | ||
89 | + }, | ||
90 | + "mostraVisual" : { | ||
91 | + idhtml : "" | ||
92 | + }, | ||
93 | + "mostraHistoricoZoom" : { | ||
94 | + idhtml : "historicozoom" | ||
95 | + }, | ||
96 | + "mostraMenuSuspenso" : { | ||
97 | + permiteLogin : true, | ||
98 | + marcadores : true, | ||
99 | + idhtml : "menus", | ||
100 | + deslocaEsquerda : 0, | ||
101 | + parametrosYUI : { | ||
102 | + iframe : false, | ||
103 | + autosubmenudisplay : false, | ||
104 | + showdelay : 200, | ||
105 | + hidedelay : 500, | ||
106 | + lazyload : false | ||
107 | + } | ||
108 | + }, | ||
109 | + "mostraMenuLista" : { | ||
110 | + idhtml : "menuLista" | ||
111 | + }, | ||
112 | + "mostraVersao" : { | ||
113 | + idhtml : "versaoi3geo" | ||
114 | + }, | ||
115 | + "mostraEmail" : { | ||
116 | + idhtml : "emailInstituicao" | ||
118 | } | 117 | } |
119 | }, | 118 | }, |
120 | - "mostraMenuLista" : { | ||
121 | - idhtml : "menuLista" | ||
122 | - }, | ||
123 | - "mostraVersao" : { | ||
124 | - idhtml : "versaoi3geo" | ||
125 | - }, | ||
126 | - "mostraEmail" : { | ||
127 | - idhtml : "emailInstituicao" | ||
128 | - } | ||
129 | - }, | ||
130 | - /** | ||
131 | - * Function: mostraEmail | ||
132 | - * | ||
133 | - * Mostra o e-mail armazenado na variável | ||
134 | - * i3GEO.parametros.emailInstituicao | ||
135 | - * | ||
136 | - * Parametro: | ||
137 | - * | ||
138 | - * {String} - id do elemento HTML que receberá o resultado. Esse id | ||
139 | - * por default é obtido de i3GEO.gadgets.PARAMETROS | ||
140 | - */ | ||
141 | - mostraEmail : function(id) { | ||
142 | - if (typeof (console) !== 'undefined') | ||
143 | - console.info("i3GEO.gadgets.mostraEmail()"); | 119 | + /** |
120 | + * Function: mostraEmail | ||
121 | + * | ||
122 | + * Mostra o e-mail armazenado na variável i3GEO.parametros.emailInstituicao | ||
123 | + * | ||
124 | + * Parametro: | ||
125 | + * | ||
126 | + * {String} - id do elemento HTML que receberá o resultado. Esse id por default é obtido de i3GEO.gadgets.PARAMETROS | ||
127 | + */ | ||
128 | + mostraEmail : function(id) { | ||
129 | + if (typeof (console) !== 'undefined') | ||
130 | + console.info("i3GEO.gadgets.mostraEmail()"); | ||
144 | 131 | ||
145 | - if (arguments.length === 0 | ||
146 | - || id === "") { | ||
147 | - id = i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml; | ||
148 | - } else { | ||
149 | - i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml = id; | ||
150 | - } | ||
151 | - i3GEO.util.defineValor( | ||
152 | - id, | ||
153 | - "innerHTML", | ||
154 | - i3GEO.parametros.emailInstituicao); | ||
155 | - }, | ||
156 | - /** | ||
157 | - * Function: mostraVersao | ||
158 | - * | ||
159 | - * Mostra a versão atual do i3Geo armazenada na variável | ||
160 | - * i3GEO.parametros.mensageminicial | ||
161 | - * | ||
162 | - * Parametro: | ||
163 | - * | ||
164 | - * {String} - id do elemento HTML que receberá o resultado. Esse id | ||
165 | - * por default é obtido de i3GEO.gadgets.PARAMETROS | ||
166 | - */ | ||
167 | - mostraVersao : function(id) { | ||
168 | - if (typeof (console) !== 'undefined') | ||
169 | - console.info("i3GEO.gadgets.mostraVersão()"); | 132 | + if (arguments.length === 0 || id === "") { |
133 | + id = i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml; | ||
134 | + } else { | ||
135 | + i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml = id; | ||
136 | + } | ||
137 | + i3GEO.util.defineValor(id, "innerHTML", i3GEO.parametros.emailInstituicao); | ||
138 | + }, | ||
139 | + /** | ||
140 | + * Function: mostraVersao | ||
141 | + * | ||
142 | + * Mostra a versão atual do i3Geo armazenada na variável i3GEO.parametros.mensageminicial | ||
143 | + * | ||
144 | + * Parametro: | ||
145 | + * | ||
146 | + * {String} - id do elemento HTML que receberá o resultado. Esse id por default é obtido de i3GEO.gadgets.PARAMETROS | ||
147 | + */ | ||
148 | + mostraVersao : function(id) { | ||
149 | + if (typeof (console) !== 'undefined') | ||
150 | + console.info("i3GEO.gadgets.mostraVersão()"); | ||
170 | 151 | ||
171 | - if (arguments.length === 0 | ||
172 | - || id === "") { | ||
173 | - id = i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml; | ||
174 | - } else { | ||
175 | - i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml = id; | ||
176 | - } | ||
177 | - i3GEO.util.defineValor( | ||
178 | - id, | ||
179 | - "innerHTML", | ||
180 | - i3GEO.parametros.mensageminicia); | ||
181 | - }, | ||
182 | - /** | ||
183 | - * Function: mostraInserirKml | ||
184 | - * | ||
185 | - * Mostra no mapa a a opção para inserir kml. | ||
186 | - * | ||
187 | - * Essa opção só funciona com a API do Google carregada | ||
188 | - * | ||
189 | - * Se você não quer essa função no mapa, elimine | ||
190 | - * o elemento HTML existente no mapa que contenha o id definido em | ||
191 | - * i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml | ||
192 | - * | ||
193 | - * Parametro: | ||
194 | - * | ||
195 | - * {String} - id do elemento HTML que receberá o resultado. Esse id | ||
196 | - * por default é obtido de | ||
197 | - * i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml | ||
198 | - */ | ||
199 | - mostraInserirKml : function(id) { | ||
200 | - if (typeof (console) !== 'undefined') | ||
201 | - console.info("i3GEO.gadgets.mostraInserirKml()"); | 152 | + if (arguments.length === 0 || id === "") { |
153 | + id = i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml; | ||
154 | + } else { | ||
155 | + i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml = id; | ||
156 | + } | ||
157 | + i3GEO.util.defineValor(id, "innerHTML", i3GEO.parametros.mensageminicia); | ||
158 | + }, | ||
159 | + /** | ||
160 | + * Function: mostraInserirKml | ||
161 | + * | ||
162 | + * Mostra no mapa a a opção para inserir kml. | ||
163 | + * | ||
164 | + * Essa opção só funciona com a API do Google carregada | ||
165 | + * | ||
166 | + * Se você não quer essa função no mapa, elimine o elemento HTML existente no mapa que contenha o id | ||
167 | + * definido em i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml | ||
168 | + * | ||
169 | + * Parametro: | ||
170 | + * | ||
171 | + * {String} - id do elemento HTML que receberá o resultado. Esse id por default é obtido de | ||
172 | + * i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml | ||
173 | + */ | ||
174 | + mostraInserirKml : function(id) { | ||
175 | + if (typeof (console) !== 'undefined') | ||
176 | + console.info("i3GEO.gadgets.mostraInserirKml()"); | ||
202 | 177 | ||
203 | - var i, ins, temp; | ||
204 | - if (arguments.length === 0) { | ||
205 | - id = i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml; | ||
206 | - } | ||
207 | - if ($i(id)) { | ||
208 | - if (!$i("i3geo_urlkml")) { | ||
209 | - i = $inputText( | ||
210 | - id, | ||
211 | - "290", | ||
212 | - "i3geo_urlkml", | ||
213 | - "kml url", | ||
214 | - "35", | ||
215 | - "kml"); | ||
216 | - ins = "<table><tr><td>" | ||
217 | - + i; | ||
218 | - temp = 'i3GEO.Interface.adicionaKml();'; | ||
219 | - ins += "</td><td><img src='" | ||
220 | - + i3GEO.configura.locaplic + "/imagens/branco.gif" | ||
221 | - + "' class='tic' onclick='" | ||
222 | - + temp | ||
223 | - + "' /></td></tr></table>"; | ||
224 | - $i(id).innerHTML = ins; | 178 | + var i, ins, temp; |
179 | + if (arguments.length === 0) { | ||
180 | + id = i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml; | ||
225 | } | 181 | } |
226 | - } | ||
227 | - }, | ||
228 | - /** | ||
229 | - * Function: mostraEscalaNumerica | ||
230 | - * | ||
231 | - * Mostra no mapa a escala numérica. | ||
232 | - * | ||
233 | - * A escala numérica pode ser alterada pelo usuário | ||
234 | - * digitando-se a nova escala. | ||
235 | - * | ||
236 | - * Se você não quer essa função no mapa, elimine | ||
237 | - * o elemento HTML existente no mapa que contenha o id definido em | ||
238 | - * i3GEO.gadgets.PARAMETROS | ||
239 | - * | ||
240 | - * Parametro: | ||
241 | - * | ||
242 | - * {String} - id do elemento HTML que receberá o resultado. Esse id | ||
243 | - * por default é obtido de i3GEO.gadgets.PARAMETROS | ||
244 | - */ | ||
245 | - mostraEscalaNumerica : function(id) { | ||
246 | - if (typeof (console) !== 'undefined') | ||
247 | - console.info("i3GEO.gadgets.mostraEscalaNumerica()"); | 182 | + if ($i(id)) { |
183 | + if (!$i("i3geo_urlkml")) { | ||
184 | + i = $inputText(id, "290", "i3geo_urlkml", "kml url", "35", "kml"); | ||
185 | + ins = "<table><tr><td>" + i; | ||
186 | + temp = 'i3GEO.Interface.adicionaKml();'; | ||
187 | + ins += | ||
188 | + "</td><td><img src='" + i3GEO.configura.locaplic + "/imagens/branco.gif" + "' class='tic' onclick='" + temp | ||
189 | + + "' /></td></tr></table>"; | ||
190 | + $i(id).innerHTML = ins; | ||
191 | + } | ||
192 | + } | ||
193 | + }, | ||
194 | + /** | ||
195 | + * Function: mostraEscalaNumerica | ||
196 | + * | ||
197 | + * Mostra no mapa a escala numérica. | ||
198 | + * | ||
199 | + * A escala numérica pode ser alterada pelo usuário digitando-se a nova escala. | ||
200 | + * | ||
201 | + * Se você não quer essa função no mapa, elimine o elemento HTML existente no mapa que contenha o id | ||
202 | + * definido em i3GEO.gadgets.PARAMETROS | ||
203 | + * | ||
204 | + * Parametro: | ||
205 | + * | ||
206 | + * {String} - id do elemento HTML que receberá o resultado. Esse id por default é obtido de i3GEO.gadgets.PARAMETROS | ||
207 | + */ | ||
208 | + mostraEscalaNumerica : function(id) { | ||
209 | + if (typeof (console) !== 'undefined') | ||
210 | + console.info("i3GEO.gadgets.mostraEscalaNumerica()"); | ||
248 | 211 | ||
249 | - var i, ins, temp, onde; | ||
250 | - if (arguments.length === 0) { | ||
251 | - id = i3GEO.gadgets.PARAMETROS.mostraEscalaNumerica.idhtml; | ||
252 | - } | ||
253 | - onde = $i(id); | ||
254 | - if (onde) { | ||
255 | - if (onde.style.display == "none") { | ||
256 | - onde.style.display = "block"; | 212 | + var i, ins, temp, onde; |
213 | + if (arguments.length === 0) { | ||
214 | + id = i3GEO.gadgets.PARAMETROS.mostraEscalaNumerica.idhtml; | ||
215 | + } | ||
216 | + onde = $i(id); | ||
217 | + if (onde) { | ||
218 | + if (onde.style.display == "none") { | ||
219 | + onde.style.display = "block"; | ||
220 | + } | ||
221 | + if (!$i("i3geo_escalanum")) { | ||
222 | + i = | ||
223 | + "<form id='i3GEOescalanumForm' >" | ||
224 | + + $inputText(id, "100", "i3geo_escalanum", $trad("d10"), "10", parseInt(i3GEO.parametros.mapscale, 10)) | ||
225 | + + "</form>"; | ||
226 | + ins = "<table style='width:120px;'><tr><td>" + i; | ||
227 | + temp = 'var nova = document.getElementById("i3geo_escalanum").value;'; | ||
228 | + temp += 'i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,nova);'; | ||
229 | + ins += "</td></tr></table>"; | ||
230 | + onde.innerHTML = ins; | ||
231 | + $i("i3GEOescalanumForm").onsubmit = | ||
232 | + function() { | ||
233 | + i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic, i3GEO.configura.sid, document | ||
234 | + .getElementById("i3geo_escalanum").value); | ||
235 | + return false; | ||
236 | + }; | ||
237 | + } | ||
238 | + i3GEO.eventos.adicionaEventos("NAVEGAMAPA", [ | ||
239 | + "i3GEO.gadgets.atualizaEscalaNumerica()" | ||
240 | + ]); | ||
257 | } | 241 | } |
258 | - if (!$i("i3geo_escalanum")) { | ||
259 | - i = "<form id='i3GEOescalanumForm' >" | ||
260 | - + $inputText( | ||
261 | - id, | ||
262 | - "100", | ||
263 | - "i3geo_escalanum", | ||
264 | - $trad("d10"), | ||
265 | - "10", | ||
266 | - parseInt( | ||
267 | - i3GEO.parametros.mapscale, | ||
268 | - 10)) | ||
269 | - + "</form>"; | ||
270 | - ins = "<table style='width:120px;'><tr><td>" | ||
271 | - + i; | ||
272 | - temp = 'var nova = document.getElementById("i3geo_escalanum").value;'; | ||
273 | - temp += 'i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,nova);'; | ||
274 | - ins += "</td></tr></table>"; | ||
275 | - onde.innerHTML = ins; | ||
276 | - $i("i3GEOescalanumForm").onsubmit = function() { | ||
277 | - i3GEO.navega.aplicaEscala( | ||
278 | - i3GEO.configura.locaplic, | ||
279 | - i3GEO.configura.sid, | ||
280 | - document.getElementById("i3geo_escalanum").value); | ||
281 | - return false; | ||
282 | - }; | 242 | + }, |
243 | + atualizaEscalaNumerica : function(escala) { | ||
244 | + var e = $i("i3geo_escalanum"); | ||
245 | + if (!e) { | ||
246 | + i3GEO.eventos.removeEventos("NAVEGAMAPA", [ | ||
247 | + "i3GEO.gadgets.atualizaEscalaNumerica()" | ||
248 | + ]); | ||
249 | + return; | ||
283 | } | 250 | } |
284 | - i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"]); | ||
285 | - } | ||
286 | - }, | ||
287 | - atualizaEscalaNumerica : function(escala) { | ||
288 | - var e = $i("i3geo_escalanum"); | ||
289 | - if (!e) { | ||
290 | - i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"]); | ||
291 | - return; | ||
292 | - } | ||
293 | - if (arguments.length === 1) { | ||
294 | - e.value = escala; | ||
295 | - } else { | ||
296 | - if (i3GEO.parametros.mapscale !== "") { | ||
297 | - e.value = parseInt( | ||
298 | - i3GEO.parametros.mapscale, | ||
299 | - 10); | 251 | + if (arguments.length === 1) { |
252 | + e.value = escala; | ||
300 | } else { | 253 | } else { |
301 | - e.value = 0; | 254 | + if (i3GEO.parametros.mapscale !== "") { |
255 | + e.value = parseInt(i3GEO.parametros.mapscale, 10); | ||
256 | + } else { | ||
257 | + e.value = 0; | ||
258 | + } | ||
302 | } | 259 | } |
303 | - } | ||
304 | - }, | 260 | + }, |
305 | 261 | ||
306 | - /** | ||
307 | - * Function: mostraEscalaGrafica | ||
308 | - * | ||
309 | - * Mostra no mapa a escala grafica como um elemento fora do mapa. | ||
310 | - * | ||
311 | - * Se você não quer essa função no mapa, elimine | ||
312 | - * o elemento HTML existente no mapa que contenha o id definido em | ||
313 | - * i3GEO.gadgets.PARAMETROS(escala) | ||
314 | - * | ||
315 | - * Parametro: | ||
316 | - * | ||
317 | - * {String} - id do elemento HTML que receberá o resultado. Esse id | ||
318 | - * por default é obtido de i3GEO.gadgets.PARAMETROS | ||
319 | - */ | ||
320 | - mostraEscalaGrafica : function(id) { | ||
321 | - if (arguments.length === 0) { | ||
322 | - id = i3GEO.gadgets.PARAMETROS.mostraEscalaGrafica.idhtml; | ||
323 | - } | ||
324 | - var ins; | ||
325 | - if ($i(id)) { | ||
326 | - if (!$i("imagemEscalaGrafica")) { | ||
327 | - ins = "<img class='menuarrow' src=\"" | ||
328 | - + i3GEO.configura.locaplic | ||
329 | - + "/imagens/branco.gif\" title='opções' onclick='i3GEO.mapa.dialogo.opcoesEscala()' style='cursor:pointer'/><img id=imagemEscalaGrafica src='' />"; | ||
330 | - $i(id).innerHTML = ins; | 262 | + /** |
263 | + * Function: mostraEscalaGrafica | ||
264 | + * | ||
265 | + * Mostra no mapa a escala grafica como um elemento fora do mapa. | ||
266 | + * | ||
267 | + * Se você não quer essa função no mapa, elimine o elemento HTML existente no mapa que contenha o id | ||
268 | + * definido em i3GEO.gadgets.PARAMETROS(escala) | ||
269 | + * | ||
270 | + * Parametro: | ||
271 | + * | ||
272 | + * {String} - id do elemento HTML que receberá o resultado. Esse id por default é obtido de i3GEO.gadgets.PARAMETROS | ||
273 | + */ | ||
274 | + mostraEscalaGrafica : function(id) { | ||
275 | + if (arguments.length === 0) { | ||
276 | + id = i3GEO.gadgets.PARAMETROS.mostraEscalaGrafica.idhtml; | ||
331 | } | 277 | } |
332 | - i3GEO.gadgets.atualizaEscalaGrafica(); | ||
333 | - i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"]); | ||
334 | - } | ||
335 | - }, | ||
336 | - /** | ||
337 | - * Function: atualizaEscalaGrafica | ||
338 | - * | ||
339 | - * Atualiza a escala gráfica | ||
340 | - * | ||
341 | - */ | ||
342 | - atualizaEscalaGrafica : function() { | ||
343 | - var e = $i("imagemEscalaGrafica"); | ||
344 | - if (!e) { | ||
345 | - i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"]); | ||
346 | - return; | ||
347 | - } | ||
348 | - temp = function(retorno) { | ||
349 | - eval(retorno.data); | ||
350 | - $i("imagemEscalaGrafica").src = scaimagem; | ||
351 | - }; | ||
352 | - i3GEO.php.escalagrafica(temp); | ||
353 | - }, | ||
354 | - /** | ||
355 | - * Function: mostraBuscaRapida | ||
356 | - * | ||
357 | - * Mostra a opção de busca rápida de lugares por | ||
358 | - * palavra digitada. | ||
359 | - * | ||
360 | - * Se você não quer essa função no mapa, elimine | ||
361 | - * o elemento HTML existente no mapa que contenha o id definido em | ||
362 | - * i3GEO.gadgets.PARAMETROS (buscaRapida) | ||
363 | - * | ||
364 | - * Onde a busca será feita é controlado pela variável | ||
365 | - * i3GEO.gadgets.PARAMETROS.mostraBuscaRapida | ||
366 | - * | ||
367 | - * Parametro: | ||
368 | - * | ||
369 | - * {String} - id do elemento HTML que receberá o resultado. Esse id | ||
370 | - * por default é obtido de i3GEO.gadgets.PARAMETROS | ||
371 | - */ | ||
372 | - mostraBuscaRapida : function(id) { | ||
373 | - if (typeof (console) !== 'undefined') | ||
374 | - console.info("i3GEO.gadgets.mostraBuscaRapida()"); | 278 | + var ins; |
279 | + if ($i(id)) { | ||
280 | + if (!$i("imagemEscalaGrafica")) { | ||
281 | + ins = | ||
282 | + "<img class='menuarrow' src=\"" | ||
283 | + + i3GEO.configura.locaplic | ||
284 | + + "/imagens/branco.gif\" title='opções' onclick='i3GEO.mapa.dialogo.opcoesEscala()' style='cursor:pointer'/><img id=imagemEscalaGrafica src='' />"; | ||
285 | + $i(id).innerHTML = ins; | ||
286 | + } | ||
287 | + i3GEO.gadgets.atualizaEscalaGrafica(); | ||
288 | + i3GEO.eventos.adicionaEventos("NAVEGAMAPA", [ | ||
289 | + "i3GEO.gadgets.atualizaEscalaGrafica()" | ||
290 | + ]); | ||
291 | + } | ||
292 | + }, | ||
293 | + /** | ||
294 | + * Function: atualizaEscalaGrafica | ||
295 | + * | ||
296 | + * Atualiza a escala gráfica | ||
297 | + * | ||
298 | + */ | ||
299 | + atualizaEscalaGrafica : function() { | ||
300 | + var e = $i("imagemEscalaGrafica"); | ||
301 | + if (!e) { | ||
302 | + i3GEO.eventos.removeEventos("NAVEGAMAPA", [ | ||
303 | + "i3GEO.gadgets.atualizaEscalaGrafica()" | ||
304 | + ]); | ||
305 | + return; | ||
306 | + } | ||
307 | + temp = function(retorno) { | ||
308 | + eval(retorno.data); | ||
309 | + $i("imagemEscalaGrafica").src = scaimagem; | ||
310 | + }; | ||
311 | + i3GEO.php.escalagrafica(temp); | ||
312 | + }, | ||
313 | + /** | ||
314 | + * Function: mostraBuscaRapida | ||
315 | + * | ||
316 | + * Mostra a opção de busca rápida de lugares por palavra digitada. | ||
317 | + * | ||
318 | + * Se você não quer essa função no mapa, elimine o elemento HTML existente no mapa que contenha o id | ||
319 | + * definido em i3GEO.gadgets.PARAMETROS (buscaRapida) | ||
320 | + * | ||
321 | + * Onde a busca será feita é controlado pela variável i3GEO.gadgets.PARAMETROS.mostraBuscaRapida | ||
322 | + * | ||
323 | + * Parametro: | ||
324 | + * | ||
325 | + * {String} - id do elemento HTML que receberá o resultado. Esse id por default é obtido de i3GEO.gadgets.PARAMETROS | ||
326 | + */ | ||
327 | + mostraBuscaRapida : function(id) { | ||
328 | + if (typeof (console) !== 'undefined') | ||
329 | + console.info("i3GEO.gadgets.mostraBuscaRapida()"); | ||
375 | 330 | ||
376 | - var i, ins, temp, fbusca; | ||
377 | - if (arguments.length === 0) { | ||
378 | - id = i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.idhtml; | ||
379 | - } | ||
380 | - i3GEO.gadgets.mostraBuscaRapida.id = id; | ||
381 | - if ($i(id)) { | ||
382 | - i = "<form id=i3GEObotaoFormBuscaRapida" | ||
383 | - + id | ||
384 | - + " >" | ||
385 | - + "<div class='i3geoForm' style='width:160px;'><input class=i3geoFormSemIcone type=text value='' id='valorBuscaRapida" | ||
386 | - + id | ||
387 | - + "' /></div>" | ||
388 | - + "</form>"; | ||
389 | - ins = "<table><tr><td><a class=ajuda_usuario target=_blank href='" | ||
390 | - + i3GEO.configura.locaplic | ||
391 | - + "/ajuda_usuario.php?idcategoria=8&idajuda=71' > </a></td><td>" | ||
392 | - + i | ||
393 | - + "</td>"; | ||
394 | - ins += "<td><img src='" | ||
395 | - + i3GEO.configura.locaplic + "/imagens/branco.gif" | ||
396 | - + "' title='" | ||
397 | - + $trad("p13") | ||
398 | - + "' class='ticPropriedades2' id=i3GEObotaoPropriedadesBuscaRapida" | ||
399 | - + id | ||
400 | - + " style='margin-right:5px;margin-left:5px;'/></td>"; | ||
401 | - ins += "<td><img src='" | ||
402 | - + i3GEO.configura.locaplic + "/imagens/branco.gif" | ||
403 | - + "' class='ticfind' id=i3GEObotaoBuscaRapida" | ||
404 | - + id | ||
405 | - + " /></td></tr></table>"; | ||
406 | - temp = $i(id); | ||
407 | - if (temp) { | ||
408 | - fbusca = function() { | ||
409 | - if (i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google === false | ||
410 | - && i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos === false | ||
411 | - && i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa === false) { | ||
412 | - i3GEO.janela.tempoMsg($trad("x35")); | ||
413 | - return; | ||
414 | - } | ||
415 | - if ($i("valorBuscaRapida" | ||
416 | - + id).value === "") { | ||
417 | - i3GEO.janela.tempoMsg($trad("x36")); | ||
418 | - return; | ||
419 | - } | ||
420 | - i3GEO.janela.cria( | ||
421 | - "300px", | ||
422 | - "280px", | ||
423 | - i3GEO.configura.locaplic | ||
424 | - + "/ferramentas/buscarapida/index.htm", | ||
425 | - "", | ||
426 | - "", | ||
427 | - $trad("o2")); | ||
428 | - return false; | ||
429 | - }; | ||
430 | - temp.innerHTML = ins; | ||
431 | - $i("i3GEObotaoBuscaRapida" | ||
432 | - + id).onclick = fbusca; | ||
433 | - $i("i3GEObotaoFormBuscaRapida" | ||
434 | - + id).onsubmit = fbusca; | ||
435 | - $i("i3GEObotaoPropriedadesBuscaRapida" | ||
436 | - + id).onclick = function() { | ||
437 | - var ins, interno = "", externo = "", google = ""; | ||
438 | - i3GEO.janela.cria( | ||
439 | - "300px", | ||
440 | - "150px", | ||
441 | - "", | ||
442 | - "", | ||
443 | - "", | ||
444 | - $trad("s5"), | ||
445 | - "i3GEOpropriedadesBuscaRapida" | ||
446 | - + id); | ||
447 | - if (i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos) { | ||
448 | - externo = "checked"; | ||
449 | - } | ||
450 | - if (i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa) { | ||
451 | - interno = "checked"; | ||
452 | - } | ||
453 | - ins = "<p class=paragrafo >" | ||
454 | - + $trad("x37") | ||
455 | - + ":</p>" | ||
456 | - + "<table class=lista3 >" | ||
457 | - + "<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos = this.checked' type=checkbox " | ||
458 | - + externo | ||
459 | - + " ></td><td> " | ||
460 | - + $trad("x38") | ||
461 | - + "</td></tr>" | ||
462 | - + "<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa = this.checked' type=checkbox " | ||
463 | - + interno | ||
464 | - + " ></td><td>" | ||
465 | - + $trad("x39") | ||
466 | - + "</td></tr>"; | ||
467 | - if (i3GEO.Interface.ATUAL === "googlemaps") { | ||
468 | - if (i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google) { | ||
469 | - google = "checked"; | ||
470 | - } | ||
471 | - ins += "<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google = this.checked' type=checkbox " | ||
472 | |||
473 | - + " ></td><td>Google</td></tr>"; | ||
474 | - } else { | ||
475 | - i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google = false; | ||
476 | - } | ||
477 | - ins += "</table><br>" | ||
478 | - + "<p class=paragrafo >" | ||
479 | - + $trad("x40") | ||
480 | - + "</p>"; | ||
481 | - $i("i3GEOpropriedadesBuscaRapida" | 331 | + var i, ins, temp, fbusca; |
332 | + if (arguments.length === 0) { | ||
333 | + id = i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.idhtml; | ||
334 | + } | ||
335 | + i3GEO.gadgets.mostraBuscaRapida.id = id; | ||
336 | + if ($i(id)) { | ||
337 | + i = | ||
338 | + "<form id=i3GEObotaoFormBuscaRapida" | ||
482 | + id | 339 | + id |
483 | - + "_corpo").innerHTML = ins; | ||
484 | - }; | 340 | + + " >" |
341 | + + "<div class='i3geoForm' style='width:160px;'><input class=i3geoFormSemIcone type=text value='' id='valorBuscaRapida" | ||
342 | + + id + "' /></div>" + "</form>"; | ||
343 | + ins = | ||
344 | + "<table><tr><td><a class=ajuda_usuario target=_blank href='" + i3GEO.configura.locaplic | ||
345 | + + "/ajuda_usuario.php?idcategoria=8&idajuda=71' ><img src='" + i3GEO.configura.locaplic + "/imagens/branco.gif' /></a></td>" | ||
346 | + + "<td><img src='" + i3GEO.configura.locaplic + "/imagens/branco.gif" + "' title='" + $trad("p13") | ||
347 | + + "' class='ticPropriedades2' id=i3GEObotaoPropriedadesBuscaRapida" + id | ||
348 | + + " style='margin-right:5px;margin-left:5px;'/></td>" | ||
349 | + + "<td>" + i + "</td>" | ||
350 | + + "<td><img src='" + i3GEO.configura.locaplic | ||
351 | + + "/imagens/branco.gif" + "' class='ticfind' id=i3GEObotaoBuscaRapida" + id + " style='margin-left:3px;' /></td></tr></table>"; | ||
352 | + temp = $i(id); | ||
353 | + if (temp) { | ||
354 | + fbusca = | ||
355 | + function() { | ||
356 | + if (i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google === false | ||
357 | + && i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos === false | ||
358 | + && i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa === false) { | ||
359 | + i3GEO.janela.tempoMsg($trad("x35")); | ||
360 | + return; | ||
361 | + } | ||
362 | + if ($i("valorBuscaRapida" + id).value === "") { | ||
363 | + i3GEO.janela.tempoMsg($trad("x36")); | ||
364 | + return; | ||
365 | + } | ||
366 | + i3GEO.janela.cria( | ||
367 | + "300px", | ||
368 | + "280px", | ||
369 | + i3GEO.configura.locaplic + "/ferramentas/buscarapida/index.htm", | ||
370 | + "", | ||
371 | + "", | ||
372 | + $trad("o2")); | ||
373 | + return false; | ||
374 | + }; | ||
375 | + temp.innerHTML = ins; | ||
376 | + $i("i3GEObotaoBuscaRapida" + id).onclick = fbusca; | ||
377 | + $i("i3GEObotaoFormBuscaRapida" + id).onsubmit = fbusca; | ||
378 | + $i("i3GEObotaoPropriedadesBuscaRapida" + id).onclick = | ||
379 | + function() { | ||
380 | + var ins, interno = "", externo = "", google = ""; | ||
381 | + i3GEO.janela.cria("300px", "150px", "", "", "", $trad("s5"), "i3GEOpropriedadesBuscaRapida" + id); | ||
382 | + if (i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos) { | ||
383 | + externo = "checked"; | ||
384 | + } | ||
385 | + if (i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa) { | ||
386 | + interno = "checked"; | ||
387 | + } | ||
388 | + ins = | ||
389 | + "<p class=paragrafo >" | ||
390 | + + $trad("x37") | ||
391 | + + ":</p>" | ||
392 | + + "<table class=lista3 >" | ||
393 | + + "<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos = this.checked' type=checkbox " | ||
394 | + + externo | ||
395 | + + " ></td><td> " | ||
396 | + + $trad("x38") | ||
397 | + + "</td></tr>" | ||
398 | + + "<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa = this.checked' type=checkbox " | ||
399 | + + interno + " ></td><td>" + $trad("x39") + "</td></tr>"; | ||
400 | + if (i3GEO.Interface.ATUAL === "googlemaps") { | ||
401 | + if (i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google) { | ||
402 | + google = "checked"; | ||
403 | + } | ||
404 | + ins += | ||
405 | + "<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google = this.checked' type=checkbox " | ||
406 | + + google + " ></td><td>Google</td></tr>"; | ||
407 | + } else { | ||
408 | + i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google = false; | ||
409 | + } | ||
410 | + ins += "</table><br>" + "<p class=paragrafo >" + $trad("x40") + "</p>"; | ||
411 | + $i("i3GEOpropriedadesBuscaRapida" + id + "_corpo").innerHTML = ins; | ||
412 | + }; | ||
413 | + } | ||
485 | } | 414 | } |
486 | - } | ||
487 | - }, | ||
488 | - /** | ||
489 | - * Function: mostraHistoricoZoom | ||
490 | - * | ||
491 | - * Mostra na barra de zoom os ícones que controlam a | ||
492 | - * visualização do histórico da navegação | ||
493 | - * sobre o mapa | ||
494 | - * | ||
495 | - * Parametro: | ||
496 | - * | ||
497 | - * {String} - id do elemento HTML que receberá o resultado. Esse id | ||
498 | - * por default é obtido de i3GEO.gadgets.PARAMETROS | ||
499 | - */ | ||
500 | - mostraHistoricoZoom : function(id) { | ||
501 | - if (typeof (console) !== 'undefined') | ||
502 | - console.info("i3GEO.gadgets.mostraHistoricoZoom()"); | 415 | + }, |
416 | + /** | ||
417 | + * Function: mostraHistoricoZoom | ||
418 | + * | ||
419 | + * Mostra na barra de zoom os ícones que controlam a visualização do histórico da | ||
420 | + * navegação sobre o mapa | ||
421 | + * | ||
422 | + * Parametro: | ||
423 | + * | ||
424 | + * {String} - id do elemento HTML que receberá o resultado. Esse id por default é obtido de i3GEO.gadgets.PARAMETROS | ||
425 | + */ | ||
426 | + mostraHistoricoZoom : function(id) { | ||
427 | + if (typeof (console) !== 'undefined') | ||
428 | + console.info("i3GEO.gadgets.mostraHistoricoZoom()"); | ||
503 | 429 | ||
504 | - if (arguments.length === 0) { | ||
505 | - id = i3GEO.gadgets.PARAMETROS.mostraHistoricoZoom.idhtml; | ||
506 | - } | ||
507 | - if ($i(id)) { | ||
508 | - marcadorZoom = ""; | ||
509 | - var ins = "<table style='text-align:center;position:relative;left:"; | ||
510 | - if (navm) { | ||
511 | - ins += "0px;'>"; | ||
512 | - } else { | ||
513 | - ins += "6px;'>"; | 430 | + if (arguments.length === 0) { |
431 | + id = i3GEO.gadgets.PARAMETROS.mostraHistoricoZoom.idhtml; | ||
514 | } | 432 | } |
515 | - ins += "<tr><td><img id='i3geo_zoomanterior' class='zoomAnterior' title='anterior' src='" | ||
516 | - + i3GEO.configura.locaplic + "/imagens/branco.gif" | ||
517 | - + "' /></td>"; | ||
518 | - ins += "<td> </td>"; | ||
519 | - ins += "<td><img id='i3geo_zoomproximo' class='zoomProximo' title='proximo' src='" | ||
520 | - + i3GEO.configura.locaplic + "/imagens/branco.gif" | ||
521 | - + "' /></td>"; | ||
522 | - ins += "</tr></table>"; | ||
523 | - $i(id).innerHTML = ins; | ||
524 | - } | ||
525 | - }, | ||
526 | - /** | ||
527 | - * i3GEO.gadgets.visual (depreciado) | ||
528 | - * | ||
529 | - * Gera os ícones e controla as opções de | ||
530 | - * modificação do visual do mapa. | ||
531 | - * | ||
532 | - * O visual consiste na definição dos ícones utilizados | ||
533 | - * no mapa. O visual pode ser modificado na inicialização ou | ||
534 | - * então escolhido pelo usuário. | ||
535 | - * | ||
536 | - * Os visuais disponíveis são definidos no servidor e | ||
537 | - * consistem em diretórios localizados em i3geo/imagens/visual. A | ||
538 | - * lista de visuais disponíveis é obtida na | ||
539 | - * inicialização do i3geo. | ||
540 | - * | ||
541 | - * Os ícones para mudança do visual são | ||
542 | - * incluídos no elemento HTML definido em | ||
543 | - * i3geo.gadgets.PARAMETROS.visual | ||
544 | - */ | ||
545 | - visual : { | 433 | + if ($i(id)) { |
434 | + marcadorZoom = ""; | ||
435 | + var ins = "<table style='text-align:center;position:relative;left:"; | ||
436 | + if (navm) { | ||
437 | + ins += "0px;'>"; | ||
438 | + } else { | ||
439 | + ins += "6px;'>"; | ||
440 | + } | ||
441 | + ins += | ||
442 | + "<tr><td><img id='i3geo_zoomanterior' class='zoomAnterior' title='anterior' src='" + i3GEO.configura.locaplic | ||
443 | + + "/imagens/branco.gif" + "' /></td>"; | ||
444 | + ins += "<td> </td>"; | ||
445 | + ins += | ||
446 | + "<td><img id='i3geo_zoomproximo' class='zoomProximo' title='proximo' src='" + i3GEO.configura.locaplic | ||
447 | + + "/imagens/branco.gif" + "' /></td>"; | ||
448 | + ins += "</tr></table>"; | ||
449 | + $i(id).innerHTML = ins; | ||
450 | + } | ||
451 | + }, | ||
546 | /** | 452 | /** |
547 | - * Constrói os ícones de escolha do visual. | ||
548 | - * | ||
549 | - * Parametro: | ||
550 | - * | ||
551 | - * id {String} - id do elemento que receberá os ícones | ||
552 | - * (opcional) | 453 | + * i3GEO.gadgets.visual (depreciado) |
454 | + * | ||
455 | + * Gera os ícones e controla as opções de modificação do visual do mapa. | ||
456 | + * | ||
457 | + * O visual consiste na definição dos ícones utilizados no mapa. O visual pode ser modificado na | ||
458 | + * inicialização ou então escolhido pelo usuário. | ||
459 | + * | ||
460 | + * Os visuais disponíveis são definidos no servidor e consistem em diretórios localizados em | ||
461 | + * i3geo/imagens/visual. A lista de visuais disponíveis é obtida na inicialização do i3geo. | ||
462 | + * | ||
463 | + * Os ícones para mudança do visual são incluídos no elemento HTML definido em | ||
464 | + * i3geo.gadgets.PARAMETROS.visual | ||
553 | */ | 465 | */ |
554 | - inicia : function(id) { | ||
555 | - alert("A i3GEO.gadgets.visual foi depreciado"); | 466 | + visual : { |
467 | + /** | ||
468 | + * Constrói os ícones de escolha do visual. | ||
469 | + * | ||
470 | + * Parametro: | ||
471 | + * | ||
472 | + * id {String} - id do elemento que receberá os ícones (opcional) | ||
473 | + */ | ||
474 | + inicia : function(id) { | ||
475 | + alert("A i3GEO.gadgets.visual foi depreciado"); | ||
476 | + }, | ||
477 | + /** | ||
478 | + * Troca o visual atual. A lista de visuais disponíveis é obtida em i3GEO.parametros.listavisual | ||
479 | + * | ||
480 | + * Parametro: | ||
481 | + * | ||
482 | + * visual {String} - nome do visual que será utilizado. | ||
483 | + */ | ||
484 | + troca : function(visual) { | ||
485 | + alert("A i3GEO.gadgets.visual foi depreciado"); | ||
486 | + } | ||
556 | }, | 487 | }, |
557 | /** | 488 | /** |
558 | - * Troca o visual atual. A lista de visuais disponíveis é | ||
559 | - * obtida em i3GEO.parametros.listavisual | ||
560 | - * | 489 | + * Function: mostraMenuSuspenso |
490 | + * | ||
491 | + * Mostra o menu suspenso com opções extras de análise, ajuda, etc | ||
492 | + * | ||
493 | + * Paradefinir os ícones existentes nos elementos principais do menu, edite o arquivo i3geo/css/botoes2.css e acrescente o | ||
494 | + * estilo desejado. Utilize # para se referenciar ao elemento, cujo identificador é composto por "menu"+chave, exemplo | ||
495 | + * #menuinterface ou #menuajuda | ||
496 | + * | ||
497 | + * O objeto YAHOO.widget.MenuBar resultante pode ser obtido na variável i3GEOoMenuBar | ||
498 | + * | ||
499 | + * i3GEOoMenuBar pode ser manipulado com os métodos da biblioteca YUI | ||
500 | + * | ||
501 | + * Exemplo: | ||
502 | + * | ||
503 | + * (start code) i3GEOoMenuBar.getMenuItem("omenudataInterface1").cfg.setProperty("text", "zzzzzz"); | ||
504 | + * | ||
505 | + * i3GEOoMenuBar.getMenuItem("omenudataInterface1").destroy(); (end) | ||
506 | + * | ||
507 | + * Para executar uma operação após o menu ser montado, utilize a propriedade | ||
508 | + * i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.finaliza, por exemplo (a string é executada por meio da função | ||
509 | + * eval do javascript) | ||
510 | + * | ||
511 | + * Exemplo: | ||
512 | + * | ||
513 | + * (start code) i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.finaliza = | ||
514 | + * 'i3GEOoMenuBar.getMenuItem("omenudataInterface1").cfg.setProperty("text", "");'; (end) | ||
515 | + * | ||
516 | + * O conteúdo do menu é baseado na variável i3GEO.configura.oMenuData | ||
517 | + * | ||
561 | * Parametro: | 518 | * Parametro: |
562 | - * | ||
563 | - * visual {String} - nome do visual que será utilizado. | 519 | + * |
520 | + * {String} - id do elemento HTML que receberá o resultado. Esse id por default é obtido de i3GEO.gadgets.PARAMETROS | ||
564 | */ | 521 | */ |
565 | - troca : function(visual) { | ||
566 | - alert("A i3GEO.gadgets.visual foi depreciado"); | ||
567 | - } | ||
568 | - }, | ||
569 | - /** | ||
570 | - * Function: mostraMenuSuspenso | ||
571 | - * | ||
572 | - * Mostra o menu suspenso com opções extras de análise, | ||
573 | - * ajuda, etc | ||
574 | - * | ||
575 | - * Paradefinir os ícones existentes nos elementos principais do menu, | ||
576 | - * edite o arquivo i3geo/css/botoes2.css e acrescente o estilo desejado. | ||
577 | - * Utilize # para se referenciar ao elemento, cujo identificador é | ||
578 | - * composto por "menu"+chave, exemplo #menuinterface ou #menuajuda | ||
579 | - * | ||
580 | - * O objeto YAHOO.widget.MenuBar resultante pode ser obtido na | ||
581 | - * variável i3GEOoMenuBar | ||
582 | - * | ||
583 | - * i3GEOoMenuBar pode ser manipulado com os métodos da biblioteca YUI | ||
584 | - * | ||
585 | - * Exemplo: | ||
586 | - * | ||
587 | - * (start code) | ||
588 | - * i3GEOoMenuBar.getMenuItem("omenudataInterface1").cfg.setProperty("text", | ||
589 | - * "zzzzzz"); | ||
590 | - * | ||
591 | - * i3GEOoMenuBar.getMenuItem("omenudataInterface1").destroy(); (end) | ||
592 | - * | ||
593 | - * Para executar uma operação após o menu ser montado, | ||
594 | - * utilize a propriedade | ||
595 | - * i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.finaliza, por exemplo (a | ||
596 | - * string é executada por meio da função eval do | ||
597 | - * javascript) | ||
598 | - * | ||
599 | - * Exemplo: | ||
600 | - * | ||
601 | - * (start code) i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.finaliza = | ||
602 | - * 'i3GEOoMenuBar.getMenuItem("omenudataInterface1").cfg.setProperty("text", | ||
603 | - * "");'; (end) | ||
604 | - * | ||
605 | - * O conteúdo do menu é baseado na variável | ||
606 | - * i3GEO.configura.oMenuData | ||
607 | - * | ||
608 | - * Parametro: | ||
609 | - * | ||
610 | - * {String} - id do elemento HTML que receberá o resultado. Esse id | ||
611 | - * por default é obtido de i3GEO.gadgets.PARAMETROS | ||
612 | - */ | ||
613 | - mostraMenuSuspenso : function(id) { | ||
614 | - if (typeof (console) !== 'undefined') | ||
615 | - console.info("i3GEO.gadgets.mostraMenuSuspenso()"); | 522 | + mostraMenuSuspenso : function(id) { |
523 | + if (typeof (console) !== 'undefined') | ||
524 | + console.info("i3GEO.gadgets.mostraMenuSuspenso()"); | ||
616 | 525 | ||
617 | - var objid, n, i, estilo, t, onMenuBarBeforeRender, temp, i3GEOoMenuBarLocal, ms = i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso, confm = i3GEO.configura.oMenuData, ins = "", alinhamento = ""; | 526 | + var objid, n, i, estilo, t, onMenuBarBeforeRender, temp, i3GEOoMenuBarLocal, ms = i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso, confm = |
527 | + i3GEO.configura.oMenuData, ins = "", alinhamento = ""; | ||
618 | 528 | ||
619 | - if (arguments.length === 0) { | ||
620 | - id = ms.idhtml; | ||
621 | - } else { | ||
622 | - ms.idhtml = id; | ||
623 | - } | ||
624 | - objid = $i(id); | ||
625 | - if (!objid) { | ||
626 | - return; | ||
627 | - } | ||
628 | - // cria o menu se ainda não existir | ||
629 | - if (i3GEO.util.trim(objid.innerHTML) === "") { | ||
630 | - try { | ||
631 | - if (ms.marcadores === true) { | ||
632 | - // complementa o array com os dados para o menu de | ||
633 | - // marcadores | ||
634 | - i3GEO.configura.oMenuData = i3GEO.marcador.adicionaMenuSuspenso(i3GEO.configura.oMenuData); | ||
635 | - } | ||
636 | - } catch (e) { | 529 | + if (arguments.length === 0) { |
530 | + id = ms.idhtml; | ||
531 | + } else { | ||
532 | + ms.idhtml = id; | ||
637 | } | 533 | } |
638 | - // inclui opcoes admin | ||
639 | - try { | ||
640 | - if (ms.permiteLogin === true || (ms.permiteLogin != false | ||
641 | - && i3GEO.parametros.editor === "sim")) { | ||
642 | - i3GEO.configura.oMenuData = i3GEO.login.adicionaMenuSuspenso(i3GEO.configura.oMenuData); | ||
643 | - } | ||
644 | - } catch (e) { | 534 | + objid = $i(id); |
535 | + if (!objid) { | ||
536 | + return; | ||
645 | } | 537 | } |
646 | - i3GEOoMenuBar = YAHOO.widget.MenuManager; | ||
647 | - if (objid) { | ||
648 | - objid.className = "yuimenubar"; | ||
649 | - temp = $i("contemMenu"); | ||
650 | - if (temp) { | ||
651 | - temp.className = "yui-navset"; | ||
652 | - } | ||
653 | - if (ms.deslocaEsquerda) { | ||
654 | - alinhamento = "left:" | ||
655 | - + ms.deslocaEsquerda | ||
656 | - * -1 | ||
657 | - + "px;"; | ||
658 | - } | ||
659 | - // ajusta a altura caso não tenha sido especificado no | ||
660 | - // HTML | ||
661 | - if (temp | ||
662 | - && (!temp.style.height || parseInt(temp.style.height) === 0)) { | ||
663 | - temp.style.height = "30px"; | 538 | + // cria o menu se ainda não existir |
539 | + if (i3GEO.util.trim(objid.innerHTML) === "") { | ||
540 | + try { | ||
541 | + if (ms.marcadores === true) { | ||
542 | + // complementa o array com os dados para o menu de | ||
543 | + // marcadores | ||
544 | + i3GEO.configura.oMenuData = i3GEO.marcador.adicionaMenuSuspenso(i3GEO.configura.oMenuData); | ||
545 | + } | ||
546 | + } catch (e) { | ||
664 | } | 547 | } |
665 | - if (objid.style.height | ||
666 | - && parseInt( | ||
667 | - objid.style.height, | ||
668 | - 10) === 0) { | ||
669 | - objid.style.height = "0px"; | 548 | + // inclui opcoes admin |
549 | + try { | ||
550 | + if (ms.permiteLogin === true || (ms.permiteLogin != false && i3GEO.parametros.editor === "sim")) { | ||
551 | + i3GEO.configura.oMenuData = i3GEO.login.adicionaMenuSuspenso(i3GEO.configura.oMenuData); | ||
552 | + } | ||
553 | + } catch (e) { | ||
670 | } | 554 | } |
555 | + i3GEOoMenuBar = YAHOO.widget.MenuManager; | ||
556 | + if (objid) { | ||
557 | + objid.className = "yuimenubar"; | ||
558 | + temp = $i("contemMenu"); | ||
559 | + if (temp) { | ||
560 | + temp.className = "yui-navset"; | ||
561 | + } | ||
562 | + if (ms.deslocaEsquerda) { | ||
563 | + alinhamento = "left:" + ms.deslocaEsquerda * -1 + "px;"; | ||
564 | + } | ||
565 | + // ajusta a altura caso não tenha sido especificado no | ||
566 | + // HTML | ||
567 | + if (temp && (!temp.style.height || parseInt(temp.style.height) === 0)) { | ||
568 | + temp.style.height = "30px"; | ||
569 | + } | ||
570 | + if (objid.style.height && parseInt(objid.style.height, 10) === 0) { | ||
571 | + objid.style.height = "0px"; | ||
572 | + } | ||
671 | 573 | ||
672 | - ins += '<div class="bd" style="top:0px;' | ||
673 | - + alinhamento | ||
674 | - + 'display:block;align:right;border: 0px solid white;z-index:3;line-height:1.4" >' | ||
675 | - + '<ul class="first-of-type" style="display:block;border:0px solid white;top:10px;">'; | ||
676 | - n = confm.menu.length; | ||
677 | - estilo = "padding-bottom:3px;top:0px;border: 0px solid white;"; | ||
678 | - for (i = 0; i < n; i += 1) { | ||
679 | - t = ""; | ||
680 | - if (confm.menu[i].target) { | ||
681 | - t = "target=" | ||
682 | - + confm.menu[i].target; | 574 | + ins += |
575 | + '<div class="bd" style="top:0px;' + alinhamento | ||
576 | + + 'display:block;align:right;border: 0px solid white;z-index:3;line-height:1.4" >' | ||
577 | + + '<ul class="first-of-type" style="display:block;border:0px solid white;top:10px;">'; | ||
578 | + n = confm.menu.length; | ||
579 | + estilo = "padding-bottom:3px;top:0px;border: 0px solid white;"; | ||
580 | + for (i = 0; i < n; i += 1) { | ||
581 | + t = ""; | ||
582 | + if (confm.menu[i].target) { | ||
583 | + t = "target=" + confm.menu[i].target; | ||
584 | + } | ||
585 | + if (confm.submenus[confm.menu[i].id].length > 0) { | ||
586 | + ins += | ||
587 | + '<li class="yuimenubaritem" style="padding-top:2px;"><a style="' + estilo | ||
588 | + + '" href="#" class="yuimenubaritemlabel" ' + t + 'id="menu' + confm.menu[i].id + '" > ' | ||
589 | + + confm.menu[i].nome + '</a></li>'; | ||
590 | + } | ||
683 | } | 591 | } |
684 | - if (confm.submenus[confm.menu[i].id].length > 0) { | ||
685 | - ins += '<li class="yuimenubaritem" style="padding-top:2px;"><a style="' | ||
686 | - + estilo | ||
687 | - + '" href="#" class="yuimenubaritemlabel" ' | ||
688 | - + t | ||
689 | - + 'id="menu' | ||
690 | - + confm.menu[i].id | ||
691 | - + '" > ' | ||
692 | - + confm.menu[i].nome | ||
693 | - + '</a></li>'; | 592 | + ins += '</ul>'; |
593 | + ins += '</div>'; | ||
594 | + objid.innerHTML = ins; | ||
595 | + if (i3GEO.Interface.ATUAL === "googleearth") { | ||
596 | + i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI.iframe = true; | ||
694 | } | 597 | } |
695 | - } | ||
696 | - ins += '</ul>'; | ||
697 | - ins += '</div>'; | ||
698 | - objid.innerHTML = ins; | ||
699 | - if (i3GEO.Interface.ATUAL === "googleearth") { | ||
700 | - i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI.iframe = true; | ||
701 | - } | ||
702 | - i3GEOoMenuBarLocal = new YAHOO.widget.MenuBar( | ||
703 | - id, i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI); | ||
704 | - onMenuBarBeforeRender = function(p_sType, p_sArgs) { | ||
705 | - var nomeMenu = "", nomeSub, subs = i3GEO.configura.oMenuData.submenus, conta = 0; | ||
706 | - for (nomeMenu in subs) { | ||
707 | - if ($i("menu" | ||
708 | - + nomeMenu)) { | ||
709 | - nomeSub = subs[nomeMenu]; | ||
710 | - if (nomeSub !== "") { | ||
711 | - i3GEOoMenuBarLocal.getItem(conta).cfg.setProperty( | ||
712 | - 'submenu', | ||
713 | - { | 598 | + i3GEOoMenuBarLocal = new YAHOO.widget.MenuBar(id, i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI); |
599 | + onMenuBarBeforeRender = function(p_sType, p_sArgs) { | ||
600 | + var nomeMenu = "", nomeSub, subs = i3GEO.configura.oMenuData.submenus, conta = 0; | ||
601 | + for (nomeMenu in subs) { | ||
602 | + if ($i("menu" + nomeMenu)) { | ||
603 | + nomeSub = subs[nomeMenu]; | ||
604 | + if (nomeSub !== "") { | ||
605 | + i3GEOoMenuBarLocal.getItem(conta).cfg.setProperty('submenu', { | ||
714 | id : nomeMenu, | 606 | id : nomeMenu, |
715 | itemdata : nomeSub | 607 | itemdata : nomeSub |
716 | }); | 608 | }); |
609 | + } | ||
610 | + conta += 1; | ||
717 | } | 611 | } |
718 | - conta += 1; | ||
719 | } | 612 | } |
720 | - } | ||
721 | - }; | ||
722 | - // esses eventos fazem com que os itens de um menu fiquem sempre | ||
723 | - // sobre outros elementos do mapa | ||
724 | - temp = $i("contemMenu"); | ||
725 | - if (temp) { | ||
726 | - i3GEOoMenuBarLocal.subscribe( | ||
727 | - "beforeShow", | ||
728 | - function() { | 613 | + }; |
614 | + // esses eventos fazem com que os itens de um menu fiquem sempre | ||
615 | + // sobre outros elementos do mapa | ||
616 | + temp = $i("contemMenu"); | ||
617 | + if (temp) { | ||
618 | + i3GEOoMenuBarLocal.subscribe("beforeShow", function() { | ||
729 | $i("contemMenu").style.zIndex = 5000; | 619 | $i("contemMenu").style.zIndex = 5000; |
730 | return; | 620 | return; |
731 | - }, | ||
732 | - i3GEO.configura.oMenuData.submenus); | ||
733 | - i3GEOoMenuBarLocal.subscribe( | ||
734 | - "beforeHide", | ||
735 | - function() { | 621 | + }, i3GEO.configura.oMenuData.submenus); |
622 | + i3GEOoMenuBarLocal.subscribe("beforeHide", function() { | ||
736 | $i("contemMenu").style.zIndex = 1; | 623 | $i("contemMenu").style.zIndex = 1; |
737 | return; | 624 | return; |
738 | - }, | ||
739 | - i3GEO.configura.oMenuData.submenus); | 625 | + }, i3GEO.configura.oMenuData.submenus); |
626 | + } | ||
627 | + i3GEOoMenuBar.addMenu(i3GEOoMenuBarLocal); | ||
628 | + i3GEOoMenuBarLocal.beforeRenderEvent.subscribe(onMenuBarBeforeRender); | ||
629 | + i3GEOoMenuBarLocal.render(); | ||
740 | } | 630 | } |
741 | - i3GEOoMenuBar.addMenu(i3GEOoMenuBarLocal); | ||
742 | - i3GEOoMenuBarLocal.beforeRenderEvent.subscribe(onMenuBarBeforeRender); | ||
743 | - i3GEOoMenuBarLocal.render(); | ||
744 | } | 631 | } |
745 | - } | ||
746 | - // | ||
747 | - // marca o tipo de interface em uso | ||
748 | - // | ||
749 | - temp = [ | ||
750 | - "omenudataInterface1", | ||
751 | - "omenudataInterface2", | ||
752 | - "omenudataInterface3", | ||
753 | - "omenudataInterface4", | ||
754 | - "omenudataInterface5" | ||
755 | - ]; | ||
756 | - n = temp.length; | ||
757 | - while (n > 0) { | ||
758 | - n -= 1; | ||
759 | - i = i3GEOoMenuBar.getMenuItem(temp[n]); | ||
760 | - if (i) { | ||
761 | - i.cfg.setProperty( | ||
762 | - "checked", | ||
763 | - false); | ||
764 | - } | ||
765 | - } | ||
766 | - try { | ||
767 | - temp = ""; | ||
768 | - switch (i3GEO.Interface.ATUAL) { | ||
769 | - case "openlayers": | ||
770 | - temp = "omenudataInterface2"; | ||
771 | - break; | ||
772 | - case "googlemaps": | ||
773 | - temp = "omenudataInterface4"; | ||
774 | - break; | ||
775 | - case "googleearth": | ||
776 | - temp = "omenudataInterface5"; | ||
777 | - break; | ||
778 | - } | ||
779 | - if (temp != "" | ||
780 | - && $i(temp)) { | ||
781 | - i3GEOoMenuBar.getMenuItem(temp).cfg.setProperty( | ||
782 | - "checked", | ||
783 | - true); | 632 | + // |
633 | + // marca o tipo de interface em uso | ||
634 | + // | ||
635 | + temp = [ | ||
636 | + "omenudataInterface1", | ||
637 | + "omenudataInterface2", | ||
638 | + "omenudataInterface3", | ||
639 | + "omenudataInterface4", | ||
640 | + "omenudataInterface5" | ||
641 | + ]; | ||
642 | + n = temp.length; | ||
643 | + while (n > 0) { | ||
644 | + n -= 1; | ||
645 | + i = i3GEOoMenuBar.getMenuItem(temp[n]); | ||
646 | + if (i) { | ||
647 | + i.cfg.setProperty("checked", false); | ||
648 | + } | ||
784 | } | 649 | } |
785 | - } catch (e) { | ||
786 | - if (typeof (console) !== 'undefined') | ||
787 | - console.warning("i3GEO.gadgets.mostraMenuSuspenso() "); | 650 | + try { |
651 | + temp = ""; | ||
652 | + switch (i3GEO.Interface.ATUAL) { | ||
653 | + case "openlayers": | ||
654 | + temp = "omenudataInterface2"; | ||
655 | + break; | ||
656 | + case "googlemaps": | ||
657 | + temp = "omenudataInterface4"; | ||
658 | + break; | ||
659 | + case "googleearth": | ||
660 | + temp = "omenudataInterface5"; | ||
661 | + break; | ||
662 | + } | ||
663 | + if (temp != "" && $i(temp)) { | ||
664 | + i3GEOoMenuBar.getMenuItem(temp).cfg.setProperty("checked", true); | ||
665 | + } | ||
666 | + } catch (e) { | ||
667 | + if (typeof (console) !== 'undefined') | ||
668 | + console.warning("i3GEO.gadgets.mostraMenuSuspenso() "); | ||
788 | 669 | ||
789 | - } | ||
790 | - // | ||
791 | - // desabilita opções em interfaces específicas | ||
792 | - // | ||
793 | - temp = [ | ||
794 | - "omenudataFerramentas7b", | ||
795 | - "omenudataArquivos3", | ||
796 | - "omenudataJanelas1", | ||
797 | - "omenudataJanelas3", | ||
798 | - "omenudataFerramentas2a" | ||
799 | - ]; | ||
800 | - n = temp.length; | ||
801 | - while (n > 0) { | ||
802 | - n -= 1; | ||
803 | - i = i3GEOoMenuBar.getMenuItem(temp[n]); | ||
804 | - if (i) { | ||
805 | - i.cfg.setProperty( | ||
806 | - "disabled", | ||
807 | - false); | ||
808 | } | 670 | } |
809 | - } | ||
810 | - try { | ||
811 | - temp = []; | ||
812 | - switch (i3GEO.Interface.ATUAL) { | ||
813 | - case "openlayers": | ||
814 | - temp = [ | ||
815 | - "omenudataArquivos3", | ||
816 | - "omenudataJanelas1" | ||
817 | - ]; | ||
818 | - break; | ||
819 | - case "googlemaps": | ||
820 | - temp = [ | ||
821 | - "omenudataArquivos3", | ||
822 | - "omenudataJanelas1", | ||
823 | - "omenudataJanelas3" | ||
824 | - ]; | ||
825 | - break; | ||
826 | - case "googleearth": | ||
827 | - temp = [ | ||
828 | - "omenudataFerramentas7b", | ||
829 | - "omenudataArquivos3", | ||
830 | - "omenudataJanelas3", | ||
831 | - "omenudataFerramentas2a" | ||
832 | - ]; | ||
833 | - break; | ||
834 | - } | ||
835 | - ; | 671 | + // |
672 | + // desabilita opções em interfaces específicas | ||
673 | + // | ||
674 | + temp = [ | ||
675 | + "omenudataFerramentas7b", | ||
676 | + "omenudataArquivos3", | ||
677 | + "omenudataJanelas1", | ||
678 | + "omenudataJanelas3", | ||
679 | + "omenudataFerramentas2a" | ||
680 | + ]; | ||
836 | n = temp.length; | 681 | n = temp.length; |
837 | while (n > 0) { | 682 | while (n > 0) { |
838 | n -= 1; | 683 | n -= 1; |
839 | i = i3GEOoMenuBar.getMenuItem(temp[n]); | 684 | i = i3GEOoMenuBar.getMenuItem(temp[n]); |
840 | if (i) { | 685 | if (i) { |
841 | - i.cfg.setProperty( | ||
842 | - "disabled", | ||
843 | - true); | 686 | + i.cfg.setProperty("disabled", false); |
844 | } | 687 | } |
845 | } | 688 | } |
846 | - } catch (e) { | ||
847 | - } | ||
848 | - // | ||
849 | - // corrige problemas de estilo | ||
850 | - // | ||
851 | - temp = objid.style; | ||
852 | - temp.backgroundPosition = "0px -1px"; | ||
853 | - temp.border = "0px solid white"; | ||
854 | - // if(navm) | ||
855 | - // {temp.borderBottom = "2px solid white";} | ||
856 | - // if(navm && i3GEO.Interface.ATUAL === "googlemaps") | ||
857 | - // {temp.border = "2px dotted white";} | ||
858 | - if (ms.finaliza | ||
859 | - && ms.finaliza != "") { | ||
860 | - eval(ms.finaliza); | ||
861 | - } | ||
862 | - }, | ||
863 | - /** | ||
864 | - * Function: mostraMenuLista | ||
865 | - * | ||
866 | - * Mostra as opções existentes no menu suspenso porém | ||
867 | - * na forma de uma lista de opções | ||
868 | - * | ||
869 | - * O conteúdo do menu é baseado na variável | ||
870 | - * i3GEO.configura.oMenuData | ||
871 | - * | ||
872 | - * Parametro: | ||
873 | - * | ||
874 | - * {String} - id do elemento HTML que receberá o resultado. Esse id | ||
875 | - * por default é obtido de i3GEO.gadgets.PARAMETROS | ||
876 | - */ | ||
877 | - mostraMenuLista : function(id) { | ||
878 | - var objid, n, i, sub, nomeMenu = "", ms = i3GEO.gadgets.PARAMETROS.mostraMenuLista, confm = i3GEO.configura.oMenuData, ins = "", subs = i3GEO.configura.oMenuData.submenus; | ||
879 | - if (arguments.length === 0) { | ||
880 | - id = ms.idhtml; | ||
881 | - } else { | ||
882 | - ms.idhtml = id; | ||
883 | - } | ||
884 | - objid = $i(id); | ||
885 | - if (objid) { | ||
886 | - n = confm.menu.length; | ||
887 | - for (i = 0; i < n; i += 1) { | ||
888 | - ins += '<div class="listaMenuTitulo" id=menulista_' | ||
889 | - + confm.menu[i].id | ||
890 | - + '>' | ||
891 | - + confm.menu[i].nome | ||
892 | - + '</div>'; | 689 | + try { |
690 | + temp = []; | ||
691 | + switch (i3GEO.Interface.ATUAL) { | ||
692 | + case "openlayers": | ||
693 | + temp = [ | ||
694 | + "omenudataArquivos3", | ||
695 | + "omenudataJanelas1" | ||
696 | + ]; | ||
697 | + break; | ||
698 | + case "googlemaps": | ||
699 | + temp = [ | ||
700 | + "omenudataArquivos3", | ||
701 | + "omenudataJanelas1", | ||
702 | + "omenudataJanelas3" | ||
703 | + ]; | ||
704 | + break; | ||
705 | + case "googleearth": | ||
706 | + temp = [ | ||
707 | + "omenudataFerramentas7b", | ||
708 | + "omenudataArquivos3", | ||
709 | + "omenudataJanelas3", | ||
710 | + "omenudataFerramentas2a" | ||
711 | + ]; | ||
712 | + break; | ||
713 | + } | ||
714 | + ; | ||
715 | + n = temp.length; | ||
716 | + while (n > 0) { | ||
717 | + n -= 1; | ||
718 | + i = i3GEOoMenuBar.getMenuItem(temp[n]); | ||
719 | + if (i) { | ||
720 | + i.cfg.setProperty("disabled", true); | ||
721 | + } | ||
722 | + } | ||
723 | + } catch (e) { | ||
724 | + } | ||
725 | + // | ||
726 | + // corrige problemas de estilo | ||
727 | + // | ||
728 | + temp = objid.style; | ||
729 | + temp.backgroundPosition = "0px -1px"; | ||
730 | + temp.border = "0px solid white"; | ||
731 | + // if(navm) | ||
732 | + // {temp.borderBottom = "2px solid white";} | ||
733 | + // if(navm && i3GEO.Interface.ATUAL === "googlemaps") | ||
734 | + // {temp.border = "2px dotted white";} | ||
735 | + if (ms.finaliza && ms.finaliza != "") { | ||
736 | + eval(ms.finaliza); | ||
737 | + } | ||
738 | + }, | ||
739 | + /** | ||
740 | + * Function: mostraMenuLista | ||
741 | + * | ||
742 | + * Mostra as opções existentes no menu suspenso porém na forma de uma lista de opções | ||
743 | + * | ||
744 | + * O conteúdo do menu é baseado na variável i3GEO.configura.oMenuData | ||
745 | + * | ||
746 | + * Parametro: | ||
747 | + * | ||
748 | + * {String} - id do elemento HTML que receberá o resultado. Esse id por default é obtido de i3GEO.gadgets.PARAMETROS | ||
749 | + */ | ||
750 | + mostraMenuLista : function(id) { | ||
751 | + var objid, n, i, sub, nomeMenu = "", ms = i3GEO.gadgets.PARAMETROS.mostraMenuLista, confm = i3GEO.configura.oMenuData, ins = "", subs = | ||
752 | + i3GEO.configura.oMenuData.submenus; | ||
753 | + if (arguments.length === 0) { | ||
754 | + id = ms.idhtml; | ||
755 | + } else { | ||
756 | + ms.idhtml = id; | ||
893 | } | 757 | } |
894 | - objid.innerHTML = ins; | ||
895 | - for (nomeMenu in subs) { | ||
896 | - if ($i("menulista_" | ||
897 | - + nomeMenu)) { | ||
898 | - sub = subs[nomeMenu]; | ||
899 | - n = sub.length; | ||
900 | - ins = ""; | ||
901 | - for (i = 0; i < n; i++) { | ||
902 | - ins += "<p class='listaMenuItem' ><a href='" | ||
903 | - + sub[i].url | ||
904 | - + "' target='_self'>" | ||
905 | - + sub[i].text | ||
906 | - + "</a>"; | 758 | + objid = $i(id); |
759 | + if (objid) { | ||
760 | + n = confm.menu.length; | ||
761 | + for (i = 0; i < n; i += 1) { | ||
762 | + ins += '<div class="listaMenuTitulo" id=menulista_' + confm.menu[i].id + '>' + confm.menu[i].nome + '</div>'; | ||
763 | + } | ||
764 | + objid.innerHTML = ins; | ||
765 | + for (nomeMenu in subs) { | ||
766 | + if ($i("menulista_" + nomeMenu)) { | ||
767 | + sub = subs[nomeMenu]; | ||
768 | + n = sub.length; | ||
769 | + ins = ""; | ||
770 | + for (i = 0; i < n; i++) { | ||
771 | + ins += "<p class='listaMenuItem' ><a href='" + sub[i].url + "' target='_self'>" + sub[i].text + "</a>"; | ||
772 | + } | ||
773 | + $i("menulista_" + nomeMenu).innerHTML += ins; | ||
907 | } | 774 | } |
908 | - $i("menulista_" | ||
909 | - + nomeMenu).innerHTML += ins; | ||
910 | } | 775 | } |
911 | } | 776 | } |
912 | } | 777 | } |
913 | - } | ||
914 | -}; | ||
915 | \ No newline at end of file | 778 | \ No newline at end of file |
779 | + }; | ||
916 | \ No newline at end of file | 780 | \ No newline at end of file |
classesjs/compactados/classe_gadgets_compacto.js
1 | -if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.gadgets={PARAMETROS:{"mostraInserirKml":{idhtml:"inserirKml"},"mostraEscalaNumerica":{idhtml:"escala"},"mostraEscalaGrafica":{idhtml:"escalaGrafica"},"mostraBuscaRapida":{idhtml:"buscaRapida",servicosexternos:true,temasmapa:false,google:true},"mostraVisual":{idhtml:""},"mostraHistoricoZoom":{idhtml:"historicozoom"},"mostraMenuSuspenso":{permiteLogin:true,marcadores:true,idhtml:"menus",deslocaEsquerda:0,parametrosYUI:{iframe:false,autosubmenudisplay:false,showdelay:200,hidedelay:500,lazyload:false}},"mostraMenuLista":{idhtml:"menuLista"},"mostraVersao":{idhtml:"versaoi3geo"},"mostraEmail":{idhtml:"emailInstituicao"}},mostraEmail:function(id){if(arguments.length===0||id===""){id=i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml}else{i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml=id}i3GEO.util.defineValor(id,"innerHTML",i3GEO.parametros.emailInstituicao)},mostraVersao:function(id){if(arguments.length===0||id===""){id=i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml}else{i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml=id}i3GEO.util.defineValor(id,"innerHTML",i3GEO.parametros.mensageminicia)},mostraInserirKml:function(id){var i,ins,temp;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml}if($i(id)){if(!$i("i3geo_urlkml")){i=$inputText(id,"290","i3geo_urlkml","kml url","35","kml");ins="<table><tr><td>"+i;temp='i3GEO.Interface.adicionaKml();';ins+="</td><td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' class='tic' onclick='"+temp+"' /></td></tr></table>";$i(id).innerHTML=ins}}},mostraEscalaNumerica:function(id){var i,ins,temp,onde;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraEscalaNumerica.idhtml}onde=$i(id);if(onde){if(onde.style.display=="none"){onde.style.display="block"}if(!$i("i3geo_escalanum")){i="<form id='i3GEOescalanumForm' >"+$inputText(id,"100","i3geo_escalanum",$trad("d10"),"10",parseInt(i3GEO.parametros.mapscale,10))+"</form>";ins="<table style='width:120px;'><tr><td>"+i;temp='var nova = document.getElementById("i3geo_escalanum").value;';temp+='i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,nova);';ins+="</td></tr></table>";onde.innerHTML=ins;$i("i3GEOescalanumForm").onsubmit=function(){i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,document.getElementById("i3geo_escalanum").value);return false}}i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"])}},atualizaEscalaNumerica:function(escala){var e=$i("i3geo_escalanum");if(!e){i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"]);return}if(arguments.length===1){e.value=escala}else{if(i3GEO.parametros.mapscale!==""){e.value=parseInt(i3GEO.parametros.mapscale,10)}else{e.value=0}}},mostraEscalaGrafica:function(id){if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraEscalaGrafica.idhtml}var ins;if($i(id)){if(!$i("imagemEscalaGrafica")){ins="<img class='menuarrow' src=\""+i3GEO.configura.locaplic+"/imagens/branco.gif\" title='opções' onclick='i3GEO.mapa.dialogo.opcoesEscala()' style='cursor:pointer'/><img id=imagemEscalaGrafica src='' />";$i(id).innerHTML=ins}i3GEO.gadgets.atualizaEscalaGrafica();i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"])}},atualizaEscalaGrafica:function(){var e=$i("imagemEscalaGrafica");if(!e){i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"]);return}temp=function(retorno){eval(retorno.data);$i("imagemEscalaGrafica").src=scaimagem};i3GEO.php.escalagrafica(temp)},mostraBuscaRapida:function(id){var i,ins,temp,fbusca;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.idhtml}i3GEO.gadgets.mostraBuscaRapida.id=id;if($i(id)){i="<form id=i3GEObotaoFormBuscaRapida"+id+" >"+"<div class='i3geoForm' style='width:160px;'><input class=i3geoFormSemIcone type=text value='' id='valorBuscaRapida"+id+"' /></div>"+"</form>";ins="<table><tr><td><a class=ajuda_usuario target=_blank href='"+i3GEO.configura.locaplic+"/ajuda_usuario.php?idcategoria=8&idajuda=71' > </a></td><td>"+i+"</td>";ins+="<td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' title='"+$trad("p13")+"' class='ticPropriedades2' id=i3GEObotaoPropriedadesBuscaRapida"+id+" style='margin-right:5px;margin-left:5px;'/></td>";ins+="<td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' class='ticfind' id=i3GEObotaoBuscaRapida"+id+" /></td></tr></table>";temp=$i(id);if(temp){fbusca=function(){if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google===false&&i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos===false&&i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa===false){i3GEO.janela.tempoMsg($trad("x35"));return}if($i("valorBuscaRapida"+id).value===""){i3GEO.janela.tempoMsg($trad("x36"));return}i3GEO.janela.cria("300px","280px",i3GEO.configura.locaplic+"/ferramentas/buscarapida/index.htm","","",$trad("o2"));return false};temp.innerHTML=ins;$i("i3GEObotaoBuscaRapida"+id).onclick=fbusca;$i("i3GEObotaoFormBuscaRapida"+id).onsubmit=fbusca;$i("i3GEObotaoPropriedadesBuscaRapida"+id).onclick=function(){var ins,interno="",externo="",google="";i3GEO.janela.cria("300px","150px","","","",$trad("s5"),"i3GEOpropriedadesBuscaRapida"+id);if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos){externo="checked"}if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa){interno="checked"}ins="<p class=paragrafo >"+$trad("x37")+":</p>"+"<table class=lista3 >"+"<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos = this.checked' type=checkbox "+externo+" ></td><td> "+$trad("x38")+"</td></tr>"+"<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa = this.checked' type=checkbox "+interno+" ></td><td>"+$trad("x39")+"</td></tr>";if(i3GEO.Interface.ATUAL==="googlemaps"){if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google){google="checked"}ins+="<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google = this.checked' type=checkbox "+google+" ></td><td>Google</td></tr>"}else{i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google=false}ins+="</table><br>"+"<p class=paragrafo >"+$trad("x40")+"</p>";$i("i3GEOpropriedadesBuscaRapida"+id+"_corpo").innerHTML=ins}}}},mostraHistoricoZoom:function(id){if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraHistoricoZoom.idhtml}if($i(id)){marcadorZoom="";var ins="<table style='text-align:center;position:relative;left:";if(navm){ins+="0px;'>"}else{ins+="6px;'>"}ins+="<tr><td><img id='i3geo_zoomanterior' class='zoomAnterior' title='anterior' src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' /></td>";ins+="<td> </td>";ins+="<td><img id='i3geo_zoomproximo' class='zoomProximo' title='proximo' src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' /></td>";ins+="</tr></table>";$i(id).innerHTML=ins}},visual:{inicia:function(id){alert("A i3GEO.gadgets.visual foi depreciado")},troca:function(visual){alert("A i3GEO.gadgets.visual foi depreciado")}},mostraMenuSuspenso:function(id){var objid,n,i,estilo,t,onMenuBarBeforeRender,temp,i3GEOoMenuBarLocal,ms=i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso,confm=i3GEO.configura.oMenuData,ins="",alinhamento="";if(arguments.length===0){id=ms.idhtml}else{ms.idhtml=id}objid=$i(id);if(!objid){return}if(i3GEO.util.trim(objid.innerHTML)===""){try{if(ms.marcadores===true){i3GEO.configura.oMenuData=i3GEO.marcador.adicionaMenuSuspenso(i3GEO.configura.oMenuData)}}catch(e){}try{if(ms.permiteLogin===true||(ms.permiteLogin!=false&&i3GEO.parametros.editor==="sim")){i3GEO.configura.oMenuData=i3GEO.login.adicionaMenuSuspenso(i3GEO.configura.oMenuData)}}catch(e){}i3GEOoMenuBar=YAHOO.widget.MenuManager;if(objid){objid.className="yuimenubar";temp=$i("contemMenu");if(temp){temp.className="yui-navset"}if(ms.deslocaEsquerda){alinhamento="left:"+ms.deslocaEsquerda*-1+"px;"}if(temp&&(!temp.style.height||parseInt(temp.style.height)===0)){temp.style.height="30px"}if(objid.style.height&&parseInt(objid.style.height,10)===0){objid.style.height="0px"}ins+='<div class="bd" style="top:0px;'+alinhamento+'display:block;align:right;border: 0px solid white;z-index:3;line-height:1.4" >'+'<ul class="first-of-type" style="display:block;border:0px solid white;top:10px;">';n=confm.menu.length;estilo="padding-bottom:3px;top:0px;border: 0px solid white;";for(i=0;i<n;i+=1){t="";if(confm.menu[i].target){t="target="+confm.menu[i].target}if(confm.submenus[confm.menu[i].id].length>0){ins+='<li class="yuimenubaritem" style="padding-top:2px;"><a style="'+estilo+'" href="#" class="yuimenubaritemlabel" '+t+'id="menu'+confm.menu[i].id+'" > '+confm.menu[i].nome+'</a></li>'}}ins+='</ul>';ins+='</div>';objid.innerHTML=ins;if(i3GEO.Interface.ATUAL==="googleearth"){i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI.iframe=true}i3GEOoMenuBarLocal=new YAHOO.widget.MenuBar(id,i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI);onMenuBarBeforeRender=function(p_sType,p_sArgs){var nomeMenu="",nomeSub,subs=i3GEO.configura.oMenuData.submenus,conta=0;for(nomeMenu in subs){if($i("menu"+nomeMenu)){nomeSub=subs[nomeMenu];if(nomeSub!==""){i3GEOoMenuBarLocal.getItem(conta).cfg.setProperty('submenu',{id:nomeMenu,itemdata:nomeSub})}conta+=1}}};temp=$i("contemMenu");if(temp){i3GEOoMenuBarLocal.subscribe("beforeShow",function(){$i("contemMenu").style.zIndex=5000;return},i3GEO.configura.oMenuData.submenus);i3GEOoMenuBarLocal.subscribe("beforeHide",function(){$i("contemMenu").style.zIndex=1;return},i3GEO.configura.oMenuData.submenus)}i3GEOoMenuBar.addMenu(i3GEOoMenuBarLocal);i3GEOoMenuBarLocal.beforeRenderEvent.subscribe(onMenuBarBeforeRender);i3GEOoMenuBarLocal.render()}}temp=["omenudataInterface1","omenudataInterface2","omenudataInterface3","omenudataInterface4","omenudataInterface5"];n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("checked",false)}}try{temp="";switch(i3GEO.Interface.ATUAL){case"openlayers":temp="omenudataInterface2";break;case"googlemaps":temp="omenudataInterface4";break;case"googleearth":temp="omenudataInterface5";break}if(temp!=""&&$i(temp)){i3GEOoMenuBar.getMenuItem(temp).cfg.setProperty("checked",true)}}catch(e){}temp=["omenudataFerramentas7b","omenudataArquivos3","omenudataJanelas1","omenudataJanelas3","omenudataFerramentas2a"];n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("disabled",false)}}try{temp=[];switch(i3GEO.Interface.ATUAL){case"openlayers":temp=["omenudataArquivos3","omenudataJanelas1"];break;case"googlemaps":temp=["omenudataArquivos3","omenudataJanelas1","omenudataJanelas3"];break;case"googleearth":temp=["omenudataFerramentas7b","omenudataArquivos3","omenudataJanelas3","omenudataFerramentas2a"];break};n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("disabled",true)}}}catch(e){}temp=objid.style;temp.backgroundPosition="0px -1px";temp.border="0px solid white";if(ms.finaliza&&ms.finaliza!=""){eval(ms.finaliza)}},mostraMenuLista:function(id){var objid,n,i,sub,nomeMenu="",ms=i3GEO.gadgets.PARAMETROS.mostraMenuLista,confm=i3GEO.configura.oMenuData,ins="",subs=i3GEO.configura.oMenuData.submenus;if(arguments.length===0){id=ms.idhtml}else{ms.idhtml=id}objid=$i(id);if(objid){n=confm.menu.length;for(i=0;i<n;i+=1){ins+='<div class="listaMenuTitulo" id=menulista_'+confm.menu[i].id+'>'+confm.menu[i].nome+'</div>'}objid.innerHTML=ins;for(nomeMenu in subs){if($i("menulista_"+nomeMenu)){sub=subs[nomeMenu];n=sub.length;ins="";for(i=0;i<n;i++){ins+="<p class='listaMenuItem' ><a href='"+sub[i].url+"' target='_self'>"+sub[i].text+"</a>"}$i("menulista_"+nomeMenu).innerHTML+=ins}}}}}; | ||
2 | \ No newline at end of file | 1 | \ No newline at end of file |
2 | +if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.gadgets={PARAMETROS:{"mostraInserirKml":{idhtml:"inserirKml"},"mostraEscalaNumerica":{idhtml:"escala"},"mostraEscalaGrafica":{idhtml:"escalaGrafica"},"mostraBuscaRapida":{idhtml:"buscaRapida",servicosexternos:true,temasmapa:false,google:true},"mostraVisual":{idhtml:""},"mostraHistoricoZoom":{idhtml:"historicozoom"},"mostraMenuSuspenso":{permiteLogin:true,marcadores:true,idhtml:"menus",deslocaEsquerda:0,parametrosYUI:{iframe:false,autosubmenudisplay:false,showdelay:200,hidedelay:500,lazyload:false}},"mostraMenuLista":{idhtml:"menuLista"},"mostraVersao":{idhtml:"versaoi3geo"},"mostraEmail":{idhtml:"emailInstituicao"}},mostraEmail:function(id){if(arguments.length===0||id===""){id=i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml}else{i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml=id}i3GEO.util.defineValor(id,"innerHTML",i3GEO.parametros.emailInstituicao)},mostraVersao:function(id){if(arguments.length===0||id===""){id=i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml}else{i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml=id}i3GEO.util.defineValor(id,"innerHTML",i3GEO.parametros.mensageminicia)},mostraInserirKml:function(id){var i,ins,temp;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml}if($i(id)){if(!$i("i3geo_urlkml")){i=$inputText(id,"290","i3geo_urlkml","kml url","35","kml");ins="<table><tr><td>"+i;temp='i3GEO.Interface.adicionaKml();';ins+="</td><td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' class='tic' onclick='"+temp+"' /></td></tr></table>";$i(id).innerHTML=ins}}},mostraEscalaNumerica:function(id){var i,ins,temp,onde;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraEscalaNumerica.idhtml}onde=$i(id);if(onde){if(onde.style.display=="none"){onde.style.display="block"}if(!$i("i3geo_escalanum")){i="<form id='i3GEOescalanumForm' >"+$inputText(id,"100","i3geo_escalanum",$trad("d10"),"10",parseInt(i3GEO.parametros.mapscale,10))+"</form>";ins="<table style='width:120px;'><tr><td>"+i;temp='var nova = document.getElementById("i3geo_escalanum").value;';temp+='i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,nova);';ins+="</td></tr></table>";onde.innerHTML=ins;$i("i3GEOescalanumForm").onsubmit=function(){i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,document.getElementById("i3geo_escalanum").value);return false}}i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"])}},atualizaEscalaNumerica:function(escala){var e=$i("i3geo_escalanum");if(!e){i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"]);return}if(arguments.length===1){e.value=escala}else{if(i3GEO.parametros.mapscale!==""){e.value=parseInt(i3GEO.parametros.mapscale,10)}else{e.value=0}}},mostraEscalaGrafica:function(id){if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraEscalaGrafica.idhtml}var ins;if($i(id)){if(!$i("imagemEscalaGrafica")){ins="<img class='menuarrow' src=\""+i3GEO.configura.locaplic+"/imagens/branco.gif\" title='opções' onclick='i3GEO.mapa.dialogo.opcoesEscala()' style='cursor:pointer'/><img id=imagemEscalaGrafica src='' />";$i(id).innerHTML=ins}i3GEO.gadgets.atualizaEscalaGrafica();i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"])}},atualizaEscalaGrafica:function(){var e=$i("imagemEscalaGrafica");if(!e){i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"]);return}temp=function(retorno){eval(retorno.data);$i("imagemEscalaGrafica").src=scaimagem};i3GEO.php.escalagrafica(temp)},mostraBuscaRapida:function(id){var i,ins,temp,fbusca;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.idhtml}i3GEO.gadgets.mostraBuscaRapida.id=id;if($i(id)){i="<form id=i3GEObotaoFormBuscaRapida"+id+" >"+"<div class='i3geoForm' style='width:160px;'><input class=i3geoFormSemIcone type=text value='' id='valorBuscaRapida"+id+"' /></div>"+"</form>";ins="<table><tr><td><a class=ajuda_usuario target=_blank href='"+i3GEO.configura.locaplic+"/ajuda_usuario.php?idcategoria=8&idajuda=71' ><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif' /></a></td>"+"<td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' title='"+$trad("p13")+"' class='ticPropriedades2' id=i3GEObotaoPropriedadesBuscaRapida"+id+" style='margin-right:5px;margin-left:5px;'/></td>"+"<td>"+i+"</td>"+"<td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' class='ticfind' id=i3GEObotaoBuscaRapida"+id+" style='margin-left:3px;' /></td></tr></table>";temp=$i(id);if(temp){fbusca=function(){if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google===false&&i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos===false&&i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa===false){i3GEO.janela.tempoMsg($trad("x35"));return}if($i("valorBuscaRapida"+id).value===""){i3GEO.janela.tempoMsg($trad("x36"));return}i3GEO.janela.cria("300px","280px",i3GEO.configura.locaplic+"/ferramentas/buscarapida/index.htm","","",$trad("o2"));return false};temp.innerHTML=ins;$i("i3GEObotaoBuscaRapida"+id).onclick=fbusca;$i("i3GEObotaoFormBuscaRapida"+id).onsubmit=fbusca;$i("i3GEObotaoPropriedadesBuscaRapida"+id).onclick=function(){var ins,interno="",externo="",google="";i3GEO.janela.cria("300px","150px","","","",$trad("s5"),"i3GEOpropriedadesBuscaRapida"+id);if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos){externo="checked"}if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa){interno="checked"}ins="<p class=paragrafo >"+$trad("x37")+":</p>"+"<table class=lista3 >"+"<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos = this.checked' type=checkbox "+externo+" ></td><td> "+$trad("x38")+"</td></tr>"+"<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa = this.checked' type=checkbox "+interno+" ></td><td>"+$trad("x39")+"</td></tr>";if(i3GEO.Interface.ATUAL==="googlemaps"){if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google){google="checked"}ins+="<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google = this.checked' type=checkbox "+google+" ></td><td>Google</td></tr>"}else{i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google=false}ins+="</table><br>"+"<p class=paragrafo >"+$trad("x40")+"</p>";$i("i3GEOpropriedadesBuscaRapida"+id+"_corpo").innerHTML=ins}}}},mostraHistoricoZoom:function(id){if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraHistoricoZoom.idhtml}if($i(id)){marcadorZoom="";var ins="<table style='text-align:center;position:relative;left:";if(navm){ins+="0px;'>"}else{ins+="6px;'>"}ins+="<tr><td><img id='i3geo_zoomanterior' class='zoomAnterior' title='anterior' src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' /></td>";ins+="<td> </td>";ins+="<td><img id='i3geo_zoomproximo' class='zoomProximo' title='proximo' src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' /></td>";ins+="</tr></table>";$i(id).innerHTML=ins}},visual:{inicia:function(id){alert("A i3GEO.gadgets.visual foi depreciado")},troca:function(visual){alert("A i3GEO.gadgets.visual foi depreciado")}},mostraMenuSuspenso:function(id){var objid,n,i,estilo,t,onMenuBarBeforeRender,temp,i3GEOoMenuBarLocal,ms=i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso,confm=i3GEO.configura.oMenuData,ins="",alinhamento="";if(arguments.length===0){id=ms.idhtml}else{ms.idhtml=id}objid=$i(id);if(!objid){return}if(i3GEO.util.trim(objid.innerHTML)===""){try{if(ms.marcadores===true){i3GEO.configura.oMenuData=i3GEO.marcador.adicionaMenuSuspenso(i3GEO.configura.oMenuData)}}catch(e){}try{if(ms.permiteLogin===true||(ms.permiteLogin!=false&&i3GEO.parametros.editor==="sim")){i3GEO.configura.oMenuData=i3GEO.login.adicionaMenuSuspenso(i3GEO.configura.oMenuData)}}catch(e){}i3GEOoMenuBar=YAHOO.widget.MenuManager;if(objid){objid.className="yuimenubar";temp=$i("contemMenu");if(temp){temp.className="yui-navset"}if(ms.deslocaEsquerda){alinhamento="left:"+ms.deslocaEsquerda*-1+"px;"}if(temp&&(!temp.style.height||parseInt(temp.style.height)===0)){temp.style.height="30px"}if(objid.style.height&&parseInt(objid.style.height,10)===0){objid.style.height="0px"}ins+='<div class="bd" style="top:0px;'+alinhamento+'display:block;align:right;border: 0px solid white;z-index:3;line-height:1.4" >'+'<ul class="first-of-type" style="display:block;border:0px solid white;top:10px;">';n=confm.menu.length;estilo="padding-bottom:3px;top:0px;border: 0px solid white;";for(i=0;i<n;i+=1){t="";if(confm.menu[i].target){t="target="+confm.menu[i].target}if(confm.submenus[confm.menu[i].id].length>0){ins+='<li class="yuimenubaritem" style="padding-top:2px;"><a style="'+estilo+'" href="#" class="yuimenubaritemlabel" '+t+'id="menu'+confm.menu[i].id+'" > '+confm.menu[i].nome+'</a></li>'}}ins+='</ul>';ins+='</div>';objid.innerHTML=ins;if(i3GEO.Interface.ATUAL==="googleearth"){i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI.iframe=true}i3GEOoMenuBarLocal=new YAHOO.widget.MenuBar(id,i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI);onMenuBarBeforeRender=function(p_sType,p_sArgs){var nomeMenu="",nomeSub,subs=i3GEO.configura.oMenuData.submenus,conta=0;for(nomeMenu in subs){if($i("menu"+nomeMenu)){nomeSub=subs[nomeMenu];if(nomeSub!==""){i3GEOoMenuBarLocal.getItem(conta).cfg.setProperty('submenu',{id:nomeMenu,itemdata:nomeSub})}conta+=1}}};temp=$i("contemMenu");if(temp){i3GEOoMenuBarLocal.subscribe("beforeShow",function(){$i("contemMenu").style.zIndex=5000;return},i3GEO.configura.oMenuData.submenus);i3GEOoMenuBarLocal.subscribe("beforeHide",function(){$i("contemMenu").style.zIndex=1;return},i3GEO.configura.oMenuData.submenus)}i3GEOoMenuBar.addMenu(i3GEOoMenuBarLocal);i3GEOoMenuBarLocal.beforeRenderEvent.subscribe(onMenuBarBeforeRender);i3GEOoMenuBarLocal.render()}}temp=["omenudataInterface1","omenudataInterface2","omenudataInterface3","omenudataInterface4","omenudataInterface5"];n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("checked",false)}}try{temp="";switch(i3GEO.Interface.ATUAL){case"openlayers":temp="omenudataInterface2";break;case"googlemaps":temp="omenudataInterface4";break;case"googleearth":temp="omenudataInterface5";break}if(temp!=""&&$i(temp)){i3GEOoMenuBar.getMenuItem(temp).cfg.setProperty("checked",true)}}catch(e){}temp=["omenudataFerramentas7b","omenudataArquivos3","omenudataJanelas1","omenudataJanelas3","omenudataFerramentas2a"];n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("disabled",false)}}try{temp=[];switch(i3GEO.Interface.ATUAL){case"openlayers":temp=["omenudataArquivos3","omenudataJanelas1"];break;case"googlemaps":temp=["omenudataArquivos3","omenudataJanelas1","omenudataJanelas3"];break;case"googleearth":temp=["omenudataFerramentas7b","omenudataArquivos3","omenudataJanelas3","omenudataFerramentas2a"];break};n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("disabled",true)}}}catch(e){}temp=objid.style;temp.backgroundPosition="0px -1px";temp.border="0px solid white";if(ms.finaliza&&ms.finaliza!=""){eval(ms.finaliza)}},mostraMenuLista:function(id){var objid,n,i,sub,nomeMenu="",ms=i3GEO.gadgets.PARAMETROS.mostraMenuLista,confm=i3GEO.configura.oMenuData,ins="",subs=i3GEO.configura.oMenuData.submenus;if(arguments.length===0){id=ms.idhtml}else{ms.idhtml=id}objid=$i(id);if(objid){n=confm.menu.length;for(i=0;i<n;i+=1){ins+='<div class="listaMenuTitulo" id=menulista_'+confm.menu[i].id+'>'+confm.menu[i].nome+'</div>'}objid.innerHTML=ins;for(nomeMenu in subs){if($i("menulista_"+nomeMenu)){sub=subs[nomeMenu];n=sub.length;ins="";for(i=0;i<n;i++){ins+="<p class='listaMenuItem' ><a href='"+sub[i].url+"' target='_self'>"+sub[i].text+"</a>"}$i("menulista_"+nomeMenu).innerHTML+=ins}}}}}; | ||
3 | \ No newline at end of file | 3 | \ No newline at end of file |
classesjs/i3geo_tudo_compacto6.js
@@ -273,7 +273,7 @@ if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.barraDeBotoes={BARRAS:[],BOTA | @@ -273,7 +273,7 @@ if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.barraDeBotoes={BARRAS:[],BOTA | ||
273 | if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.coordenadas={formato:"bloco",padrao:"geoProj",defOrigem:"+proj=longlat +ellps=GRS67 +no_defs",config:{"geoProj":{idhtml:"localizarxy",tipo:"geo",titulo:"Geo",ativo:true,defepsg:""},"dd":{idhtml:"localizarxy",tipo:"metrica",titulo:"Déc. de grau",ativo:true,defepsg:""},"geohash":{idhtml:"localizarxy",tipo:"codigo",tipoCodigo:"geohash",titulo:"GeoHash",ativo:true},"policonicaSad69":{idhtml:"localizarxy",tipo:"metrica",titulo:"Polic SAD-69",ativo:true,defepsg:"+proj=poly +lat_0=0 +lon_0=-54 +x_0=5000000 +y_0=10000000 +ellps=aust_SA +units=m +no_defs"},"utmSad69Proj":{idhtml:"localizarxy",tipo:"utm",titulo:"UTM Sad-69",ativo:true,defepsg:"",zona:{"19N":"+proj=utm +zone=19 +ellps=aust_SA +units=m +no_defs","20N":"+proj=utm +zone=20 +ellps=aust_SA +units=m +no_defs","21N":"+proj=utm +zone=21 +ellps=aust_SA +units=m +no_defs","22N":"+proj=utm +zone=22 +ellps=aust_SA +units=m +no_defs","17S":"+proj=utm +zone=17 +south +ellps=aust_SA +units=m +no_defs","18S":"+proj=utm +zone=18 +south +ellps=aust_SA +units=m +no_defs","19S":"+proj=utm +zone=19 +south +ellps=aust_SA +units=m +no_defs","20S":"+proj=utm +zone=20 +south +ellps=aust_SA +units=m +no_defs","21S":"+proj=utm +zone=21 +south +ellps=aust_SA +units=m +no_defs","22S":"+proj=utm +zone=22 +south +ellps=aust_SA +units=m +no_defs","23S":"+proj=utm +zone=23 +south +ellps=aust_SA +units=m +no_defs","24S":"+proj=utm +zone=24 +south +ellps=aust_SA +units=m +no_defs","25S":"+proj=utm +zone=25 +south +ellps=aust_SA +units=m +no_defs"}},"utmSirgas2000Proj":{idhtml:"localizarxy",tipo:"utm",titulo:"UTM Sirgas",ativo:true,defepsg:"",zona:{"11N":"+proj=utm +zone=11 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","12N":"+proj=utm +zone=12 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","13N":"+proj=utm +zone=13 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","14N":"+proj=utm +zone=14 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","15N":"+proj=utm +zone=15 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","16N":"+proj=utm +zone=16 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","17N":"+proj=utm +zone=17 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","18N":"+proj=utm +zone=18 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","19N":"+proj=utm +zone=19 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","20N":"+proj=utm +zone=20 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","21N":"+proj=utm +zone=21 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","22N":"+proj=utm +zone=22 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","17S":"+proj=utm +zone=17 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","18S":"+proj=utm +zone=18 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","19S":"+proj=utm +zone=19 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","20S":"+proj=utm +zone=20 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","21S":"+proj=utm +zone=21 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","22S":"+proj=utm +zone=22 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","23S":"+proj=utm +zone=23 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","24S":"+proj=utm +zone=24 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","25S":"+proj=utm +zone=25 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs"}}},PARAMETROS:{"mostraCoordenadasUTM":{idhtml:"localizarxy"},"mostraCoordenadasGEO":{idhtml:"localizarxy"},"mostraCoordenadasGeohash":{idhtml:"localizarxy"}},MODOTEXTO:"",mostraCoordenadasGEO:function(id){try{if(arguments.length===0||id===""||typeof(id)==='undefined'){id=this.PARAMETROS.mostraCoordenadasGEO.idhtml}else{this.PARAMETROS.mostraCoordenadasGEO.idhtml=id}if($i(id)){if(!$i("coordgeotabela")){$i(id).innerHTML=i3GEO.coordenadas.criaMascaraDMS("coordgeotabela");if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",["i3GEO.coordenadas.atualizaLocalizarGeo()"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",["i3GEO.coordenadas.atualizaLocalizarGeo()"])}}}}catch(e){i3GEO.janela.tempoMsg("mostraCoordenadasGeo: "+e.description)}},atualizaLocalizarGeo:function(id,x,y){if(!id){id="coordgeotabela"}if(typeof(x)==='undefined'){x=objposicaocursor.dmsx}if(typeof(y)==='undefined'){y=objposicaocursor.dmsy}var temp=$i(id);if(temp&&temp.style.display==="block"){i3GEO.coordenadas.atualizaGeo(x,y,id)}},geo2zonaUtm:function(l){l=(l*1)+180;l=l/6;return parseInt(l,10)+1},criaMascaraDMS:function(prefixo,titulo,caixa){var ins='<table class="i3GeoMascaraCoord" id='+prefixo+' ><tr>'+"<td>"+caixa+" </td>"+'<td style=width:10px;text-align:right > X: </td>'+'<td>'+$inputText('','',prefixo+'xg','grau','3','-00')+'</td>'+'<td>'+$inputText('','',prefixo+'xm','minuto','2','00')+'</td>'+'<td>'+$inputText('','',prefixo+'xs','segundo','5','00.00')+'</td>'+'<td> Y: '+$inputText('','',prefixo+'yg','grau','3','-00')+'</td>'+'<td>'+$inputText('','',prefixo+'ym','minuto','2','00')+'</td>'+'<td>'+$inputText('','',prefixo+'ys','segundo','5','00.00')+'</td>',temp='var '+prefixo+'xxx = i3GEO.calculo.dms2dd($i(\''+prefixo+'xg\').value,$i(\''+prefixo+'xm\').value,$i(\''+prefixo+'xs\').value);'+'var '+prefixo+'yyy = i3GEO.calculo.dms2dd($i(\''+prefixo+'yg\').value,$i(\''+prefixo+'ym\').value,$i(\''+prefixo+'ys\').value);'+'i3GEO.navega.zoomponto(i3GEO.configura.locaplic,i3GEO.configura.sid,'+prefixo+'xxx,'+prefixo+'yyy);';ins+='<td><img class=ticfind style="margin-left:8px;" title=zoom onclick="'+temp+'" src="'+i3GEO.configura.locaplic+"/imagens/branco.gif"+'" /></td>'+"</tr></table>";return ins},atualizaGeo:function(dmsx,dmsy,prefixo){var x=dmsx.split(" "),y=dmsy.split(" ");if($i(prefixo+"xg")){$i(prefixo+"xg").value=x[0];$i(prefixo+"xm").value=x[1];$i(prefixo+"xs").value=x[2];$i(prefixo+"yg").value=y[0];$i(prefixo+"ym").value=y[1];$i(prefixo+"ys").value=y[2]}i3GEO.coordenadas.MODOTEXTO+="DMS - Latitude: "+y[0]+" "+y[1]+" "+y[2]+" Longitude: "+x[0]+" "+x[1]+" "+x[2]+"<br><br>"},criaMascaraMetrica:function(prefixo,titulo,caixa){var ins="<table id="+prefixo+" class='i3GeoMascaraCoord' ><tr>"+"<td>"+caixa+" <td>"+"<td style=width:100px;text-align:right >"+titulo+" X: </td>"+"<td>"+$inputText("","",prefixo+"X","X","12","00")+" </td>"+"<td>Y:"+$inputText("","",prefixo+"Y","Y","12","00")+" </td>"+"<td>Zn:"+$inputText("","",prefixo+"ZN","Zona","2","--")+" </td>"+"</tr></table>";return ins},criaMascaraCodigo:function(prefixo,titulo,caixa,tipoCodigo){var funcao="",ins="";if(tipoCodigo==="geohash"){funcao="i3GEO.coordenadas.geohash.zoomCodigo(\'"+prefixo+"Codigo\')"}ins="<table id="+prefixo+" class='i3GeoMascaraCoord' ><tr>"+"<td>"+caixa+" <td>"+"<td style=width:100px;text-align:right >"+titulo+" : </td>"+"<td>"+$inputText("","",prefixo+"Codigo","Cod","12","00")+" </td>"+'<td><img class=tic title=zoom onclick="'+funcao+'" src="'+i3GEO.configura.locaplic+"/imagens/branco.gif"+'" /></td>'+"</tr></table>";return ins},atualizaCodigo:function(onde,configProj,x,y){var ondeValor=$i(onde+configProj+"Codigo");onde=$i(onde),temp=i3GEO.coordenadas.config[configProj],codigo="";if(onde&&onde.style.display==="none"){return}if(typeof(x)==='undefined'){x=objposicaocursor.ddx}if(typeof(y)==='undefined'){y=objposicaocursor.ddy}if(temp.tipoCodigo==="geohash"){codigo=i3GEO.coordenadas.geohash.encodeGeoHash(y,x)}i3GEO.coordenadas.MODOTEXTO+=temp.titulo+" : "+codigo+"<br><br>";if(ondeValor){ondeValor.value=codigo}},atualizaProj4:function(onde,configProj,x,y){var zona,temp,p,destino="",iu=i3GEO.util;try{if(!$i(onde+configProj+"ZN")){return}}catch(e){return}temp=i3GEO.coordenadas.config[configProj];try{if($i(onde+configProj).style.display==="none"){return}}catch(men){}if(temp.tipo==="metrica"){destino=temp.defepsg}if(typeof(x)==='undefined'){x=objposicaocursor.ddx}if(typeof(y)==='undefined'){y=objposicaocursor.ddy}if(temp.tipo==="utm"){zona=i3GEO.coordenadas.geo2zonaUtm(x);$i(onde+configProj+"ZN").value=zona;if(objposicaocursor.ddy*1>0){destino=temp.zona[zona+"N"]}else{destino=temp.zona[zona+"S"]}if(typeof(destino)==='undefined'){iu.defineValor(onde+configProj+"X","value","?");iu.defineValor(onde+configProj+"Y","value","?");return}}if(temp.defepsg===""&&temp.tipo==="metrica"){p={x:x,y:y}}else{p=i3GEO.coordenadas.calculaProj4(i3GEO.coordenadas.defOrigem,destino,x,y)}iu.defineValor(onde+configProj+"X","value",p.x);iu.defineValor(onde+configProj+"Y","value",p.y);i3GEO.coordenadas.MODOTEXTO+=temp.titulo+" - X: "+p.x+" Y: "+p.y+"<br><br>"},calculaProj4:function(origem,destino,x,y){Proj4js.defs={'ORIGEM':origem,'DESTINO':destino};Proj4js.getScriptLocation=function(){return i3GEO.configura.locaplic+"/pacotes/proj4js/lib/"};var source=new Proj4js.Proj("ORIGEM"),dest=new Proj4js.Proj("DESTINO"),p=new Proj4js.Point(x,y);Proj4js.transform(source,dest,p);return p},ativaBloco:function(prefixo){var tipos=i3GEO.util.listaChaves(i3GEO.coordenadas.config),n=tipos.length,temp,i=0;for(i=0;i<n;i++){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){if(tipos[i]===this.padrao){$i(prefixo+tipos[i]).style.display="block"}else{$i(prefixo+tipos[i]).style.display="none"}}}},mudaTipo:function(obj,onde){if(obj.value==="janela"){this.formato="janela";this.mostraCoordenadas();return}this.padrao=obj.value;obj.selectedIndex=0;i3GEO.coordenadas.ativaBloco(onde)},mostraCoordenadas:function(ativaMovimento,onde,x,y){try{var tipos=i3GEO.util.listaChaves(i3GEO.coordenadas.config),n=tipos.length,temp,ins="",i=0,caixa,janela,nomeFunc;i3GEO.coordenadas.MODOTEXTO="";if(arguments.length===0){ativaMovimento=true;onde=""}if(onde===""){onde=i3GEO.coordenadas.config[tipos[0]].idhtml}caixa="<select onchange='javascript:i3GEO.coordenadas.mudaTipo(this,\""+onde+"\");' class='i3geoCoordenadasComboTipo' ><option>---</option><option value='janela' >janela</option>";for(i=0;i<n;i+=1){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){caixa+="<option value='"+tipos[i]+"'>"+temp.titulo+"</option>"}}caixa+="</select>";if(i3GEO.coordenadas.formato!=="bloco"){caixa=""}for(i=0;i<n;i+=1){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){if(temp.tipo==="geo"){ins+=i3GEO.coordenadas.criaMascaraDMS(onde+tipos[i],temp.titulo,caixa);if(i3GEO.coordenadas.formato==="separado"){try{$i(temp.idhtml).innerHTML=ins}catch(e){}ins=""}}else{if(temp.tipo==="codigo"){ins+=i3GEO.coordenadas.criaMascaraCodigo(onde+tipos[i],temp.titulo,caixa,temp.tipoCodigo)}else{ins+=i3GEO.coordenadas.criaMascaraMetrica(onde+tipos[i],temp.titulo,caixa)}}}}if(this.formato==="janela"){janela=i3GEO.janela.cria("450px","120px","","","",$trad("x49"),"i3GEOJanelaCoordenadas",false,"hd","","");YAHOO.util.Event.addListener(janela[0].close,"click",function(){i3GEO.coordenadas.formato="bloco",i3GEO.coordenadas.mostraCoordenadas()});temp=$i("i3GEOJanelaCoordenadas_corpo");temp.style.backgroundColor="white";temp.style.textAlign="left";temp=$i("i3GEOJanelaCoordenadas");temp.onmouseover="";temp.onmouseout="";if($i(onde)){$i(onde).innerHTML=""}onde="i3GEOJanelaCoordenadas_corpo";ins+="<br><a href='#' style='cursor:pointer;color:blue' onclick='new YAHOO.util.KeyListener(document.body,{alt:true,keys:67},{fn: function(type, args, obj){i3GEO.janela.tempoMsg(i3GEO.coordenadas.MODOTEXTO);}}).enable();' >"+"Clique aqui para ativar Alt+C para poder capturar as coordenadas</a>"}if(onde!==""&&$i(onde)){$i(onde).innerHTML=ins}for(i=0;i<n;i+=1){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){if(temp.tipo==="geo"){if(ativaMovimento===true){if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",["i3GEO.coordenadas.atualizaLocalizarGeo('"+onde+tipos[i]+"')"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",["i3GEO.coordenadas.atualizaLocalizarGeo('"+onde+tipos[i]+"')"])}}if(typeof(x)!=='undefined'){i3GEO.coordenadas.atualizaLocalizarGeo(onde+tipos[i],i3GEO.calculo.dd2dms(x)[0],i3GEO.calculo.dd2dms(y)[0])}}else{nomeFunc="i3GEO.coordenadas.atualizaProj4";if(temp.tipo==="codigo"){nomeFunc="i3GEO.coordenadas.atualizaCodigo"}if(ativaMovimento===true){if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",[nomeFunc+"('"+onde+"','"+tipos[i]+"')"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",[nomeFunc+"('"+onde+"','"+tipos[i]+"')"])}}if(typeof(x)!=='undefined'){eval(nomeFunc+"(onde,tipos[i],x,y);")}}}}if(ativaMovimento===true){if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",["i3GEO.coordenadas.limpaModoTexto()"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",["i3GEO.coordenadas.limpaModoTexto()"])}}if(i3GEO.coordenadas.formato==="bloco"){i3GEO.coordenadas.ativaBloco(onde)}}catch(men){}},limpaModoTexto:function(){i3GEO.coordenadas.MODOTEXTO=""},geohash:{BITS:[16,8,4,2,1],BASE32:"0123456789bcdefghjkmnpqrstuvwxyz",refine_interval:function(interval,cd,mask){if(cd&mask)interval[0]=(interval[0]+interval[1])/2;else interval[1]=(interval[0]+interval[1])/2},decodeGeoHash:function(geohash){var is_even=1,lat=[],lon=[],i,j,x,y;lat[0]=-90.0;lat[1]=90.0;lon[0]=-180.0;lon[1]=180.0;lat_err=90.0;lon_err=180.0;for(i=0;i<geohash.length;i++){c=geohash[i];cd=i3GEO.coordenadas.geohash.BASE32.indexOf(c);for(j=0;j<5;j++){mask=i3GEO.coordenadas.geohash.BITS[j];if(is_even){lon_err/=2;i3GEO.coordenadas.geohash.refine_interval(lon,cd,mask)}else{lat_err/=2;i3GEO.coordenadas.geohash.refine_interval(lat,cd,mask)}is_even=!is_even}}lat[2]=(lat[0]+lat[1])/2;lon[2]=(lon[0]+lon[1])/2;y=(lat[0]+lat[1])/2;x=(lon[0]+lon[1])/2;return{latitude:y,longitude:x}},encodeGeoHash:function(latitude,longitude){var is_even=1,lat=[],lon=[],bit=0,ch=0,precision=12,geohash="";lat[0]=-90.0;lat[1]=90.0;lon[0]=-180.0;lon[1]=180.0;while(geohash.length<precision){if(is_even){mid=(lon[0]+lon[1])/2;if(longitude>mid){ch|=i3GEO.coordenadas.geohash.BITS[bit];lon[0]=mid}else lon[1]=mid}else{mid=(lat[0]+lat[1])/2;if(latitude>mid){ch|=i3GEO.coordenadas.geohash.BITS[bit];lat[0]=mid}else lat[1]=mid}is_even=!is_even;if(bit<4)bit++;else{geohash+=i3GEO.coordenadas.geohash.BASE32[ch];bit=0;ch=0}}return geohash},zoomCodigo:function(idobj){var codigo;if($i(idobj)){codigo=$i(idobj).value}else{codigo=idobj}codigo=i3GEO.coordenadas.geohash.decodeGeoHash(codigo);i3GEO.navega.zoomponto(i3GEO.configura.locaplic,i3GEO.configura.sid,codigo.longitude,codigo.latitude)}}}; | 273 | if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.coordenadas={formato:"bloco",padrao:"geoProj",defOrigem:"+proj=longlat +ellps=GRS67 +no_defs",config:{"geoProj":{idhtml:"localizarxy",tipo:"geo",titulo:"Geo",ativo:true,defepsg:""},"dd":{idhtml:"localizarxy",tipo:"metrica",titulo:"Déc. de grau",ativo:true,defepsg:""},"geohash":{idhtml:"localizarxy",tipo:"codigo",tipoCodigo:"geohash",titulo:"GeoHash",ativo:true},"policonicaSad69":{idhtml:"localizarxy",tipo:"metrica",titulo:"Polic SAD-69",ativo:true,defepsg:"+proj=poly +lat_0=0 +lon_0=-54 +x_0=5000000 +y_0=10000000 +ellps=aust_SA +units=m +no_defs"},"utmSad69Proj":{idhtml:"localizarxy",tipo:"utm",titulo:"UTM Sad-69",ativo:true,defepsg:"",zona:{"19N":"+proj=utm +zone=19 +ellps=aust_SA +units=m +no_defs","20N":"+proj=utm +zone=20 +ellps=aust_SA +units=m +no_defs","21N":"+proj=utm +zone=21 +ellps=aust_SA +units=m +no_defs","22N":"+proj=utm +zone=22 +ellps=aust_SA +units=m +no_defs","17S":"+proj=utm +zone=17 +south +ellps=aust_SA +units=m +no_defs","18S":"+proj=utm +zone=18 +south +ellps=aust_SA +units=m +no_defs","19S":"+proj=utm +zone=19 +south +ellps=aust_SA +units=m +no_defs","20S":"+proj=utm +zone=20 +south +ellps=aust_SA +units=m +no_defs","21S":"+proj=utm +zone=21 +south +ellps=aust_SA +units=m +no_defs","22S":"+proj=utm +zone=22 +south +ellps=aust_SA +units=m +no_defs","23S":"+proj=utm +zone=23 +south +ellps=aust_SA +units=m +no_defs","24S":"+proj=utm +zone=24 +south +ellps=aust_SA +units=m +no_defs","25S":"+proj=utm +zone=25 +south +ellps=aust_SA +units=m +no_defs"}},"utmSirgas2000Proj":{idhtml:"localizarxy",tipo:"utm",titulo:"UTM Sirgas",ativo:true,defepsg:"",zona:{"11N":"+proj=utm +zone=11 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","12N":"+proj=utm +zone=12 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","13N":"+proj=utm +zone=13 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","14N":"+proj=utm +zone=14 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","15N":"+proj=utm +zone=15 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","16N":"+proj=utm +zone=16 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","17N":"+proj=utm +zone=17 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","18N":"+proj=utm +zone=18 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","19N":"+proj=utm +zone=19 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","20N":"+proj=utm +zone=20 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","21N":"+proj=utm +zone=21 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","22N":"+proj=utm +zone=22 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","17S":"+proj=utm +zone=17 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","18S":"+proj=utm +zone=18 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","19S":"+proj=utm +zone=19 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","20S":"+proj=utm +zone=20 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","21S":"+proj=utm +zone=21 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","22S":"+proj=utm +zone=22 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","23S":"+proj=utm +zone=23 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","24S":"+proj=utm +zone=24 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","25S":"+proj=utm +zone=25 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs"}}},PARAMETROS:{"mostraCoordenadasUTM":{idhtml:"localizarxy"},"mostraCoordenadasGEO":{idhtml:"localizarxy"},"mostraCoordenadasGeohash":{idhtml:"localizarxy"}},MODOTEXTO:"",mostraCoordenadasGEO:function(id){try{if(arguments.length===0||id===""||typeof(id)==='undefined'){id=this.PARAMETROS.mostraCoordenadasGEO.idhtml}else{this.PARAMETROS.mostraCoordenadasGEO.idhtml=id}if($i(id)){if(!$i("coordgeotabela")){$i(id).innerHTML=i3GEO.coordenadas.criaMascaraDMS("coordgeotabela");if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",["i3GEO.coordenadas.atualizaLocalizarGeo()"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",["i3GEO.coordenadas.atualizaLocalizarGeo()"])}}}}catch(e){i3GEO.janela.tempoMsg("mostraCoordenadasGeo: "+e.description)}},atualizaLocalizarGeo:function(id,x,y){if(!id){id="coordgeotabela"}if(typeof(x)==='undefined'){x=objposicaocursor.dmsx}if(typeof(y)==='undefined'){y=objposicaocursor.dmsy}var temp=$i(id);if(temp&&temp.style.display==="block"){i3GEO.coordenadas.atualizaGeo(x,y,id)}},geo2zonaUtm:function(l){l=(l*1)+180;l=l/6;return parseInt(l,10)+1},criaMascaraDMS:function(prefixo,titulo,caixa){var ins='<table class="i3GeoMascaraCoord" id='+prefixo+' ><tr>'+"<td>"+caixa+" </td>"+'<td style=width:10px;text-align:right > X: </td>'+'<td>'+$inputText('','',prefixo+'xg','grau','3','-00')+'</td>'+'<td>'+$inputText('','',prefixo+'xm','minuto','2','00')+'</td>'+'<td>'+$inputText('','',prefixo+'xs','segundo','5','00.00')+'</td>'+'<td> Y: '+$inputText('','',prefixo+'yg','grau','3','-00')+'</td>'+'<td>'+$inputText('','',prefixo+'ym','minuto','2','00')+'</td>'+'<td>'+$inputText('','',prefixo+'ys','segundo','5','00.00')+'</td>',temp='var '+prefixo+'xxx = i3GEO.calculo.dms2dd($i(\''+prefixo+'xg\').value,$i(\''+prefixo+'xm\').value,$i(\''+prefixo+'xs\').value);'+'var '+prefixo+'yyy = i3GEO.calculo.dms2dd($i(\''+prefixo+'yg\').value,$i(\''+prefixo+'ym\').value,$i(\''+prefixo+'ys\').value);'+'i3GEO.navega.zoomponto(i3GEO.configura.locaplic,i3GEO.configura.sid,'+prefixo+'xxx,'+prefixo+'yyy);';ins+='<td><img class=ticfind style="margin-left:8px;" title=zoom onclick="'+temp+'" src="'+i3GEO.configura.locaplic+"/imagens/branco.gif"+'" /></td>'+"</tr></table>";return ins},atualizaGeo:function(dmsx,dmsy,prefixo){var x=dmsx.split(" "),y=dmsy.split(" ");if($i(prefixo+"xg")){$i(prefixo+"xg").value=x[0];$i(prefixo+"xm").value=x[1];$i(prefixo+"xs").value=x[2];$i(prefixo+"yg").value=y[0];$i(prefixo+"ym").value=y[1];$i(prefixo+"ys").value=y[2]}i3GEO.coordenadas.MODOTEXTO+="DMS - Latitude: "+y[0]+" "+y[1]+" "+y[2]+" Longitude: "+x[0]+" "+x[1]+" "+x[2]+"<br><br>"},criaMascaraMetrica:function(prefixo,titulo,caixa){var ins="<table id="+prefixo+" class='i3GeoMascaraCoord' ><tr>"+"<td>"+caixa+" <td>"+"<td style=width:100px;text-align:right >"+titulo+" X: </td>"+"<td>"+$inputText("","",prefixo+"X","X","12","00")+" </td>"+"<td>Y:"+$inputText("","",prefixo+"Y","Y","12","00")+" </td>"+"<td>Zn:"+$inputText("","",prefixo+"ZN","Zona","2","--")+" </td>"+"</tr></table>";return ins},criaMascaraCodigo:function(prefixo,titulo,caixa,tipoCodigo){var funcao="",ins="";if(tipoCodigo==="geohash"){funcao="i3GEO.coordenadas.geohash.zoomCodigo(\'"+prefixo+"Codigo\')"}ins="<table id="+prefixo+" class='i3GeoMascaraCoord' ><tr>"+"<td>"+caixa+" <td>"+"<td style=width:100px;text-align:right >"+titulo+" : </td>"+"<td>"+$inputText("","",prefixo+"Codigo","Cod","12","00")+" </td>"+'<td><img class=tic title=zoom onclick="'+funcao+'" src="'+i3GEO.configura.locaplic+"/imagens/branco.gif"+'" /></td>'+"</tr></table>";return ins},atualizaCodigo:function(onde,configProj,x,y){var ondeValor=$i(onde+configProj+"Codigo");onde=$i(onde),temp=i3GEO.coordenadas.config[configProj],codigo="";if(onde&&onde.style.display==="none"){return}if(typeof(x)==='undefined'){x=objposicaocursor.ddx}if(typeof(y)==='undefined'){y=objposicaocursor.ddy}if(temp.tipoCodigo==="geohash"){codigo=i3GEO.coordenadas.geohash.encodeGeoHash(y,x)}i3GEO.coordenadas.MODOTEXTO+=temp.titulo+" : "+codigo+"<br><br>";if(ondeValor){ondeValor.value=codigo}},atualizaProj4:function(onde,configProj,x,y){var zona,temp,p,destino="",iu=i3GEO.util;try{if(!$i(onde+configProj+"ZN")){return}}catch(e){return}temp=i3GEO.coordenadas.config[configProj];try{if($i(onde+configProj).style.display==="none"){return}}catch(men){}if(temp.tipo==="metrica"){destino=temp.defepsg}if(typeof(x)==='undefined'){x=objposicaocursor.ddx}if(typeof(y)==='undefined'){y=objposicaocursor.ddy}if(temp.tipo==="utm"){zona=i3GEO.coordenadas.geo2zonaUtm(x);$i(onde+configProj+"ZN").value=zona;if(objposicaocursor.ddy*1>0){destino=temp.zona[zona+"N"]}else{destino=temp.zona[zona+"S"]}if(typeof(destino)==='undefined'){iu.defineValor(onde+configProj+"X","value","?");iu.defineValor(onde+configProj+"Y","value","?");return}}if(temp.defepsg===""&&temp.tipo==="metrica"){p={x:x,y:y}}else{p=i3GEO.coordenadas.calculaProj4(i3GEO.coordenadas.defOrigem,destino,x,y)}iu.defineValor(onde+configProj+"X","value",p.x);iu.defineValor(onde+configProj+"Y","value",p.y);i3GEO.coordenadas.MODOTEXTO+=temp.titulo+" - X: "+p.x+" Y: "+p.y+"<br><br>"},calculaProj4:function(origem,destino,x,y){Proj4js.defs={'ORIGEM':origem,'DESTINO':destino};Proj4js.getScriptLocation=function(){return i3GEO.configura.locaplic+"/pacotes/proj4js/lib/"};var source=new Proj4js.Proj("ORIGEM"),dest=new Proj4js.Proj("DESTINO"),p=new Proj4js.Point(x,y);Proj4js.transform(source,dest,p);return p},ativaBloco:function(prefixo){var tipos=i3GEO.util.listaChaves(i3GEO.coordenadas.config),n=tipos.length,temp,i=0;for(i=0;i<n;i++){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){if(tipos[i]===this.padrao){$i(prefixo+tipos[i]).style.display="block"}else{$i(prefixo+tipos[i]).style.display="none"}}}},mudaTipo:function(obj,onde){if(obj.value==="janela"){this.formato="janela";this.mostraCoordenadas();return}this.padrao=obj.value;obj.selectedIndex=0;i3GEO.coordenadas.ativaBloco(onde)},mostraCoordenadas:function(ativaMovimento,onde,x,y){try{var tipos=i3GEO.util.listaChaves(i3GEO.coordenadas.config),n=tipos.length,temp,ins="",i=0,caixa,janela,nomeFunc;i3GEO.coordenadas.MODOTEXTO="";if(arguments.length===0){ativaMovimento=true;onde=""}if(onde===""){onde=i3GEO.coordenadas.config[tipos[0]].idhtml}caixa="<select onchange='javascript:i3GEO.coordenadas.mudaTipo(this,\""+onde+"\");' class='i3geoCoordenadasComboTipo' ><option>---</option><option value='janela' >janela</option>";for(i=0;i<n;i+=1){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){caixa+="<option value='"+tipos[i]+"'>"+temp.titulo+"</option>"}}caixa+="</select>";if(i3GEO.coordenadas.formato!=="bloco"){caixa=""}for(i=0;i<n;i+=1){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){if(temp.tipo==="geo"){ins+=i3GEO.coordenadas.criaMascaraDMS(onde+tipos[i],temp.titulo,caixa);if(i3GEO.coordenadas.formato==="separado"){try{$i(temp.idhtml).innerHTML=ins}catch(e){}ins=""}}else{if(temp.tipo==="codigo"){ins+=i3GEO.coordenadas.criaMascaraCodigo(onde+tipos[i],temp.titulo,caixa,temp.tipoCodigo)}else{ins+=i3GEO.coordenadas.criaMascaraMetrica(onde+tipos[i],temp.titulo,caixa)}}}}if(this.formato==="janela"){janela=i3GEO.janela.cria("450px","120px","","","",$trad("x49"),"i3GEOJanelaCoordenadas",false,"hd","","");YAHOO.util.Event.addListener(janela[0].close,"click",function(){i3GEO.coordenadas.formato="bloco",i3GEO.coordenadas.mostraCoordenadas()});temp=$i("i3GEOJanelaCoordenadas_corpo");temp.style.backgroundColor="white";temp.style.textAlign="left";temp=$i("i3GEOJanelaCoordenadas");temp.onmouseover="";temp.onmouseout="";if($i(onde)){$i(onde).innerHTML=""}onde="i3GEOJanelaCoordenadas_corpo";ins+="<br><a href='#' style='cursor:pointer;color:blue' onclick='new YAHOO.util.KeyListener(document.body,{alt:true,keys:67},{fn: function(type, args, obj){i3GEO.janela.tempoMsg(i3GEO.coordenadas.MODOTEXTO);}}).enable();' >"+"Clique aqui para ativar Alt+C para poder capturar as coordenadas</a>"}if(onde!==""&&$i(onde)){$i(onde).innerHTML=ins}for(i=0;i<n;i+=1){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){if(temp.tipo==="geo"){if(ativaMovimento===true){if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",["i3GEO.coordenadas.atualizaLocalizarGeo('"+onde+tipos[i]+"')"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",["i3GEO.coordenadas.atualizaLocalizarGeo('"+onde+tipos[i]+"')"])}}if(typeof(x)!=='undefined'){i3GEO.coordenadas.atualizaLocalizarGeo(onde+tipos[i],i3GEO.calculo.dd2dms(x)[0],i3GEO.calculo.dd2dms(y)[0])}}else{nomeFunc="i3GEO.coordenadas.atualizaProj4";if(temp.tipo==="codigo"){nomeFunc="i3GEO.coordenadas.atualizaCodigo"}if(ativaMovimento===true){if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",[nomeFunc+"('"+onde+"','"+tipos[i]+"')"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",[nomeFunc+"('"+onde+"','"+tipos[i]+"')"])}}if(typeof(x)!=='undefined'){eval(nomeFunc+"(onde,tipos[i],x,y);")}}}}if(ativaMovimento===true){if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",["i3GEO.coordenadas.limpaModoTexto()"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",["i3GEO.coordenadas.limpaModoTexto()"])}}if(i3GEO.coordenadas.formato==="bloco"){i3GEO.coordenadas.ativaBloco(onde)}}catch(men){}},limpaModoTexto:function(){i3GEO.coordenadas.MODOTEXTO=""},geohash:{BITS:[16,8,4,2,1],BASE32:"0123456789bcdefghjkmnpqrstuvwxyz",refine_interval:function(interval,cd,mask){if(cd&mask)interval[0]=(interval[0]+interval[1])/2;else interval[1]=(interval[0]+interval[1])/2},decodeGeoHash:function(geohash){var is_even=1,lat=[],lon=[],i,j,x,y;lat[0]=-90.0;lat[1]=90.0;lon[0]=-180.0;lon[1]=180.0;lat_err=90.0;lon_err=180.0;for(i=0;i<geohash.length;i++){c=geohash[i];cd=i3GEO.coordenadas.geohash.BASE32.indexOf(c);for(j=0;j<5;j++){mask=i3GEO.coordenadas.geohash.BITS[j];if(is_even){lon_err/=2;i3GEO.coordenadas.geohash.refine_interval(lon,cd,mask)}else{lat_err/=2;i3GEO.coordenadas.geohash.refine_interval(lat,cd,mask)}is_even=!is_even}}lat[2]=(lat[0]+lat[1])/2;lon[2]=(lon[0]+lon[1])/2;y=(lat[0]+lat[1])/2;x=(lon[0]+lon[1])/2;return{latitude:y,longitude:x}},encodeGeoHash:function(latitude,longitude){var is_even=1,lat=[],lon=[],bit=0,ch=0,precision=12,geohash="";lat[0]=-90.0;lat[1]=90.0;lon[0]=-180.0;lon[1]=180.0;while(geohash.length<precision){if(is_even){mid=(lon[0]+lon[1])/2;if(longitude>mid){ch|=i3GEO.coordenadas.geohash.BITS[bit];lon[0]=mid}else lon[1]=mid}else{mid=(lat[0]+lat[1])/2;if(latitude>mid){ch|=i3GEO.coordenadas.geohash.BITS[bit];lat[0]=mid}else lat[1]=mid}is_even=!is_even;if(bit<4)bit++;else{geohash+=i3GEO.coordenadas.geohash.BASE32[ch];bit=0;ch=0}}return geohash},zoomCodigo:function(idobj){var codigo;if($i(idobj)){codigo=$i(idobj).value}else{codigo=idobj}codigo=i3GEO.coordenadas.geohash.decodeGeoHash(codigo);i3GEO.navega.zoomponto(i3GEO.configura.locaplic,i3GEO.configura.sid,codigo.longitude,codigo.latitude)}}}; |
274 | // | 274 | // |
275 | //compactados/classe_gadgets_compacto.js | 275 | //compactados/classe_gadgets_compacto.js |
276 | -if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.gadgets={PARAMETROS:{"mostraInserirKml":{idhtml:"inserirKml"},"mostraEscalaNumerica":{idhtml:"escala"},"mostraEscalaGrafica":{idhtml:"escalaGrafica"},"mostraBuscaRapida":{idhtml:"buscaRapida",servicosexternos:true,temasmapa:false,google:true},"mostraVisual":{idhtml:""},"mostraHistoricoZoom":{idhtml:"historicozoom"},"mostraMenuSuspenso":{permiteLogin:true,marcadores:true,idhtml:"menus",deslocaEsquerda:0,parametrosYUI:{iframe:false,autosubmenudisplay:false,showdelay:200,hidedelay:500,lazyload:false}},"mostraMenuLista":{idhtml:"menuLista"},"mostraVersao":{idhtml:"versaoi3geo"},"mostraEmail":{idhtml:"emailInstituicao"}},mostraEmail:function(id){if(arguments.length===0||id===""){id=i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml}else{i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml=id}i3GEO.util.defineValor(id,"innerHTML",i3GEO.parametros.emailInstituicao)},mostraVersao:function(id){if(arguments.length===0||id===""){id=i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml}else{i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml=id}i3GEO.util.defineValor(id,"innerHTML",i3GEO.parametros.mensageminicia)},mostraInserirKml:function(id){var i,ins,temp;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml}if($i(id)){if(!$i("i3geo_urlkml")){i=$inputText(id,"290","i3geo_urlkml","kml url","35","kml");ins="<table><tr><td>"+i;temp='i3GEO.Interface.adicionaKml();';ins+="</td><td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' class='tic' onclick='"+temp+"' /></td></tr></table>";$i(id).innerHTML=ins}}},mostraEscalaNumerica:function(id){var i,ins,temp,onde;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraEscalaNumerica.idhtml}onde=$i(id);if(onde){if(onde.style.display=="none"){onde.style.display="block"}if(!$i("i3geo_escalanum")){i="<form id='i3GEOescalanumForm' >"+$inputText(id,"100","i3geo_escalanum",$trad("d10"),"10",parseInt(i3GEO.parametros.mapscale,10))+"</form>";ins="<table style='width:120px;'><tr><td>"+i;temp='var nova = document.getElementById("i3geo_escalanum").value;';temp+='i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,nova);';ins+="</td></tr></table>";onde.innerHTML=ins;$i("i3GEOescalanumForm").onsubmit=function(){i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,document.getElementById("i3geo_escalanum").value);return false}}i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"])}},atualizaEscalaNumerica:function(escala){var e=$i("i3geo_escalanum");if(!e){i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"]);return}if(arguments.length===1){e.value=escala}else{if(i3GEO.parametros.mapscale!==""){e.value=parseInt(i3GEO.parametros.mapscale,10)}else{e.value=0}}},mostraEscalaGrafica:function(id){if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraEscalaGrafica.idhtml}var ins;if($i(id)){if(!$i("imagemEscalaGrafica")){ins="<img class='menuarrow' src=\""+i3GEO.configura.locaplic+"/imagens/branco.gif\" title='opções' onclick='i3GEO.mapa.dialogo.opcoesEscala()' style='cursor:pointer'/><img id=imagemEscalaGrafica src='' />";$i(id).innerHTML=ins}i3GEO.gadgets.atualizaEscalaGrafica();i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"])}},atualizaEscalaGrafica:function(){var e=$i("imagemEscalaGrafica");if(!e){i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"]);return}temp=function(retorno){eval(retorno.data);$i("imagemEscalaGrafica").src=scaimagem};i3GEO.php.escalagrafica(temp)},mostraBuscaRapida:function(id){var i,ins,temp,fbusca;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.idhtml}i3GEO.gadgets.mostraBuscaRapida.id=id;if($i(id)){i="<form id=i3GEObotaoFormBuscaRapida"+id+" >"+"<div class='i3geoForm' style='width:160px;'><input class=i3geoFormSemIcone type=text value='' id='valorBuscaRapida"+id+"' /></div>"+"</form>";ins="<table><tr><td><a class=ajuda_usuario target=_blank href='"+i3GEO.configura.locaplic+"/ajuda_usuario.php?idcategoria=8&idajuda=71' > </a></td><td>"+i+"</td>";ins+="<td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' title='"+$trad("p13")+"' class='ticPropriedades2' id=i3GEObotaoPropriedadesBuscaRapida"+id+" style='margin-right:5px;margin-left:5px;'/></td>";ins+="<td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' class='ticfind' id=i3GEObotaoBuscaRapida"+id+" /></td></tr></table>";temp=$i(id);if(temp){fbusca=function(){if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google===false&&i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos===false&&i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa===false){i3GEO.janela.tempoMsg($trad("x35"));return}if($i("valorBuscaRapida"+id).value===""){i3GEO.janela.tempoMsg($trad("x36"));return}i3GEO.janela.cria("300px","280px",i3GEO.configura.locaplic+"/ferramentas/buscarapida/index.htm","","",$trad("o2"));return false};temp.innerHTML=ins;$i("i3GEObotaoBuscaRapida"+id).onclick=fbusca;$i("i3GEObotaoFormBuscaRapida"+id).onsubmit=fbusca;$i("i3GEObotaoPropriedadesBuscaRapida"+id).onclick=function(){var ins,interno="",externo="",google="";i3GEO.janela.cria("300px","150px","","","",$trad("s5"),"i3GEOpropriedadesBuscaRapida"+id);if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos){externo="checked"}if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa){interno="checked"}ins="<p class=paragrafo >"+$trad("x37")+":</p>"+"<table class=lista3 >"+"<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos = this.checked' type=checkbox "+externo+" ></td><td> "+$trad("x38")+"</td></tr>"+"<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa = this.checked' type=checkbox "+interno+" ></td><td>"+$trad("x39")+"</td></tr>";if(i3GEO.Interface.ATUAL==="googlemaps"){if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google){google="checked"}ins+="<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google = this.checked' type=checkbox "+google+" ></td><td>Google</td></tr>"}else{i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google=false}ins+="</table><br>"+"<p class=paragrafo >"+$trad("x40")+"</p>";$i("i3GEOpropriedadesBuscaRapida"+id+"_corpo").innerHTML=ins}}}},mostraHistoricoZoom:function(id){if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraHistoricoZoom.idhtml}if($i(id)){marcadorZoom="";var ins="<table style='text-align:center;position:relative;left:";if(navm){ins+="0px;'>"}else{ins+="6px;'>"}ins+="<tr><td><img id='i3geo_zoomanterior' class='zoomAnterior' title='anterior' src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' /></td>";ins+="<td> </td>";ins+="<td><img id='i3geo_zoomproximo' class='zoomProximo' title='proximo' src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' /></td>";ins+="</tr></table>";$i(id).innerHTML=ins}},visual:{inicia:function(id){alert("A i3GEO.gadgets.visual foi depreciado")},troca:function(visual){alert("A i3GEO.gadgets.visual foi depreciado")}},mostraMenuSuspenso:function(id){var objid,n,i,estilo,t,onMenuBarBeforeRender,temp,i3GEOoMenuBarLocal,ms=i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso,confm=i3GEO.configura.oMenuData,ins="",alinhamento="";if(arguments.length===0){id=ms.idhtml}else{ms.idhtml=id}objid=$i(id);if(!objid){return}if(i3GEO.util.trim(objid.innerHTML)===""){try{if(ms.marcadores===true){i3GEO.configura.oMenuData=i3GEO.marcador.adicionaMenuSuspenso(i3GEO.configura.oMenuData)}}catch(e){}try{if(ms.permiteLogin===true||(ms.permiteLogin!=false&&i3GEO.parametros.editor==="sim")){i3GEO.configura.oMenuData=i3GEO.login.adicionaMenuSuspenso(i3GEO.configura.oMenuData)}}catch(e){}i3GEOoMenuBar=YAHOO.widget.MenuManager;if(objid){objid.className="yuimenubar";temp=$i("contemMenu");if(temp){temp.className="yui-navset"}if(ms.deslocaEsquerda){alinhamento="left:"+ms.deslocaEsquerda*-1+"px;"}if(temp&&(!temp.style.height||parseInt(temp.style.height)===0)){temp.style.height="30px"}if(objid.style.height&&parseInt(objid.style.height,10)===0){objid.style.height="0px"}ins+='<div class="bd" style="top:0px;'+alinhamento+'display:block;align:right;border: 0px solid white;z-index:3;line-height:1.4" >'+'<ul class="first-of-type" style="display:block;border:0px solid white;top:10px;">';n=confm.menu.length;estilo="padding-bottom:3px;top:0px;border: 0px solid white;";for(i=0;i<n;i+=1){t="";if(confm.menu[i].target){t="target="+confm.menu[i].target}if(confm.submenus[confm.menu[i].id].length>0){ins+='<li class="yuimenubaritem" style="padding-top:2px;"><a style="'+estilo+'" href="#" class="yuimenubaritemlabel" '+t+'id="menu'+confm.menu[i].id+'" > '+confm.menu[i].nome+'</a></li>'}}ins+='</ul>';ins+='</div>';objid.innerHTML=ins;if(i3GEO.Interface.ATUAL==="googleearth"){i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI.iframe=true}i3GEOoMenuBarLocal=new YAHOO.widget.MenuBar(id,i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI);onMenuBarBeforeRender=function(p_sType,p_sArgs){var nomeMenu="",nomeSub,subs=i3GEO.configura.oMenuData.submenus,conta=0;for(nomeMenu in subs){if($i("menu"+nomeMenu)){nomeSub=subs[nomeMenu];if(nomeSub!==""){i3GEOoMenuBarLocal.getItem(conta).cfg.setProperty('submenu',{id:nomeMenu,itemdata:nomeSub})}conta+=1}}};temp=$i("contemMenu");if(temp){i3GEOoMenuBarLocal.subscribe("beforeShow",function(){$i("contemMenu").style.zIndex=5000;return},i3GEO.configura.oMenuData.submenus);i3GEOoMenuBarLocal.subscribe("beforeHide",function(){$i("contemMenu").style.zIndex=1;return},i3GEO.configura.oMenuData.submenus)}i3GEOoMenuBar.addMenu(i3GEOoMenuBarLocal);i3GEOoMenuBarLocal.beforeRenderEvent.subscribe(onMenuBarBeforeRender);i3GEOoMenuBarLocal.render()}}temp=["omenudataInterface1","omenudataInterface2","omenudataInterface3","omenudataInterface4","omenudataInterface5"];n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("checked",false)}}try{temp="";switch(i3GEO.Interface.ATUAL){case"openlayers":temp="omenudataInterface2";break;case"googlemaps":temp="omenudataInterface4";break;case"googleearth":temp="omenudataInterface5";break}if(temp!=""&&$i(temp)){i3GEOoMenuBar.getMenuItem(temp).cfg.setProperty("checked",true)}}catch(e){}temp=["omenudataFerramentas7b","omenudataArquivos3","omenudataJanelas1","omenudataJanelas3","omenudataFerramentas2a"];n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("disabled",false)}}try{temp=[];switch(i3GEO.Interface.ATUAL){case"openlayers":temp=["omenudataArquivos3","omenudataJanelas1"];break;case"googlemaps":temp=["omenudataArquivos3","omenudataJanelas1","omenudataJanelas3"];break;case"googleearth":temp=["omenudataFerramentas7b","omenudataArquivos3","omenudataJanelas3","omenudataFerramentas2a"];break};n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("disabled",true)}}}catch(e){}temp=objid.style;temp.backgroundPosition="0px -1px";temp.border="0px solid white";if(ms.finaliza&&ms.finaliza!=""){eval(ms.finaliza)}},mostraMenuLista:function(id){var objid,n,i,sub,nomeMenu="",ms=i3GEO.gadgets.PARAMETROS.mostraMenuLista,confm=i3GEO.configura.oMenuData,ins="",subs=i3GEO.configura.oMenuData.submenus;if(arguments.length===0){id=ms.idhtml}else{ms.idhtml=id}objid=$i(id);if(objid){n=confm.menu.length;for(i=0;i<n;i+=1){ins+='<div class="listaMenuTitulo" id=menulista_'+confm.menu[i].id+'>'+confm.menu[i].nome+'</div>'}objid.innerHTML=ins;for(nomeMenu in subs){if($i("menulista_"+nomeMenu)){sub=subs[nomeMenu];n=sub.length;ins="";for(i=0;i<n;i++){ins+="<p class='listaMenuItem' ><a href='"+sub[i].url+"' target='_self'>"+sub[i].text+"</a>"}$i("menulista_"+nomeMenu).innerHTML+=ins}}}}}; | 276 | +if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.gadgets={PARAMETROS:{"mostraInserirKml":{idhtml:"inserirKml"},"mostraEscalaNumerica":{idhtml:"escala"},"mostraEscalaGrafica":{idhtml:"escalaGrafica"},"mostraBuscaRapida":{idhtml:"buscaRapida",servicosexternos:true,temasmapa:false,google:true},"mostraVisual":{idhtml:""},"mostraHistoricoZoom":{idhtml:"historicozoom"},"mostraMenuSuspenso":{permiteLogin:true,marcadores:true,idhtml:"menus",deslocaEsquerda:0,parametrosYUI:{iframe:false,autosubmenudisplay:false,showdelay:200,hidedelay:500,lazyload:false}},"mostraMenuLista":{idhtml:"menuLista"},"mostraVersao":{idhtml:"versaoi3geo"},"mostraEmail":{idhtml:"emailInstituicao"}},mostraEmail:function(id){if(arguments.length===0||id===""){id=i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml}else{i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml=id}i3GEO.util.defineValor(id,"innerHTML",i3GEO.parametros.emailInstituicao)},mostraVersao:function(id){if(arguments.length===0||id===""){id=i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml}else{i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml=id}i3GEO.util.defineValor(id,"innerHTML",i3GEO.parametros.mensageminicia)},mostraInserirKml:function(id){var i,ins,temp;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml}if($i(id)){if(!$i("i3geo_urlkml")){i=$inputText(id,"290","i3geo_urlkml","kml url","35","kml");ins="<table><tr><td>"+i;temp='i3GEO.Interface.adicionaKml();';ins+="</td><td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' class='tic' onclick='"+temp+"' /></td></tr></table>";$i(id).innerHTML=ins}}},mostraEscalaNumerica:function(id){var i,ins,temp,onde;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraEscalaNumerica.idhtml}onde=$i(id);if(onde){if(onde.style.display=="none"){onde.style.display="block"}if(!$i("i3geo_escalanum")){i="<form id='i3GEOescalanumForm' >"+$inputText(id,"100","i3geo_escalanum",$trad("d10"),"10",parseInt(i3GEO.parametros.mapscale,10))+"</form>";ins="<table style='width:120px;'><tr><td>"+i;temp='var nova = document.getElementById("i3geo_escalanum").value;';temp+='i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,nova);';ins+="</td></tr></table>";onde.innerHTML=ins;$i("i3GEOescalanumForm").onsubmit=function(){i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,document.getElementById("i3geo_escalanum").value);return false}}i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"])}},atualizaEscalaNumerica:function(escala){var e=$i("i3geo_escalanum");if(!e){i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"]);return}if(arguments.length===1){e.value=escala}else{if(i3GEO.parametros.mapscale!==""){e.value=parseInt(i3GEO.parametros.mapscale,10)}else{e.value=0}}},mostraEscalaGrafica:function(id){if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraEscalaGrafica.idhtml}var ins;if($i(id)){if(!$i("imagemEscalaGrafica")){ins="<img class='menuarrow' src=\""+i3GEO.configura.locaplic+"/imagens/branco.gif\" title='opções' onclick='i3GEO.mapa.dialogo.opcoesEscala()' style='cursor:pointer'/><img id=imagemEscalaGrafica src='' />";$i(id).innerHTML=ins}i3GEO.gadgets.atualizaEscalaGrafica();i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"])}},atualizaEscalaGrafica:function(){var e=$i("imagemEscalaGrafica");if(!e){i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"]);return}temp=function(retorno){eval(retorno.data);$i("imagemEscalaGrafica").src=scaimagem};i3GEO.php.escalagrafica(temp)},mostraBuscaRapida:function(id){var i,ins,temp,fbusca;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.idhtml}i3GEO.gadgets.mostraBuscaRapida.id=id;if($i(id)){i="<form id=i3GEObotaoFormBuscaRapida"+id+" >"+"<div class='i3geoForm' style='width:160px;'><input class=i3geoFormSemIcone type=text value='' id='valorBuscaRapida"+id+"' /></div>"+"</form>";ins="<table><tr><td><a class=ajuda_usuario target=_blank href='"+i3GEO.configura.locaplic+"/ajuda_usuario.php?idcategoria=8&idajuda=71' ><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif' /></a></td>"+"<td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' title='"+$trad("p13")+"' class='ticPropriedades2' id=i3GEObotaoPropriedadesBuscaRapida"+id+" style='margin-right:5px;margin-left:5px;'/></td>"+"<td>"+i+"</td>"+"<td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' class='ticfind' id=i3GEObotaoBuscaRapida"+id+" style='margin-left:3px;' /></td></tr></table>";temp=$i(id);if(temp){fbusca=function(){if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google===false&&i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos===false&&i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa===false){i3GEO.janela.tempoMsg($trad("x35"));return}if($i("valorBuscaRapida"+id).value===""){i3GEO.janela.tempoMsg($trad("x36"));return}i3GEO.janela.cria("300px","280px",i3GEO.configura.locaplic+"/ferramentas/buscarapida/index.htm","","",$trad("o2"));return false};temp.innerHTML=ins;$i("i3GEObotaoBuscaRapida"+id).onclick=fbusca;$i("i3GEObotaoFormBuscaRapida"+id).onsubmit=fbusca;$i("i3GEObotaoPropriedadesBuscaRapida"+id).onclick=function(){var ins,interno="",externo="",google="";i3GEO.janela.cria("300px","150px","","","",$trad("s5"),"i3GEOpropriedadesBuscaRapida"+id);if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos){externo="checked"}if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa){interno="checked"}ins="<p class=paragrafo >"+$trad("x37")+":</p>"+"<table class=lista3 >"+"<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos = this.checked' type=checkbox "+externo+" ></td><td> "+$trad("x38")+"</td></tr>"+"<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa = this.checked' type=checkbox "+interno+" ></td><td>"+$trad("x39")+"</td></tr>";if(i3GEO.Interface.ATUAL==="googlemaps"){if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google){google="checked"}ins+="<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google = this.checked' type=checkbox "+google+" ></td><td>Google</td></tr>"}else{i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google=false}ins+="</table><br>"+"<p class=paragrafo >"+$trad("x40")+"</p>";$i("i3GEOpropriedadesBuscaRapida"+id+"_corpo").innerHTML=ins}}}},mostraHistoricoZoom:function(id){if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraHistoricoZoom.idhtml}if($i(id)){marcadorZoom="";var ins="<table style='text-align:center;position:relative;left:";if(navm){ins+="0px;'>"}else{ins+="6px;'>"}ins+="<tr><td><img id='i3geo_zoomanterior' class='zoomAnterior' title='anterior' src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' /></td>";ins+="<td> </td>";ins+="<td><img id='i3geo_zoomproximo' class='zoomProximo' title='proximo' src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' /></td>";ins+="</tr></table>";$i(id).innerHTML=ins}},visual:{inicia:function(id){alert("A i3GEO.gadgets.visual foi depreciado")},troca:function(visual){alert("A i3GEO.gadgets.visual foi depreciado")}},mostraMenuSuspenso:function(id){var objid,n,i,estilo,t,onMenuBarBeforeRender,temp,i3GEOoMenuBarLocal,ms=i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso,confm=i3GEO.configura.oMenuData,ins="",alinhamento="";if(arguments.length===0){id=ms.idhtml}else{ms.idhtml=id}objid=$i(id);if(!objid){return}if(i3GEO.util.trim(objid.innerHTML)===""){try{if(ms.marcadores===true){i3GEO.configura.oMenuData=i3GEO.marcador.adicionaMenuSuspenso(i3GEO.configura.oMenuData)}}catch(e){}try{if(ms.permiteLogin===true||(ms.permiteLogin!=false&&i3GEO.parametros.editor==="sim")){i3GEO.configura.oMenuData=i3GEO.login.adicionaMenuSuspenso(i3GEO.configura.oMenuData)}}catch(e){}i3GEOoMenuBar=YAHOO.widget.MenuManager;if(objid){objid.className="yuimenubar";temp=$i("contemMenu");if(temp){temp.className="yui-navset"}if(ms.deslocaEsquerda){alinhamento="left:"+ms.deslocaEsquerda*-1+"px;"}if(temp&&(!temp.style.height||parseInt(temp.style.height)===0)){temp.style.height="30px"}if(objid.style.height&&parseInt(objid.style.height,10)===0){objid.style.height="0px"}ins+='<div class="bd" style="top:0px;'+alinhamento+'display:block;align:right;border: 0px solid white;z-index:3;line-height:1.4" >'+'<ul class="first-of-type" style="display:block;border:0px solid white;top:10px;">';n=confm.menu.length;estilo="padding-bottom:3px;top:0px;border: 0px solid white;";for(i=0;i<n;i+=1){t="";if(confm.menu[i].target){t="target="+confm.menu[i].target}if(confm.submenus[confm.menu[i].id].length>0){ins+='<li class="yuimenubaritem" style="padding-top:2px;"><a style="'+estilo+'" href="#" class="yuimenubaritemlabel" '+t+'id="menu'+confm.menu[i].id+'" > '+confm.menu[i].nome+'</a></li>'}}ins+='</ul>';ins+='</div>';objid.innerHTML=ins;if(i3GEO.Interface.ATUAL==="googleearth"){i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI.iframe=true}i3GEOoMenuBarLocal=new YAHOO.widget.MenuBar(id,i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI);onMenuBarBeforeRender=function(p_sType,p_sArgs){var nomeMenu="",nomeSub,subs=i3GEO.configura.oMenuData.submenus,conta=0;for(nomeMenu in subs){if($i("menu"+nomeMenu)){nomeSub=subs[nomeMenu];if(nomeSub!==""){i3GEOoMenuBarLocal.getItem(conta).cfg.setProperty('submenu',{id:nomeMenu,itemdata:nomeSub})}conta+=1}}};temp=$i("contemMenu");if(temp){i3GEOoMenuBarLocal.subscribe("beforeShow",function(){$i("contemMenu").style.zIndex=5000;return},i3GEO.configura.oMenuData.submenus);i3GEOoMenuBarLocal.subscribe("beforeHide",function(){$i("contemMenu").style.zIndex=1;return},i3GEO.configura.oMenuData.submenus)}i3GEOoMenuBar.addMenu(i3GEOoMenuBarLocal);i3GEOoMenuBarLocal.beforeRenderEvent.subscribe(onMenuBarBeforeRender);i3GEOoMenuBarLocal.render()}}temp=["omenudataInterface1","omenudataInterface2","omenudataInterface3","omenudataInterface4","omenudataInterface5"];n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("checked",false)}}try{temp="";switch(i3GEO.Interface.ATUAL){case"openlayers":temp="omenudataInterface2";break;case"googlemaps":temp="omenudataInterface4";break;case"googleearth":temp="omenudataInterface5";break}if(temp!=""&&$i(temp)){i3GEOoMenuBar.getMenuItem(temp).cfg.setProperty("checked",true)}}catch(e){}temp=["omenudataFerramentas7b","omenudataArquivos3","omenudataJanelas1","omenudataJanelas3","omenudataFerramentas2a"];n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("disabled",false)}}try{temp=[];switch(i3GEO.Interface.ATUAL){case"openlayers":temp=["omenudataArquivos3","omenudataJanelas1"];break;case"googlemaps":temp=["omenudataArquivos3","omenudataJanelas1","omenudataJanelas3"];break;case"googleearth":temp=["omenudataFerramentas7b","omenudataArquivos3","omenudataJanelas3","omenudataFerramentas2a"];break};n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("disabled",true)}}}catch(e){}temp=objid.style;temp.backgroundPosition="0px -1px";temp.border="0px solid white";if(ms.finaliza&&ms.finaliza!=""){eval(ms.finaliza)}},mostraMenuLista:function(id){var objid,n,i,sub,nomeMenu="",ms=i3GEO.gadgets.PARAMETROS.mostraMenuLista,confm=i3GEO.configura.oMenuData,ins="",subs=i3GEO.configura.oMenuData.submenus;if(arguments.length===0){id=ms.idhtml}else{ms.idhtml=id}objid=$i(id);if(objid){n=confm.menu.length;for(i=0;i<n;i+=1){ins+='<div class="listaMenuTitulo" id=menulista_'+confm.menu[i].id+'>'+confm.menu[i].nome+'</div>'}objid.innerHTML=ins;for(nomeMenu in subs){if($i("menulista_"+nomeMenu)){sub=subs[nomeMenu];n=sub.length;ins="";for(i=0;i<n;i++){ins+="<p class='listaMenuItem' ><a href='"+sub[i].url+"' target='_self'>"+sub[i].text+"</a>"}$i("menulista_"+nomeMenu).innerHTML+=ins}}}}}; |
277 | // | 277 | // |
278 | //compactados/classe_social_compacto.js | 278 | //compactados/classe_social_compacto.js |
279 | if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.social={curtirFacebook:function(url,tipo){if(tipo==="comtotal"){return"<iframe src='http://www.facebook.com/plugins/like.php?href="+url+"&layout=button_count&show_faces=false&width=160&action=like&colorscheme=light&height=21' scrolling='no' frameborder='0' style='border:none; overflow:hidden; width:160px; height:21px;' allowTransparency='true'></iframe>"}if(tipo==="semtotal"){return"<iframe src='http://www.facebook.com/plugins/like.php?href="+url+"&layout=button_count&show_faces=false&action=like&colorscheme=light&height=21' scrolling='no' frameborder='0' style='border:none; overflow:hidden; width:100px; height:21px;' allowTransparency='true'></iframe>"}},publicarTwitter:function(url,tipo){var re=new RegExp("=","g");url=url.replace(re,'%3d');if(tipo==="comtotal"){return'<iframe allowtransparency="true" frameborder="0" scrolling="no" src="http://platform.twitter.com/widgets/tweet_button.html?count=horizontal&via=i3geo&url='+url+'" style="width:100px; height:21px;"></iframe>'}if(tipo==="semtotal"){return'<iframe allowtransparency="true" frameborder="0" scrolling="no" src="http://platform.twitter.com/widgets/tweet_button.html?count=none&via=i3geo&url='+url+'" style="width:65px; height:21px;"></iframe>'}},compartilhar:function(id,urlcf,urlpt,tipo,locaplic){if(!locaplic){locaplic=i3GEO.configura.locaplic}if(!tipo){tipo="comtotal"}var onde=$i(id),tabela="";if(tipo==="comtotal"){tabela+="<table style='width:250px' ><tr>"}if(tipo==="semtotal"){tabela+="<table style='width:115px' ><tr>"}if(onde||id===""){if(urlpt!==""){tabela+="<td>"+i3GEO.social.publicarTwitter(urlpt,tipo)+"</td>"}if(urlcf!==""){tabela+="<td>"+i3GEO.social.curtirFacebook(urlcf,tipo)+"</td>"}tabela+="</tr></table>";if(id!==""){onde.innerHTML=tabela}return tabela}else{return false}},bookmark:function(link,locaplic){if(!locaplic){locaplic=i3GEO.configura.locaplic}var ins="<img style='cursor:pointer' src='"+locaplic+"/imagens/delicious.gif' onclick='javascript:window.open(\"http://del.icio.us/post?url="+link+"\")' title='Delicious'/> ";ins+="<img style='cursor:pointer' src='"+locaplic+"/imagens/digg.gif' onclick='javascript:window.open(\"http://digg.com/submit/post?url="+link+"\")' title='Digg'/> ";ins+="<img style='cursor:pointer' src='"+locaplic+"/imagens/facebook.gif' onclick='javascript:window.open(\"http://www.facebook.com/sharer.php?u="+link+"\")' title='Facebook'/> ";ins+="<img style='cursor:pointer' src='"+locaplic+"/imagens/stumbleupon.gif' onclick='javascript:window.open(\"http://www.stumbleupon.com/submit?url="+link+"\")' title='StumbleUpon'/>";return ins}}; | 279 | if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.social={curtirFacebook:function(url,tipo){if(tipo==="comtotal"){return"<iframe src='http://www.facebook.com/plugins/like.php?href="+url+"&layout=button_count&show_faces=false&width=160&action=like&colorscheme=light&height=21' scrolling='no' frameborder='0' style='border:none; overflow:hidden; width:160px; height:21px;' allowTransparency='true'></iframe>"}if(tipo==="semtotal"){return"<iframe src='http://www.facebook.com/plugins/like.php?href="+url+"&layout=button_count&show_faces=false&action=like&colorscheme=light&height=21' scrolling='no' frameborder='0' style='border:none; overflow:hidden; width:100px; height:21px;' allowTransparency='true'></iframe>"}},publicarTwitter:function(url,tipo){var re=new RegExp("=","g");url=url.replace(re,'%3d');if(tipo==="comtotal"){return'<iframe allowtransparency="true" frameborder="0" scrolling="no" src="http://platform.twitter.com/widgets/tweet_button.html?count=horizontal&via=i3geo&url='+url+'" style="width:100px; height:21px;"></iframe>'}if(tipo==="semtotal"){return'<iframe allowtransparency="true" frameborder="0" scrolling="no" src="http://platform.twitter.com/widgets/tweet_button.html?count=none&via=i3geo&url='+url+'" style="width:65px; height:21px;"></iframe>'}},compartilhar:function(id,urlcf,urlpt,tipo,locaplic){if(!locaplic){locaplic=i3GEO.configura.locaplic}if(!tipo){tipo="comtotal"}var onde=$i(id),tabela="";if(tipo==="comtotal"){tabela+="<table style='width:250px' ><tr>"}if(tipo==="semtotal"){tabela+="<table style='width:115px' ><tr>"}if(onde||id===""){if(urlpt!==""){tabela+="<td>"+i3GEO.social.publicarTwitter(urlpt,tipo)+"</td>"}if(urlcf!==""){tabela+="<td>"+i3GEO.social.curtirFacebook(urlcf,tipo)+"</td>"}tabela+="</tr></table>";if(id!==""){onde.innerHTML=tabela}return tabela}else{return false}},bookmark:function(link,locaplic){if(!locaplic){locaplic=i3GEO.configura.locaplic}var ins="<img style='cursor:pointer' src='"+locaplic+"/imagens/delicious.gif' onclick='javascript:window.open(\"http://del.icio.us/post?url="+link+"\")' title='Delicious'/> ";ins+="<img style='cursor:pointer' src='"+locaplic+"/imagens/digg.gif' onclick='javascript:window.open(\"http://digg.com/submit/post?url="+link+"\")' title='Digg'/> ";ins+="<img style='cursor:pointer' src='"+locaplic+"/imagens/facebook.gif' onclick='javascript:window.open(\"http://www.facebook.com/sharer.php?u="+link+"\")' title='Facebook'/> ";ins+="<img style='cursor:pointer' src='"+locaplic+"/imagens/stumbleupon.gif' onclick='javascript:window.open(\"http://www.stumbleupon.com/submit?url="+link+"\")' title='StumbleUpon'/>";return ins}}; |
classesjs/i3geo_tudo_compacto6.js.php
@@ -273,7 +273,7 @@ if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.barraDeBotoes={BARRAS:[],BOTA | @@ -273,7 +273,7 @@ if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.barraDeBotoes={BARRAS:[],BOTA | ||
273 | if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.coordenadas={formato:"bloco",padrao:"geoProj",defOrigem:"+proj=longlat +ellps=GRS67 +no_defs",config:{"geoProj":{idhtml:"localizarxy",tipo:"geo",titulo:"Geo",ativo:true,defepsg:""},"dd":{idhtml:"localizarxy",tipo:"metrica",titulo:"Déc. de grau",ativo:true,defepsg:""},"geohash":{idhtml:"localizarxy",tipo:"codigo",tipoCodigo:"geohash",titulo:"GeoHash",ativo:true},"policonicaSad69":{idhtml:"localizarxy",tipo:"metrica",titulo:"Polic SAD-69",ativo:true,defepsg:"+proj=poly +lat_0=0 +lon_0=-54 +x_0=5000000 +y_0=10000000 +ellps=aust_SA +units=m +no_defs"},"utmSad69Proj":{idhtml:"localizarxy",tipo:"utm",titulo:"UTM Sad-69",ativo:true,defepsg:"",zona:{"19N":"+proj=utm +zone=19 +ellps=aust_SA +units=m +no_defs","20N":"+proj=utm +zone=20 +ellps=aust_SA +units=m +no_defs","21N":"+proj=utm +zone=21 +ellps=aust_SA +units=m +no_defs","22N":"+proj=utm +zone=22 +ellps=aust_SA +units=m +no_defs","17S":"+proj=utm +zone=17 +south +ellps=aust_SA +units=m +no_defs","18S":"+proj=utm +zone=18 +south +ellps=aust_SA +units=m +no_defs","19S":"+proj=utm +zone=19 +south +ellps=aust_SA +units=m +no_defs","20S":"+proj=utm +zone=20 +south +ellps=aust_SA +units=m +no_defs","21S":"+proj=utm +zone=21 +south +ellps=aust_SA +units=m +no_defs","22S":"+proj=utm +zone=22 +south +ellps=aust_SA +units=m +no_defs","23S":"+proj=utm +zone=23 +south +ellps=aust_SA +units=m +no_defs","24S":"+proj=utm +zone=24 +south +ellps=aust_SA +units=m +no_defs","25S":"+proj=utm +zone=25 +south +ellps=aust_SA +units=m +no_defs"}},"utmSirgas2000Proj":{idhtml:"localizarxy",tipo:"utm",titulo:"UTM Sirgas",ativo:true,defepsg:"",zona:{"11N":"+proj=utm +zone=11 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","12N":"+proj=utm +zone=12 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","13N":"+proj=utm +zone=13 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","14N":"+proj=utm +zone=14 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","15N":"+proj=utm +zone=15 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","16N":"+proj=utm +zone=16 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","17N":"+proj=utm +zone=17 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","18N":"+proj=utm +zone=18 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","19N":"+proj=utm +zone=19 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","20N":"+proj=utm +zone=20 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","21N":"+proj=utm +zone=21 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","22N":"+proj=utm +zone=22 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","17S":"+proj=utm +zone=17 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","18S":"+proj=utm +zone=18 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","19S":"+proj=utm +zone=19 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","20S":"+proj=utm +zone=20 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","21S":"+proj=utm +zone=21 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","22S":"+proj=utm +zone=22 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","23S":"+proj=utm +zone=23 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","24S":"+proj=utm +zone=24 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","25S":"+proj=utm +zone=25 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs"}}},PARAMETROS:{"mostraCoordenadasUTM":{idhtml:"localizarxy"},"mostraCoordenadasGEO":{idhtml:"localizarxy"},"mostraCoordenadasGeohash":{idhtml:"localizarxy"}},MODOTEXTO:"",mostraCoordenadasGEO:function(id){try{if(arguments.length===0||id===""||typeof(id)==='undefined'){id=this.PARAMETROS.mostraCoordenadasGEO.idhtml}else{this.PARAMETROS.mostraCoordenadasGEO.idhtml=id}if($i(id)){if(!$i("coordgeotabela")){$i(id).innerHTML=i3GEO.coordenadas.criaMascaraDMS("coordgeotabela");if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",["i3GEO.coordenadas.atualizaLocalizarGeo()"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",["i3GEO.coordenadas.atualizaLocalizarGeo()"])}}}}catch(e){i3GEO.janela.tempoMsg("mostraCoordenadasGeo: "+e.description)}},atualizaLocalizarGeo:function(id,x,y){if(!id){id="coordgeotabela"}if(typeof(x)==='undefined'){x=objposicaocursor.dmsx}if(typeof(y)==='undefined'){y=objposicaocursor.dmsy}var temp=$i(id);if(temp&&temp.style.display==="block"){i3GEO.coordenadas.atualizaGeo(x,y,id)}},geo2zonaUtm:function(l){l=(l*1)+180;l=l/6;return parseInt(l,10)+1},criaMascaraDMS:function(prefixo,titulo,caixa){var ins='<table class="i3GeoMascaraCoord" id='+prefixo+' ><tr>'+"<td>"+caixa+" </td>"+'<td style=width:10px;text-align:right > X: </td>'+'<td>'+$inputText('','',prefixo+'xg','grau','3','-00')+'</td>'+'<td>'+$inputText('','',prefixo+'xm','minuto','2','00')+'</td>'+'<td>'+$inputText('','',prefixo+'xs','segundo','5','00.00')+'</td>'+'<td> Y: '+$inputText('','',prefixo+'yg','grau','3','-00')+'</td>'+'<td>'+$inputText('','',prefixo+'ym','minuto','2','00')+'</td>'+'<td>'+$inputText('','',prefixo+'ys','segundo','5','00.00')+'</td>',temp='var '+prefixo+'xxx = i3GEO.calculo.dms2dd($i(\''+prefixo+'xg\').value,$i(\''+prefixo+'xm\').value,$i(\''+prefixo+'xs\').value);'+'var '+prefixo+'yyy = i3GEO.calculo.dms2dd($i(\''+prefixo+'yg\').value,$i(\''+prefixo+'ym\').value,$i(\''+prefixo+'ys\').value);'+'i3GEO.navega.zoomponto(i3GEO.configura.locaplic,i3GEO.configura.sid,'+prefixo+'xxx,'+prefixo+'yyy);';ins+='<td><img class=ticfind style="margin-left:8px;" title=zoom onclick="'+temp+'" src="'+i3GEO.configura.locaplic+"/imagens/branco.gif"+'" /></td>'+"</tr></table>";return ins},atualizaGeo:function(dmsx,dmsy,prefixo){var x=dmsx.split(" "),y=dmsy.split(" ");if($i(prefixo+"xg")){$i(prefixo+"xg").value=x[0];$i(prefixo+"xm").value=x[1];$i(prefixo+"xs").value=x[2];$i(prefixo+"yg").value=y[0];$i(prefixo+"ym").value=y[1];$i(prefixo+"ys").value=y[2]}i3GEO.coordenadas.MODOTEXTO+="DMS - Latitude: "+y[0]+" "+y[1]+" "+y[2]+" Longitude: "+x[0]+" "+x[1]+" "+x[2]+"<br><br>"},criaMascaraMetrica:function(prefixo,titulo,caixa){var ins="<table id="+prefixo+" class='i3GeoMascaraCoord' ><tr>"+"<td>"+caixa+" <td>"+"<td style=width:100px;text-align:right >"+titulo+" X: </td>"+"<td>"+$inputText("","",prefixo+"X","X","12","00")+" </td>"+"<td>Y:"+$inputText("","",prefixo+"Y","Y","12","00")+" </td>"+"<td>Zn:"+$inputText("","",prefixo+"ZN","Zona","2","--")+" </td>"+"</tr></table>";return ins},criaMascaraCodigo:function(prefixo,titulo,caixa,tipoCodigo){var funcao="",ins="";if(tipoCodigo==="geohash"){funcao="i3GEO.coordenadas.geohash.zoomCodigo(\'"+prefixo+"Codigo\')"}ins="<table id="+prefixo+" class='i3GeoMascaraCoord' ><tr>"+"<td>"+caixa+" <td>"+"<td style=width:100px;text-align:right >"+titulo+" : </td>"+"<td>"+$inputText("","",prefixo+"Codigo","Cod","12","00")+" </td>"+'<td><img class=tic title=zoom onclick="'+funcao+'" src="'+i3GEO.configura.locaplic+"/imagens/branco.gif"+'" /></td>'+"</tr></table>";return ins},atualizaCodigo:function(onde,configProj,x,y){var ondeValor=$i(onde+configProj+"Codigo");onde=$i(onde),temp=i3GEO.coordenadas.config[configProj],codigo="";if(onde&&onde.style.display==="none"){return}if(typeof(x)==='undefined'){x=objposicaocursor.ddx}if(typeof(y)==='undefined'){y=objposicaocursor.ddy}if(temp.tipoCodigo==="geohash"){codigo=i3GEO.coordenadas.geohash.encodeGeoHash(y,x)}i3GEO.coordenadas.MODOTEXTO+=temp.titulo+" : "+codigo+"<br><br>";if(ondeValor){ondeValor.value=codigo}},atualizaProj4:function(onde,configProj,x,y){var zona,temp,p,destino="",iu=i3GEO.util;try{if(!$i(onde+configProj+"ZN")){return}}catch(e){return}temp=i3GEO.coordenadas.config[configProj];try{if($i(onde+configProj).style.display==="none"){return}}catch(men){}if(temp.tipo==="metrica"){destino=temp.defepsg}if(typeof(x)==='undefined'){x=objposicaocursor.ddx}if(typeof(y)==='undefined'){y=objposicaocursor.ddy}if(temp.tipo==="utm"){zona=i3GEO.coordenadas.geo2zonaUtm(x);$i(onde+configProj+"ZN").value=zona;if(objposicaocursor.ddy*1>0){destino=temp.zona[zona+"N"]}else{destino=temp.zona[zona+"S"]}if(typeof(destino)==='undefined'){iu.defineValor(onde+configProj+"X","value","?");iu.defineValor(onde+configProj+"Y","value","?");return}}if(temp.defepsg===""&&temp.tipo==="metrica"){p={x:x,y:y}}else{p=i3GEO.coordenadas.calculaProj4(i3GEO.coordenadas.defOrigem,destino,x,y)}iu.defineValor(onde+configProj+"X","value",p.x);iu.defineValor(onde+configProj+"Y","value",p.y);i3GEO.coordenadas.MODOTEXTO+=temp.titulo+" - X: "+p.x+" Y: "+p.y+"<br><br>"},calculaProj4:function(origem,destino,x,y){Proj4js.defs={'ORIGEM':origem,'DESTINO':destino};Proj4js.getScriptLocation=function(){return i3GEO.configura.locaplic+"/pacotes/proj4js/lib/"};var source=new Proj4js.Proj("ORIGEM"),dest=new Proj4js.Proj("DESTINO"),p=new Proj4js.Point(x,y);Proj4js.transform(source,dest,p);return p},ativaBloco:function(prefixo){var tipos=i3GEO.util.listaChaves(i3GEO.coordenadas.config),n=tipos.length,temp,i=0;for(i=0;i<n;i++){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){if(tipos[i]===this.padrao){$i(prefixo+tipos[i]).style.display="block"}else{$i(prefixo+tipos[i]).style.display="none"}}}},mudaTipo:function(obj,onde){if(obj.value==="janela"){this.formato="janela";this.mostraCoordenadas();return}this.padrao=obj.value;obj.selectedIndex=0;i3GEO.coordenadas.ativaBloco(onde)},mostraCoordenadas:function(ativaMovimento,onde,x,y){try{var tipos=i3GEO.util.listaChaves(i3GEO.coordenadas.config),n=tipos.length,temp,ins="",i=0,caixa,janela,nomeFunc;i3GEO.coordenadas.MODOTEXTO="";if(arguments.length===0){ativaMovimento=true;onde=""}if(onde===""){onde=i3GEO.coordenadas.config[tipos[0]].idhtml}caixa="<select onchange='javascript:i3GEO.coordenadas.mudaTipo(this,\""+onde+"\");' class='i3geoCoordenadasComboTipo' ><option>---</option><option value='janela' >janela</option>";for(i=0;i<n;i+=1){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){caixa+="<option value='"+tipos[i]+"'>"+temp.titulo+"</option>"}}caixa+="</select>";if(i3GEO.coordenadas.formato!=="bloco"){caixa=""}for(i=0;i<n;i+=1){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){if(temp.tipo==="geo"){ins+=i3GEO.coordenadas.criaMascaraDMS(onde+tipos[i],temp.titulo,caixa);if(i3GEO.coordenadas.formato==="separado"){try{$i(temp.idhtml).innerHTML=ins}catch(e){}ins=""}}else{if(temp.tipo==="codigo"){ins+=i3GEO.coordenadas.criaMascaraCodigo(onde+tipos[i],temp.titulo,caixa,temp.tipoCodigo)}else{ins+=i3GEO.coordenadas.criaMascaraMetrica(onde+tipos[i],temp.titulo,caixa)}}}}if(this.formato==="janela"){janela=i3GEO.janela.cria("450px","120px","","","",$trad("x49"),"i3GEOJanelaCoordenadas",false,"hd","","");YAHOO.util.Event.addListener(janela[0].close,"click",function(){i3GEO.coordenadas.formato="bloco",i3GEO.coordenadas.mostraCoordenadas()});temp=$i("i3GEOJanelaCoordenadas_corpo");temp.style.backgroundColor="white";temp.style.textAlign="left";temp=$i("i3GEOJanelaCoordenadas");temp.onmouseover="";temp.onmouseout="";if($i(onde)){$i(onde).innerHTML=""}onde="i3GEOJanelaCoordenadas_corpo";ins+="<br><a href='#' style='cursor:pointer;color:blue' onclick='new YAHOO.util.KeyListener(document.body,{alt:true,keys:67},{fn: function(type, args, obj){i3GEO.janela.tempoMsg(i3GEO.coordenadas.MODOTEXTO);}}).enable();' >"+"Clique aqui para ativar Alt+C para poder capturar as coordenadas</a>"}if(onde!==""&&$i(onde)){$i(onde).innerHTML=ins}for(i=0;i<n;i+=1){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){if(temp.tipo==="geo"){if(ativaMovimento===true){if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",["i3GEO.coordenadas.atualizaLocalizarGeo('"+onde+tipos[i]+"')"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",["i3GEO.coordenadas.atualizaLocalizarGeo('"+onde+tipos[i]+"')"])}}if(typeof(x)!=='undefined'){i3GEO.coordenadas.atualizaLocalizarGeo(onde+tipos[i],i3GEO.calculo.dd2dms(x)[0],i3GEO.calculo.dd2dms(y)[0])}}else{nomeFunc="i3GEO.coordenadas.atualizaProj4";if(temp.tipo==="codigo"){nomeFunc="i3GEO.coordenadas.atualizaCodigo"}if(ativaMovimento===true){if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",[nomeFunc+"('"+onde+"','"+tipos[i]+"')"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",[nomeFunc+"('"+onde+"','"+tipos[i]+"')"])}}if(typeof(x)!=='undefined'){eval(nomeFunc+"(onde,tipos[i],x,y);")}}}}if(ativaMovimento===true){if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",["i3GEO.coordenadas.limpaModoTexto()"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",["i3GEO.coordenadas.limpaModoTexto()"])}}if(i3GEO.coordenadas.formato==="bloco"){i3GEO.coordenadas.ativaBloco(onde)}}catch(men){}},limpaModoTexto:function(){i3GEO.coordenadas.MODOTEXTO=""},geohash:{BITS:[16,8,4,2,1],BASE32:"0123456789bcdefghjkmnpqrstuvwxyz",refine_interval:function(interval,cd,mask){if(cd&mask)interval[0]=(interval[0]+interval[1])/2;else interval[1]=(interval[0]+interval[1])/2},decodeGeoHash:function(geohash){var is_even=1,lat=[],lon=[],i,j,x,y;lat[0]=-90.0;lat[1]=90.0;lon[0]=-180.0;lon[1]=180.0;lat_err=90.0;lon_err=180.0;for(i=0;i<geohash.length;i++){c=geohash[i];cd=i3GEO.coordenadas.geohash.BASE32.indexOf(c);for(j=0;j<5;j++){mask=i3GEO.coordenadas.geohash.BITS[j];if(is_even){lon_err/=2;i3GEO.coordenadas.geohash.refine_interval(lon,cd,mask)}else{lat_err/=2;i3GEO.coordenadas.geohash.refine_interval(lat,cd,mask)}is_even=!is_even}}lat[2]=(lat[0]+lat[1])/2;lon[2]=(lon[0]+lon[1])/2;y=(lat[0]+lat[1])/2;x=(lon[0]+lon[1])/2;return{latitude:y,longitude:x}},encodeGeoHash:function(latitude,longitude){var is_even=1,lat=[],lon=[],bit=0,ch=0,precision=12,geohash="";lat[0]=-90.0;lat[1]=90.0;lon[0]=-180.0;lon[1]=180.0;while(geohash.length<precision){if(is_even){mid=(lon[0]+lon[1])/2;if(longitude>mid){ch|=i3GEO.coordenadas.geohash.BITS[bit];lon[0]=mid}else lon[1]=mid}else{mid=(lat[0]+lat[1])/2;if(latitude>mid){ch|=i3GEO.coordenadas.geohash.BITS[bit];lat[0]=mid}else lat[1]=mid}is_even=!is_even;if(bit<4)bit++;else{geohash+=i3GEO.coordenadas.geohash.BASE32[ch];bit=0;ch=0}}return geohash},zoomCodigo:function(idobj){var codigo;if($i(idobj)){codigo=$i(idobj).value}else{codigo=idobj}codigo=i3GEO.coordenadas.geohash.decodeGeoHash(codigo);i3GEO.navega.zoomponto(i3GEO.configura.locaplic,i3GEO.configura.sid,codigo.longitude,codigo.latitude)}}}; | 273 | if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.coordenadas={formato:"bloco",padrao:"geoProj",defOrigem:"+proj=longlat +ellps=GRS67 +no_defs",config:{"geoProj":{idhtml:"localizarxy",tipo:"geo",titulo:"Geo",ativo:true,defepsg:""},"dd":{idhtml:"localizarxy",tipo:"metrica",titulo:"Déc. de grau",ativo:true,defepsg:""},"geohash":{idhtml:"localizarxy",tipo:"codigo",tipoCodigo:"geohash",titulo:"GeoHash",ativo:true},"policonicaSad69":{idhtml:"localizarxy",tipo:"metrica",titulo:"Polic SAD-69",ativo:true,defepsg:"+proj=poly +lat_0=0 +lon_0=-54 +x_0=5000000 +y_0=10000000 +ellps=aust_SA +units=m +no_defs"},"utmSad69Proj":{idhtml:"localizarxy",tipo:"utm",titulo:"UTM Sad-69",ativo:true,defepsg:"",zona:{"19N":"+proj=utm +zone=19 +ellps=aust_SA +units=m +no_defs","20N":"+proj=utm +zone=20 +ellps=aust_SA +units=m +no_defs","21N":"+proj=utm +zone=21 +ellps=aust_SA +units=m +no_defs","22N":"+proj=utm +zone=22 +ellps=aust_SA +units=m +no_defs","17S":"+proj=utm +zone=17 +south +ellps=aust_SA +units=m +no_defs","18S":"+proj=utm +zone=18 +south +ellps=aust_SA +units=m +no_defs","19S":"+proj=utm +zone=19 +south +ellps=aust_SA +units=m +no_defs","20S":"+proj=utm +zone=20 +south +ellps=aust_SA +units=m +no_defs","21S":"+proj=utm +zone=21 +south +ellps=aust_SA +units=m +no_defs","22S":"+proj=utm +zone=22 +south +ellps=aust_SA +units=m +no_defs","23S":"+proj=utm +zone=23 +south +ellps=aust_SA +units=m +no_defs","24S":"+proj=utm +zone=24 +south +ellps=aust_SA +units=m +no_defs","25S":"+proj=utm +zone=25 +south +ellps=aust_SA +units=m +no_defs"}},"utmSirgas2000Proj":{idhtml:"localizarxy",tipo:"utm",titulo:"UTM Sirgas",ativo:true,defepsg:"",zona:{"11N":"+proj=utm +zone=11 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","12N":"+proj=utm +zone=12 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","13N":"+proj=utm +zone=13 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","14N":"+proj=utm +zone=14 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","15N":"+proj=utm +zone=15 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","16N":"+proj=utm +zone=16 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","17N":"+proj=utm +zone=17 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","18N":"+proj=utm +zone=18 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","19N":"+proj=utm +zone=19 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","20N":"+proj=utm +zone=20 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","21N":"+proj=utm +zone=21 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","22N":"+proj=utm +zone=22 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","17S":"+proj=utm +zone=17 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","18S":"+proj=utm +zone=18 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","19S":"+proj=utm +zone=19 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","20S":"+proj=utm +zone=20 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","21S":"+proj=utm +zone=21 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","22S":"+proj=utm +zone=22 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","23S":"+proj=utm +zone=23 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","24S":"+proj=utm +zone=24 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs","25S":"+proj=utm +zone=25 +south +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs"}}},PARAMETROS:{"mostraCoordenadasUTM":{idhtml:"localizarxy"},"mostraCoordenadasGEO":{idhtml:"localizarxy"},"mostraCoordenadasGeohash":{idhtml:"localizarxy"}},MODOTEXTO:"",mostraCoordenadasGEO:function(id){try{if(arguments.length===0||id===""||typeof(id)==='undefined'){id=this.PARAMETROS.mostraCoordenadasGEO.idhtml}else{this.PARAMETROS.mostraCoordenadasGEO.idhtml=id}if($i(id)){if(!$i("coordgeotabela")){$i(id).innerHTML=i3GEO.coordenadas.criaMascaraDMS("coordgeotabela");if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",["i3GEO.coordenadas.atualizaLocalizarGeo()"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",["i3GEO.coordenadas.atualizaLocalizarGeo()"])}}}}catch(e){i3GEO.janela.tempoMsg("mostraCoordenadasGeo: "+e.description)}},atualizaLocalizarGeo:function(id,x,y){if(!id){id="coordgeotabela"}if(typeof(x)==='undefined'){x=objposicaocursor.dmsx}if(typeof(y)==='undefined'){y=objposicaocursor.dmsy}var temp=$i(id);if(temp&&temp.style.display==="block"){i3GEO.coordenadas.atualizaGeo(x,y,id)}},geo2zonaUtm:function(l){l=(l*1)+180;l=l/6;return parseInt(l,10)+1},criaMascaraDMS:function(prefixo,titulo,caixa){var ins='<table class="i3GeoMascaraCoord" id='+prefixo+' ><tr>'+"<td>"+caixa+" </td>"+'<td style=width:10px;text-align:right > X: </td>'+'<td>'+$inputText('','',prefixo+'xg','grau','3','-00')+'</td>'+'<td>'+$inputText('','',prefixo+'xm','minuto','2','00')+'</td>'+'<td>'+$inputText('','',prefixo+'xs','segundo','5','00.00')+'</td>'+'<td> Y: '+$inputText('','',prefixo+'yg','grau','3','-00')+'</td>'+'<td>'+$inputText('','',prefixo+'ym','minuto','2','00')+'</td>'+'<td>'+$inputText('','',prefixo+'ys','segundo','5','00.00')+'</td>',temp='var '+prefixo+'xxx = i3GEO.calculo.dms2dd($i(\''+prefixo+'xg\').value,$i(\''+prefixo+'xm\').value,$i(\''+prefixo+'xs\').value);'+'var '+prefixo+'yyy = i3GEO.calculo.dms2dd($i(\''+prefixo+'yg\').value,$i(\''+prefixo+'ym\').value,$i(\''+prefixo+'ys\').value);'+'i3GEO.navega.zoomponto(i3GEO.configura.locaplic,i3GEO.configura.sid,'+prefixo+'xxx,'+prefixo+'yyy);';ins+='<td><img class=ticfind style="margin-left:8px;" title=zoom onclick="'+temp+'" src="'+i3GEO.configura.locaplic+"/imagens/branco.gif"+'" /></td>'+"</tr></table>";return ins},atualizaGeo:function(dmsx,dmsy,prefixo){var x=dmsx.split(" "),y=dmsy.split(" ");if($i(prefixo+"xg")){$i(prefixo+"xg").value=x[0];$i(prefixo+"xm").value=x[1];$i(prefixo+"xs").value=x[2];$i(prefixo+"yg").value=y[0];$i(prefixo+"ym").value=y[1];$i(prefixo+"ys").value=y[2]}i3GEO.coordenadas.MODOTEXTO+="DMS - Latitude: "+y[0]+" "+y[1]+" "+y[2]+" Longitude: "+x[0]+" "+x[1]+" "+x[2]+"<br><br>"},criaMascaraMetrica:function(prefixo,titulo,caixa){var ins="<table id="+prefixo+" class='i3GeoMascaraCoord' ><tr>"+"<td>"+caixa+" <td>"+"<td style=width:100px;text-align:right >"+titulo+" X: </td>"+"<td>"+$inputText("","",prefixo+"X","X","12","00")+" </td>"+"<td>Y:"+$inputText("","",prefixo+"Y","Y","12","00")+" </td>"+"<td>Zn:"+$inputText("","",prefixo+"ZN","Zona","2","--")+" </td>"+"</tr></table>";return ins},criaMascaraCodigo:function(prefixo,titulo,caixa,tipoCodigo){var funcao="",ins="";if(tipoCodigo==="geohash"){funcao="i3GEO.coordenadas.geohash.zoomCodigo(\'"+prefixo+"Codigo\')"}ins="<table id="+prefixo+" class='i3GeoMascaraCoord' ><tr>"+"<td>"+caixa+" <td>"+"<td style=width:100px;text-align:right >"+titulo+" : </td>"+"<td>"+$inputText("","",prefixo+"Codigo","Cod","12","00")+" </td>"+'<td><img class=tic title=zoom onclick="'+funcao+'" src="'+i3GEO.configura.locaplic+"/imagens/branco.gif"+'" /></td>'+"</tr></table>";return ins},atualizaCodigo:function(onde,configProj,x,y){var ondeValor=$i(onde+configProj+"Codigo");onde=$i(onde),temp=i3GEO.coordenadas.config[configProj],codigo="";if(onde&&onde.style.display==="none"){return}if(typeof(x)==='undefined'){x=objposicaocursor.ddx}if(typeof(y)==='undefined'){y=objposicaocursor.ddy}if(temp.tipoCodigo==="geohash"){codigo=i3GEO.coordenadas.geohash.encodeGeoHash(y,x)}i3GEO.coordenadas.MODOTEXTO+=temp.titulo+" : "+codigo+"<br><br>";if(ondeValor){ondeValor.value=codigo}},atualizaProj4:function(onde,configProj,x,y){var zona,temp,p,destino="",iu=i3GEO.util;try{if(!$i(onde+configProj+"ZN")){return}}catch(e){return}temp=i3GEO.coordenadas.config[configProj];try{if($i(onde+configProj).style.display==="none"){return}}catch(men){}if(temp.tipo==="metrica"){destino=temp.defepsg}if(typeof(x)==='undefined'){x=objposicaocursor.ddx}if(typeof(y)==='undefined'){y=objposicaocursor.ddy}if(temp.tipo==="utm"){zona=i3GEO.coordenadas.geo2zonaUtm(x);$i(onde+configProj+"ZN").value=zona;if(objposicaocursor.ddy*1>0){destino=temp.zona[zona+"N"]}else{destino=temp.zona[zona+"S"]}if(typeof(destino)==='undefined'){iu.defineValor(onde+configProj+"X","value","?");iu.defineValor(onde+configProj+"Y","value","?");return}}if(temp.defepsg===""&&temp.tipo==="metrica"){p={x:x,y:y}}else{p=i3GEO.coordenadas.calculaProj4(i3GEO.coordenadas.defOrigem,destino,x,y)}iu.defineValor(onde+configProj+"X","value",p.x);iu.defineValor(onde+configProj+"Y","value",p.y);i3GEO.coordenadas.MODOTEXTO+=temp.titulo+" - X: "+p.x+" Y: "+p.y+"<br><br>"},calculaProj4:function(origem,destino,x,y){Proj4js.defs={'ORIGEM':origem,'DESTINO':destino};Proj4js.getScriptLocation=function(){return i3GEO.configura.locaplic+"/pacotes/proj4js/lib/"};var source=new Proj4js.Proj("ORIGEM"),dest=new Proj4js.Proj("DESTINO"),p=new Proj4js.Point(x,y);Proj4js.transform(source,dest,p);return p},ativaBloco:function(prefixo){var tipos=i3GEO.util.listaChaves(i3GEO.coordenadas.config),n=tipos.length,temp,i=0;for(i=0;i<n;i++){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){if(tipos[i]===this.padrao){$i(prefixo+tipos[i]).style.display="block"}else{$i(prefixo+tipos[i]).style.display="none"}}}},mudaTipo:function(obj,onde){if(obj.value==="janela"){this.formato="janela";this.mostraCoordenadas();return}this.padrao=obj.value;obj.selectedIndex=0;i3GEO.coordenadas.ativaBloco(onde)},mostraCoordenadas:function(ativaMovimento,onde,x,y){try{var tipos=i3GEO.util.listaChaves(i3GEO.coordenadas.config),n=tipos.length,temp,ins="",i=0,caixa,janela,nomeFunc;i3GEO.coordenadas.MODOTEXTO="";if(arguments.length===0){ativaMovimento=true;onde=""}if(onde===""){onde=i3GEO.coordenadas.config[tipos[0]].idhtml}caixa="<select onchange='javascript:i3GEO.coordenadas.mudaTipo(this,\""+onde+"\");' class='i3geoCoordenadasComboTipo' ><option>---</option><option value='janela' >janela</option>";for(i=0;i<n;i+=1){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){caixa+="<option value='"+tipos[i]+"'>"+temp.titulo+"</option>"}}caixa+="</select>";if(i3GEO.coordenadas.formato!=="bloco"){caixa=""}for(i=0;i<n;i+=1){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){if(temp.tipo==="geo"){ins+=i3GEO.coordenadas.criaMascaraDMS(onde+tipos[i],temp.titulo,caixa);if(i3GEO.coordenadas.formato==="separado"){try{$i(temp.idhtml).innerHTML=ins}catch(e){}ins=""}}else{if(temp.tipo==="codigo"){ins+=i3GEO.coordenadas.criaMascaraCodigo(onde+tipos[i],temp.titulo,caixa,temp.tipoCodigo)}else{ins+=i3GEO.coordenadas.criaMascaraMetrica(onde+tipos[i],temp.titulo,caixa)}}}}if(this.formato==="janela"){janela=i3GEO.janela.cria("450px","120px","","","",$trad("x49"),"i3GEOJanelaCoordenadas",false,"hd","","");YAHOO.util.Event.addListener(janela[0].close,"click",function(){i3GEO.coordenadas.formato="bloco",i3GEO.coordenadas.mostraCoordenadas()});temp=$i("i3GEOJanelaCoordenadas_corpo");temp.style.backgroundColor="white";temp.style.textAlign="left";temp=$i("i3GEOJanelaCoordenadas");temp.onmouseover="";temp.onmouseout="";if($i(onde)){$i(onde).innerHTML=""}onde="i3GEOJanelaCoordenadas_corpo";ins+="<br><a href='#' style='cursor:pointer;color:blue' onclick='new YAHOO.util.KeyListener(document.body,{alt:true,keys:67},{fn: function(type, args, obj){i3GEO.janela.tempoMsg(i3GEO.coordenadas.MODOTEXTO);}}).enable();' >"+"Clique aqui para ativar Alt+C para poder capturar as coordenadas</a>"}if(onde!==""&&$i(onde)){$i(onde).innerHTML=ins}for(i=0;i<n;i+=1){temp=i3GEO.coordenadas.config[tipos[i]];if(temp.ativo===true){if(temp.tipo==="geo"){if(ativaMovimento===true){if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",["i3GEO.coordenadas.atualizaLocalizarGeo('"+onde+tipos[i]+"')"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",["i3GEO.coordenadas.atualizaLocalizarGeo('"+onde+tipos[i]+"')"])}}if(typeof(x)!=='undefined'){i3GEO.coordenadas.atualizaLocalizarGeo(onde+tipos[i],i3GEO.calculo.dd2dms(x)[0],i3GEO.calculo.dd2dms(y)[0])}}else{nomeFunc="i3GEO.coordenadas.atualizaProj4";if(temp.tipo==="codigo"){nomeFunc="i3GEO.coordenadas.atualizaCodigo"}if(ativaMovimento===true){if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",[nomeFunc+"('"+onde+"','"+tipos[i]+"')"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",[nomeFunc+"('"+onde+"','"+tipos[i]+"')"])}}if(typeof(x)!=='undefined'){eval(nomeFunc+"(onde,tipos[i],x,y);")}}}}if(ativaMovimento===true){if(i3GEO.Interface.TABLET===true){i3GEO.eventos.adicionaEventos("MOUSECLIQUE",["i3GEO.coordenadas.limpaModoTexto()"])}else{i3GEO.eventos.adicionaEventos("MOUSEMOVE",["i3GEO.coordenadas.limpaModoTexto()"])}}if(i3GEO.coordenadas.formato==="bloco"){i3GEO.coordenadas.ativaBloco(onde)}}catch(men){}},limpaModoTexto:function(){i3GEO.coordenadas.MODOTEXTO=""},geohash:{BITS:[16,8,4,2,1],BASE32:"0123456789bcdefghjkmnpqrstuvwxyz",refine_interval:function(interval,cd,mask){if(cd&mask)interval[0]=(interval[0]+interval[1])/2;else interval[1]=(interval[0]+interval[1])/2},decodeGeoHash:function(geohash){var is_even=1,lat=[],lon=[],i,j,x,y;lat[0]=-90.0;lat[1]=90.0;lon[0]=-180.0;lon[1]=180.0;lat_err=90.0;lon_err=180.0;for(i=0;i<geohash.length;i++){c=geohash[i];cd=i3GEO.coordenadas.geohash.BASE32.indexOf(c);for(j=0;j<5;j++){mask=i3GEO.coordenadas.geohash.BITS[j];if(is_even){lon_err/=2;i3GEO.coordenadas.geohash.refine_interval(lon,cd,mask)}else{lat_err/=2;i3GEO.coordenadas.geohash.refine_interval(lat,cd,mask)}is_even=!is_even}}lat[2]=(lat[0]+lat[1])/2;lon[2]=(lon[0]+lon[1])/2;y=(lat[0]+lat[1])/2;x=(lon[0]+lon[1])/2;return{latitude:y,longitude:x}},encodeGeoHash:function(latitude,longitude){var is_even=1,lat=[],lon=[],bit=0,ch=0,precision=12,geohash="";lat[0]=-90.0;lat[1]=90.0;lon[0]=-180.0;lon[1]=180.0;while(geohash.length<precision){if(is_even){mid=(lon[0]+lon[1])/2;if(longitude>mid){ch|=i3GEO.coordenadas.geohash.BITS[bit];lon[0]=mid}else lon[1]=mid}else{mid=(lat[0]+lat[1])/2;if(latitude>mid){ch|=i3GEO.coordenadas.geohash.BITS[bit];lat[0]=mid}else lat[1]=mid}is_even=!is_even;if(bit<4)bit++;else{geohash+=i3GEO.coordenadas.geohash.BASE32[ch];bit=0;ch=0}}return geohash},zoomCodigo:function(idobj){var codigo;if($i(idobj)){codigo=$i(idobj).value}else{codigo=idobj}codigo=i3GEO.coordenadas.geohash.decodeGeoHash(codigo);i3GEO.navega.zoomponto(i3GEO.configura.locaplic,i3GEO.configura.sid,codigo.longitude,codigo.latitude)}}}; |
274 | // | 274 | // |
275 | //compactados/classe_gadgets_compacto.js | 275 | //compactados/classe_gadgets_compacto.js |
276 | -if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.gadgets={PARAMETROS:{"mostraInserirKml":{idhtml:"inserirKml"},"mostraEscalaNumerica":{idhtml:"escala"},"mostraEscalaGrafica":{idhtml:"escalaGrafica"},"mostraBuscaRapida":{idhtml:"buscaRapida",servicosexternos:true,temasmapa:false,google:true},"mostraVisual":{idhtml:""},"mostraHistoricoZoom":{idhtml:"historicozoom"},"mostraMenuSuspenso":{permiteLogin:true,marcadores:true,idhtml:"menus",deslocaEsquerda:0,parametrosYUI:{iframe:false,autosubmenudisplay:false,showdelay:200,hidedelay:500,lazyload:false}},"mostraMenuLista":{idhtml:"menuLista"},"mostraVersao":{idhtml:"versaoi3geo"},"mostraEmail":{idhtml:"emailInstituicao"}},mostraEmail:function(id){if(arguments.length===0||id===""){id=i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml}else{i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml=id}i3GEO.util.defineValor(id,"innerHTML",i3GEO.parametros.emailInstituicao)},mostraVersao:function(id){if(arguments.length===0||id===""){id=i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml}else{i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml=id}i3GEO.util.defineValor(id,"innerHTML",i3GEO.parametros.mensageminicia)},mostraInserirKml:function(id){var i,ins,temp;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml}if($i(id)){if(!$i("i3geo_urlkml")){i=$inputText(id,"290","i3geo_urlkml","kml url","35","kml");ins="<table><tr><td>"+i;temp='i3GEO.Interface.adicionaKml();';ins+="</td><td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' class='tic' onclick='"+temp+"' /></td></tr></table>";$i(id).innerHTML=ins}}},mostraEscalaNumerica:function(id){var i,ins,temp,onde;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraEscalaNumerica.idhtml}onde=$i(id);if(onde){if(onde.style.display=="none"){onde.style.display="block"}if(!$i("i3geo_escalanum")){i="<form id='i3GEOescalanumForm' >"+$inputText(id,"100","i3geo_escalanum",$trad("d10"),"10",parseInt(i3GEO.parametros.mapscale,10))+"</form>";ins="<table style='width:120px;'><tr><td>"+i;temp='var nova = document.getElementById("i3geo_escalanum").value;';temp+='i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,nova);';ins+="</td></tr></table>";onde.innerHTML=ins;$i("i3GEOescalanumForm").onsubmit=function(){i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,document.getElementById("i3geo_escalanum").value);return false}}i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"])}},atualizaEscalaNumerica:function(escala){var e=$i("i3geo_escalanum");if(!e){i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"]);return}if(arguments.length===1){e.value=escala}else{if(i3GEO.parametros.mapscale!==""){e.value=parseInt(i3GEO.parametros.mapscale,10)}else{e.value=0}}},mostraEscalaGrafica:function(id){if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraEscalaGrafica.idhtml}var ins;if($i(id)){if(!$i("imagemEscalaGrafica")){ins="<img class='menuarrow' src=\""+i3GEO.configura.locaplic+"/imagens/branco.gif\" title='opções' onclick='i3GEO.mapa.dialogo.opcoesEscala()' style='cursor:pointer'/><img id=imagemEscalaGrafica src='' />";$i(id).innerHTML=ins}i3GEO.gadgets.atualizaEscalaGrafica();i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"])}},atualizaEscalaGrafica:function(){var e=$i("imagemEscalaGrafica");if(!e){i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"]);return}temp=function(retorno){eval(retorno.data);$i("imagemEscalaGrafica").src=scaimagem};i3GEO.php.escalagrafica(temp)},mostraBuscaRapida:function(id){var i,ins,temp,fbusca;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.idhtml}i3GEO.gadgets.mostraBuscaRapida.id=id;if($i(id)){i="<form id=i3GEObotaoFormBuscaRapida"+id+" >"+"<div class='i3geoForm' style='width:160px;'><input class=i3geoFormSemIcone type=text value='' id='valorBuscaRapida"+id+"' /></div>"+"</form>";ins="<table><tr><td><a class=ajuda_usuario target=_blank href='"+i3GEO.configura.locaplic+"/ajuda_usuario.php?idcategoria=8&idajuda=71' > </a></td><td>"+i+"</td>";ins+="<td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' title='"+$trad("p13")+"' class='ticPropriedades2' id=i3GEObotaoPropriedadesBuscaRapida"+id+" style='margin-right:5px;margin-left:5px;'/></td>";ins+="<td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' class='ticfind' id=i3GEObotaoBuscaRapida"+id+" /></td></tr></table>";temp=$i(id);if(temp){fbusca=function(){if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google===false&&i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos===false&&i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa===false){i3GEO.janela.tempoMsg($trad("x35"));return}if($i("valorBuscaRapida"+id).value===""){i3GEO.janela.tempoMsg($trad("x36"));return}i3GEO.janela.cria("300px","280px",i3GEO.configura.locaplic+"/ferramentas/buscarapida/index.htm","","",$trad("o2"));return false};temp.innerHTML=ins;$i("i3GEObotaoBuscaRapida"+id).onclick=fbusca;$i("i3GEObotaoFormBuscaRapida"+id).onsubmit=fbusca;$i("i3GEObotaoPropriedadesBuscaRapida"+id).onclick=function(){var ins,interno="",externo="",google="";i3GEO.janela.cria("300px","150px","","","",$trad("s5"),"i3GEOpropriedadesBuscaRapida"+id);if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos){externo="checked"}if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa){interno="checked"}ins="<p class=paragrafo >"+$trad("x37")+":</p>"+"<table class=lista3 >"+"<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos = this.checked' type=checkbox "+externo+" ></td><td> "+$trad("x38")+"</td></tr>"+"<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa = this.checked' type=checkbox "+interno+" ></td><td>"+$trad("x39")+"</td></tr>";if(i3GEO.Interface.ATUAL==="googlemaps"){if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google){google="checked"}ins+="<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google = this.checked' type=checkbox "+google+" ></td><td>Google</td></tr>"}else{i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google=false}ins+="</table><br>"+"<p class=paragrafo >"+$trad("x40")+"</p>";$i("i3GEOpropriedadesBuscaRapida"+id+"_corpo").innerHTML=ins}}}},mostraHistoricoZoom:function(id){if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraHistoricoZoom.idhtml}if($i(id)){marcadorZoom="";var ins="<table style='text-align:center;position:relative;left:";if(navm){ins+="0px;'>"}else{ins+="6px;'>"}ins+="<tr><td><img id='i3geo_zoomanterior' class='zoomAnterior' title='anterior' src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' /></td>";ins+="<td> </td>";ins+="<td><img id='i3geo_zoomproximo' class='zoomProximo' title='proximo' src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' /></td>";ins+="</tr></table>";$i(id).innerHTML=ins}},visual:{inicia:function(id){alert("A i3GEO.gadgets.visual foi depreciado")},troca:function(visual){alert("A i3GEO.gadgets.visual foi depreciado")}},mostraMenuSuspenso:function(id){var objid,n,i,estilo,t,onMenuBarBeforeRender,temp,i3GEOoMenuBarLocal,ms=i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso,confm=i3GEO.configura.oMenuData,ins="",alinhamento="";if(arguments.length===0){id=ms.idhtml}else{ms.idhtml=id}objid=$i(id);if(!objid){return}if(i3GEO.util.trim(objid.innerHTML)===""){try{if(ms.marcadores===true){i3GEO.configura.oMenuData=i3GEO.marcador.adicionaMenuSuspenso(i3GEO.configura.oMenuData)}}catch(e){}try{if(ms.permiteLogin===true||(ms.permiteLogin!=false&&i3GEO.parametros.editor==="sim")){i3GEO.configura.oMenuData=i3GEO.login.adicionaMenuSuspenso(i3GEO.configura.oMenuData)}}catch(e){}i3GEOoMenuBar=YAHOO.widget.MenuManager;if(objid){objid.className="yuimenubar";temp=$i("contemMenu");if(temp){temp.className="yui-navset"}if(ms.deslocaEsquerda){alinhamento="left:"+ms.deslocaEsquerda*-1+"px;"}if(temp&&(!temp.style.height||parseInt(temp.style.height)===0)){temp.style.height="30px"}if(objid.style.height&&parseInt(objid.style.height,10)===0){objid.style.height="0px"}ins+='<div class="bd" style="top:0px;'+alinhamento+'display:block;align:right;border: 0px solid white;z-index:3;line-height:1.4" >'+'<ul class="first-of-type" style="display:block;border:0px solid white;top:10px;">';n=confm.menu.length;estilo="padding-bottom:3px;top:0px;border: 0px solid white;";for(i=0;i<n;i+=1){t="";if(confm.menu[i].target){t="target="+confm.menu[i].target}if(confm.submenus[confm.menu[i].id].length>0){ins+='<li class="yuimenubaritem" style="padding-top:2px;"><a style="'+estilo+'" href="#" class="yuimenubaritemlabel" '+t+'id="menu'+confm.menu[i].id+'" > '+confm.menu[i].nome+'</a></li>'}}ins+='</ul>';ins+='</div>';objid.innerHTML=ins;if(i3GEO.Interface.ATUAL==="googleearth"){i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI.iframe=true}i3GEOoMenuBarLocal=new YAHOO.widget.MenuBar(id,i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI);onMenuBarBeforeRender=function(p_sType,p_sArgs){var nomeMenu="",nomeSub,subs=i3GEO.configura.oMenuData.submenus,conta=0;for(nomeMenu in subs){if($i("menu"+nomeMenu)){nomeSub=subs[nomeMenu];if(nomeSub!==""){i3GEOoMenuBarLocal.getItem(conta).cfg.setProperty('submenu',{id:nomeMenu,itemdata:nomeSub})}conta+=1}}};temp=$i("contemMenu");if(temp){i3GEOoMenuBarLocal.subscribe("beforeShow",function(){$i("contemMenu").style.zIndex=5000;return},i3GEO.configura.oMenuData.submenus);i3GEOoMenuBarLocal.subscribe("beforeHide",function(){$i("contemMenu").style.zIndex=1;return},i3GEO.configura.oMenuData.submenus)}i3GEOoMenuBar.addMenu(i3GEOoMenuBarLocal);i3GEOoMenuBarLocal.beforeRenderEvent.subscribe(onMenuBarBeforeRender);i3GEOoMenuBarLocal.render()}}temp=["omenudataInterface1","omenudataInterface2","omenudataInterface3","omenudataInterface4","omenudataInterface5"];n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("checked",false)}}try{temp="";switch(i3GEO.Interface.ATUAL){case"openlayers":temp="omenudataInterface2";break;case"googlemaps":temp="omenudataInterface4";break;case"googleearth":temp="omenudataInterface5";break}if(temp!=""&&$i(temp)){i3GEOoMenuBar.getMenuItem(temp).cfg.setProperty("checked",true)}}catch(e){}temp=["omenudataFerramentas7b","omenudataArquivos3","omenudataJanelas1","omenudataJanelas3","omenudataFerramentas2a"];n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("disabled",false)}}try{temp=[];switch(i3GEO.Interface.ATUAL){case"openlayers":temp=["omenudataArquivos3","omenudataJanelas1"];break;case"googlemaps":temp=["omenudataArquivos3","omenudataJanelas1","omenudataJanelas3"];break;case"googleearth":temp=["omenudataFerramentas7b","omenudataArquivos3","omenudataJanelas3","omenudataFerramentas2a"];break};n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("disabled",true)}}}catch(e){}temp=objid.style;temp.backgroundPosition="0px -1px";temp.border="0px solid white";if(ms.finaliza&&ms.finaliza!=""){eval(ms.finaliza)}},mostraMenuLista:function(id){var objid,n,i,sub,nomeMenu="",ms=i3GEO.gadgets.PARAMETROS.mostraMenuLista,confm=i3GEO.configura.oMenuData,ins="",subs=i3GEO.configura.oMenuData.submenus;if(arguments.length===0){id=ms.idhtml}else{ms.idhtml=id}objid=$i(id);if(objid){n=confm.menu.length;for(i=0;i<n;i+=1){ins+='<div class="listaMenuTitulo" id=menulista_'+confm.menu[i].id+'>'+confm.menu[i].nome+'</div>'}objid.innerHTML=ins;for(nomeMenu in subs){if($i("menulista_"+nomeMenu)){sub=subs[nomeMenu];n=sub.length;ins="";for(i=0;i<n;i++){ins+="<p class='listaMenuItem' ><a href='"+sub[i].url+"' target='_self'>"+sub[i].text+"</a>"}$i("menulista_"+nomeMenu).innerHTML+=ins}}}}}; | 276 | +if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.gadgets={PARAMETROS:{"mostraInserirKml":{idhtml:"inserirKml"},"mostraEscalaNumerica":{idhtml:"escala"},"mostraEscalaGrafica":{idhtml:"escalaGrafica"},"mostraBuscaRapida":{idhtml:"buscaRapida",servicosexternos:true,temasmapa:false,google:true},"mostraVisual":{idhtml:""},"mostraHistoricoZoom":{idhtml:"historicozoom"},"mostraMenuSuspenso":{permiteLogin:true,marcadores:true,idhtml:"menus",deslocaEsquerda:0,parametrosYUI:{iframe:false,autosubmenudisplay:false,showdelay:200,hidedelay:500,lazyload:false}},"mostraMenuLista":{idhtml:"menuLista"},"mostraVersao":{idhtml:"versaoi3geo"},"mostraEmail":{idhtml:"emailInstituicao"}},mostraEmail:function(id){if(arguments.length===0||id===""){id=i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml}else{i3GEO.gadgets.PARAMETROS.mostraEmail.idhtml=id}i3GEO.util.defineValor(id,"innerHTML",i3GEO.parametros.emailInstituicao)},mostraVersao:function(id){if(arguments.length===0||id===""){id=i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml}else{i3GEO.gadgets.PARAMETROS.mostraVersao.idhtml=id}i3GEO.util.defineValor(id,"innerHTML",i3GEO.parametros.mensageminicia)},mostraInserirKml:function(id){var i,ins,temp;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraInserirKml.idhtml}if($i(id)){if(!$i("i3geo_urlkml")){i=$inputText(id,"290","i3geo_urlkml","kml url","35","kml");ins="<table><tr><td>"+i;temp='i3GEO.Interface.adicionaKml();';ins+="</td><td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' class='tic' onclick='"+temp+"' /></td></tr></table>";$i(id).innerHTML=ins}}},mostraEscalaNumerica:function(id){var i,ins,temp,onde;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraEscalaNumerica.idhtml}onde=$i(id);if(onde){if(onde.style.display=="none"){onde.style.display="block"}if(!$i("i3geo_escalanum")){i="<form id='i3GEOescalanumForm' >"+$inputText(id,"100","i3geo_escalanum",$trad("d10"),"10",parseInt(i3GEO.parametros.mapscale,10))+"</form>";ins="<table style='width:120px;'><tr><td>"+i;temp='var nova = document.getElementById("i3geo_escalanum").value;';temp+='i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,nova);';ins+="</td></tr></table>";onde.innerHTML=ins;$i("i3GEOescalanumForm").onsubmit=function(){i3GEO.navega.aplicaEscala(i3GEO.configura.locaplic,i3GEO.configura.sid,document.getElementById("i3geo_escalanum").value);return false}}i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"])}},atualizaEscalaNumerica:function(escala){var e=$i("i3geo_escalanum");if(!e){i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaNumerica()"]);return}if(arguments.length===1){e.value=escala}else{if(i3GEO.parametros.mapscale!==""){e.value=parseInt(i3GEO.parametros.mapscale,10)}else{e.value=0}}},mostraEscalaGrafica:function(id){if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraEscalaGrafica.idhtml}var ins;if($i(id)){if(!$i("imagemEscalaGrafica")){ins="<img class='menuarrow' src=\""+i3GEO.configura.locaplic+"/imagens/branco.gif\" title='opções' onclick='i3GEO.mapa.dialogo.opcoesEscala()' style='cursor:pointer'/><img id=imagemEscalaGrafica src='' />";$i(id).innerHTML=ins}i3GEO.gadgets.atualizaEscalaGrafica();i3GEO.eventos.adicionaEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"])}},atualizaEscalaGrafica:function(){var e=$i("imagemEscalaGrafica");if(!e){i3GEO.eventos.removeEventos("NAVEGAMAPA",["i3GEO.gadgets.atualizaEscalaGrafica()"]);return}temp=function(retorno){eval(retorno.data);$i("imagemEscalaGrafica").src=scaimagem};i3GEO.php.escalagrafica(temp)},mostraBuscaRapida:function(id){var i,ins,temp,fbusca;if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.idhtml}i3GEO.gadgets.mostraBuscaRapida.id=id;if($i(id)){i="<form id=i3GEObotaoFormBuscaRapida"+id+" >"+"<div class='i3geoForm' style='width:160px;'><input class=i3geoFormSemIcone type=text value='' id='valorBuscaRapida"+id+"' /></div>"+"</form>";ins="<table><tr><td><a class=ajuda_usuario target=_blank href='"+i3GEO.configura.locaplic+"/ajuda_usuario.php?idcategoria=8&idajuda=71' ><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif' /></a></td>"+"<td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' title='"+$trad("p13")+"' class='ticPropriedades2' id=i3GEObotaoPropriedadesBuscaRapida"+id+" style='margin-right:5px;margin-left:5px;'/></td>"+"<td>"+i+"</td>"+"<td><img src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' class='ticfind' id=i3GEObotaoBuscaRapida"+id+" style='margin-left:3px;' /></td></tr></table>";temp=$i(id);if(temp){fbusca=function(){if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google===false&&i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos===false&&i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa===false){i3GEO.janela.tempoMsg($trad("x35"));return}if($i("valorBuscaRapida"+id).value===""){i3GEO.janela.tempoMsg($trad("x36"));return}i3GEO.janela.cria("300px","280px",i3GEO.configura.locaplic+"/ferramentas/buscarapida/index.htm","","",$trad("o2"));return false};temp.innerHTML=ins;$i("i3GEObotaoBuscaRapida"+id).onclick=fbusca;$i("i3GEObotaoFormBuscaRapida"+id).onsubmit=fbusca;$i("i3GEObotaoPropriedadesBuscaRapida"+id).onclick=function(){var ins,interno="",externo="",google="";i3GEO.janela.cria("300px","150px","","","",$trad("s5"),"i3GEOpropriedadesBuscaRapida"+id);if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos){externo="checked"}if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa){interno="checked"}ins="<p class=paragrafo >"+$trad("x37")+":</p>"+"<table class=lista3 >"+"<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.servicosexternos = this.checked' type=checkbox "+externo+" ></td><td> "+$trad("x38")+"</td></tr>"+"<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.temasmapa = this.checked' type=checkbox "+interno+" ></td><td>"+$trad("x39")+"</td></tr>";if(i3GEO.Interface.ATUAL==="googlemaps"){if(i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google){google="checked"}ins+="<tr><td><input style=cursor:pointer onclick='i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google = this.checked' type=checkbox "+google+" ></td><td>Google</td></tr>"}else{i3GEO.gadgets.PARAMETROS.mostraBuscaRapida.google=false}ins+="</table><br>"+"<p class=paragrafo >"+$trad("x40")+"</p>";$i("i3GEOpropriedadesBuscaRapida"+id+"_corpo").innerHTML=ins}}}},mostraHistoricoZoom:function(id){if(arguments.length===0){id=i3GEO.gadgets.PARAMETROS.mostraHistoricoZoom.idhtml}if($i(id)){marcadorZoom="";var ins="<table style='text-align:center;position:relative;left:";if(navm){ins+="0px;'>"}else{ins+="6px;'>"}ins+="<tr><td><img id='i3geo_zoomanterior' class='zoomAnterior' title='anterior' src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' /></td>";ins+="<td> </td>";ins+="<td><img id='i3geo_zoomproximo' class='zoomProximo' title='proximo' src='"+i3GEO.configura.locaplic+"/imagens/branco.gif"+"' /></td>";ins+="</tr></table>";$i(id).innerHTML=ins}},visual:{inicia:function(id){alert("A i3GEO.gadgets.visual foi depreciado")},troca:function(visual){alert("A i3GEO.gadgets.visual foi depreciado")}},mostraMenuSuspenso:function(id){var objid,n,i,estilo,t,onMenuBarBeforeRender,temp,i3GEOoMenuBarLocal,ms=i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso,confm=i3GEO.configura.oMenuData,ins="",alinhamento="";if(arguments.length===0){id=ms.idhtml}else{ms.idhtml=id}objid=$i(id);if(!objid){return}if(i3GEO.util.trim(objid.innerHTML)===""){try{if(ms.marcadores===true){i3GEO.configura.oMenuData=i3GEO.marcador.adicionaMenuSuspenso(i3GEO.configura.oMenuData)}}catch(e){}try{if(ms.permiteLogin===true||(ms.permiteLogin!=false&&i3GEO.parametros.editor==="sim")){i3GEO.configura.oMenuData=i3GEO.login.adicionaMenuSuspenso(i3GEO.configura.oMenuData)}}catch(e){}i3GEOoMenuBar=YAHOO.widget.MenuManager;if(objid){objid.className="yuimenubar";temp=$i("contemMenu");if(temp){temp.className="yui-navset"}if(ms.deslocaEsquerda){alinhamento="left:"+ms.deslocaEsquerda*-1+"px;"}if(temp&&(!temp.style.height||parseInt(temp.style.height)===0)){temp.style.height="30px"}if(objid.style.height&&parseInt(objid.style.height,10)===0){objid.style.height="0px"}ins+='<div class="bd" style="top:0px;'+alinhamento+'display:block;align:right;border: 0px solid white;z-index:3;line-height:1.4" >'+'<ul class="first-of-type" style="display:block;border:0px solid white;top:10px;">';n=confm.menu.length;estilo="padding-bottom:3px;top:0px;border: 0px solid white;";for(i=0;i<n;i+=1){t="";if(confm.menu[i].target){t="target="+confm.menu[i].target}if(confm.submenus[confm.menu[i].id].length>0){ins+='<li class="yuimenubaritem" style="padding-top:2px;"><a style="'+estilo+'" href="#" class="yuimenubaritemlabel" '+t+'id="menu'+confm.menu[i].id+'" > '+confm.menu[i].nome+'</a></li>'}}ins+='</ul>';ins+='</div>';objid.innerHTML=ins;if(i3GEO.Interface.ATUAL==="googleearth"){i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI.iframe=true}i3GEOoMenuBarLocal=new YAHOO.widget.MenuBar(id,i3GEO.gadgets.PARAMETROS.mostraMenuSuspenso.parametrosYUI);onMenuBarBeforeRender=function(p_sType,p_sArgs){var nomeMenu="",nomeSub,subs=i3GEO.configura.oMenuData.submenus,conta=0;for(nomeMenu in subs){if($i("menu"+nomeMenu)){nomeSub=subs[nomeMenu];if(nomeSub!==""){i3GEOoMenuBarLocal.getItem(conta).cfg.setProperty('submenu',{id:nomeMenu,itemdata:nomeSub})}conta+=1}}};temp=$i("contemMenu");if(temp){i3GEOoMenuBarLocal.subscribe("beforeShow",function(){$i("contemMenu").style.zIndex=5000;return},i3GEO.configura.oMenuData.submenus);i3GEOoMenuBarLocal.subscribe("beforeHide",function(){$i("contemMenu").style.zIndex=1;return},i3GEO.configura.oMenuData.submenus)}i3GEOoMenuBar.addMenu(i3GEOoMenuBarLocal);i3GEOoMenuBarLocal.beforeRenderEvent.subscribe(onMenuBarBeforeRender);i3GEOoMenuBarLocal.render()}}temp=["omenudataInterface1","omenudataInterface2","omenudataInterface3","omenudataInterface4","omenudataInterface5"];n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("checked",false)}}try{temp="";switch(i3GEO.Interface.ATUAL){case"openlayers":temp="omenudataInterface2";break;case"googlemaps":temp="omenudataInterface4";break;case"googleearth":temp="omenudataInterface5";break}if(temp!=""&&$i(temp)){i3GEOoMenuBar.getMenuItem(temp).cfg.setProperty("checked",true)}}catch(e){}temp=["omenudataFerramentas7b","omenudataArquivos3","omenudataJanelas1","omenudataJanelas3","omenudataFerramentas2a"];n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("disabled",false)}}try{temp=[];switch(i3GEO.Interface.ATUAL){case"openlayers":temp=["omenudataArquivos3","omenudataJanelas1"];break;case"googlemaps":temp=["omenudataArquivos3","omenudataJanelas1","omenudataJanelas3"];break;case"googleearth":temp=["omenudataFerramentas7b","omenudataArquivos3","omenudataJanelas3","omenudataFerramentas2a"];break};n=temp.length;while(n>0){n-=1;i=i3GEOoMenuBar.getMenuItem(temp[n]);if(i){i.cfg.setProperty("disabled",true)}}}catch(e){}temp=objid.style;temp.backgroundPosition="0px -1px";temp.border="0px solid white";if(ms.finaliza&&ms.finaliza!=""){eval(ms.finaliza)}},mostraMenuLista:function(id){var objid,n,i,sub,nomeMenu="",ms=i3GEO.gadgets.PARAMETROS.mostraMenuLista,confm=i3GEO.configura.oMenuData,ins="",subs=i3GEO.configura.oMenuData.submenus;if(arguments.length===0){id=ms.idhtml}else{ms.idhtml=id}objid=$i(id);if(objid){n=confm.menu.length;for(i=0;i<n;i+=1){ins+='<div class="listaMenuTitulo" id=menulista_'+confm.menu[i].id+'>'+confm.menu[i].nome+'</div>'}objid.innerHTML=ins;for(nomeMenu in subs){if($i("menulista_"+nomeMenu)){sub=subs[nomeMenu];n=sub.length;ins="";for(i=0;i<n;i++){ins+="<p class='listaMenuItem' ><a href='"+sub[i].url+"' target='_self'>"+sub[i].text+"</a>"}$i("menulista_"+nomeMenu).innerHTML+=ins}}}}}; |
277 | // | 277 | // |
278 | //compactados/classe_social_compacto.js | 278 | //compactados/classe_social_compacto.js |
279 | if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.social={curtirFacebook:function(url,tipo){if(tipo==="comtotal"){return"<iframe src='http://www.facebook.com/plugins/like.php?href="+url+"&layout=button_count&show_faces=false&width=160&action=like&colorscheme=light&height=21' scrolling='no' frameborder='0' style='border:none; overflow:hidden; width:160px; height:21px;' allowTransparency='true'></iframe>"}if(tipo==="semtotal"){return"<iframe src='http://www.facebook.com/plugins/like.php?href="+url+"&layout=button_count&show_faces=false&action=like&colorscheme=light&height=21' scrolling='no' frameborder='0' style='border:none; overflow:hidden; width:100px; height:21px;' allowTransparency='true'></iframe>"}},publicarTwitter:function(url,tipo){var re=new RegExp("=","g");url=url.replace(re,'%3d');if(tipo==="comtotal"){return'<iframe allowtransparency="true" frameborder="0" scrolling="no" src="http://platform.twitter.com/widgets/tweet_button.html?count=horizontal&via=i3geo&url='+url+'" style="width:100px; height:21px;"></iframe>'}if(tipo==="semtotal"){return'<iframe allowtransparency="true" frameborder="0" scrolling="no" src="http://platform.twitter.com/widgets/tweet_button.html?count=none&via=i3geo&url='+url+'" style="width:65px; height:21px;"></iframe>'}},compartilhar:function(id,urlcf,urlpt,tipo,locaplic){if(!locaplic){locaplic=i3GEO.configura.locaplic}if(!tipo){tipo="comtotal"}var onde=$i(id),tabela="";if(tipo==="comtotal"){tabela+="<table style='width:250px' ><tr>"}if(tipo==="semtotal"){tabela+="<table style='width:115px' ><tr>"}if(onde||id===""){if(urlpt!==""){tabela+="<td>"+i3GEO.social.publicarTwitter(urlpt,tipo)+"</td>"}if(urlcf!==""){tabela+="<td>"+i3GEO.social.curtirFacebook(urlcf,tipo)+"</td>"}tabela+="</tr></table>";if(id!==""){onde.innerHTML=tabela}return tabela}else{return false}},bookmark:function(link,locaplic){if(!locaplic){locaplic=i3GEO.configura.locaplic}var ins="<img style='cursor:pointer' src='"+locaplic+"/imagens/delicious.gif' onclick='javascript:window.open(\"http://del.icio.us/post?url="+link+"\")' title='Delicious'/> ";ins+="<img style='cursor:pointer' src='"+locaplic+"/imagens/digg.gif' onclick='javascript:window.open(\"http://digg.com/submit/post?url="+link+"\")' title='Digg'/> ";ins+="<img style='cursor:pointer' src='"+locaplic+"/imagens/facebook.gif' onclick='javascript:window.open(\"http://www.facebook.com/sharer.php?u="+link+"\")' title='Facebook'/> ";ins+="<img style='cursor:pointer' src='"+locaplic+"/imagens/stumbleupon.gif' onclick='javascript:window.open(\"http://www.stumbleupon.com/submit?url="+link+"\")' title='StumbleUpon'/>";return ins}}; | 279 | if(typeof(i3GEO)==='undefined'){var i3GEO={}}i3GEO.social={curtirFacebook:function(url,tipo){if(tipo==="comtotal"){return"<iframe src='http://www.facebook.com/plugins/like.php?href="+url+"&layout=button_count&show_faces=false&width=160&action=like&colorscheme=light&height=21' scrolling='no' frameborder='0' style='border:none; overflow:hidden; width:160px; height:21px;' allowTransparency='true'></iframe>"}if(tipo==="semtotal"){return"<iframe src='http://www.facebook.com/plugins/like.php?href="+url+"&layout=button_count&show_faces=false&action=like&colorscheme=light&height=21' scrolling='no' frameborder='0' style='border:none; overflow:hidden; width:100px; height:21px;' allowTransparency='true'></iframe>"}},publicarTwitter:function(url,tipo){var re=new RegExp("=","g");url=url.replace(re,'%3d');if(tipo==="comtotal"){return'<iframe allowtransparency="true" frameborder="0" scrolling="no" src="http://platform.twitter.com/widgets/tweet_button.html?count=horizontal&via=i3geo&url='+url+'" style="width:100px; height:21px;"></iframe>'}if(tipo==="semtotal"){return'<iframe allowtransparency="true" frameborder="0" scrolling="no" src="http://platform.twitter.com/widgets/tweet_button.html?count=none&via=i3geo&url='+url+'" style="width:65px; height:21px;"></iframe>'}},compartilhar:function(id,urlcf,urlpt,tipo,locaplic){if(!locaplic){locaplic=i3GEO.configura.locaplic}if(!tipo){tipo="comtotal"}var onde=$i(id),tabela="";if(tipo==="comtotal"){tabela+="<table style='width:250px' ><tr>"}if(tipo==="semtotal"){tabela+="<table style='width:115px' ><tr>"}if(onde||id===""){if(urlpt!==""){tabela+="<td>"+i3GEO.social.publicarTwitter(urlpt,tipo)+"</td>"}if(urlcf!==""){tabela+="<td>"+i3GEO.social.curtirFacebook(urlcf,tipo)+"</td>"}tabela+="</tr></table>";if(id!==""){onde.innerHTML=tabela}return tabela}else{return false}},bookmark:function(link,locaplic){if(!locaplic){locaplic=i3GEO.configura.locaplic}var ins="<img style='cursor:pointer' src='"+locaplic+"/imagens/delicious.gif' onclick='javascript:window.open(\"http://del.icio.us/post?url="+link+"\")' title='Delicious'/> ";ins+="<img style='cursor:pointer' src='"+locaplic+"/imagens/digg.gif' onclick='javascript:window.open(\"http://digg.com/submit/post?url="+link+"\")' title='Digg'/> ";ins+="<img style='cursor:pointer' src='"+locaplic+"/imagens/facebook.gif' onclick='javascript:window.open(\"http://www.facebook.com/sharer.php?u="+link+"\")' title='Facebook'/> ";ins+="<img style='cursor:pointer' src='"+locaplic+"/imagens/stumbleupon.gif' onclick='javascript:window.open(\"http://www.stumbleupon.com/submit?url="+link+"\")' title='StumbleUpon'/>";return ins}}; |
css/botoes2.css
@@ -439,7 +439,7 @@ | @@ -439,7 +439,7 @@ | ||
439 | background-image: url("../imagens/ic_zoom.png"); | 439 | background-image: url("../imagens/ic_zoom.png"); |
440 | background-repeat: no-repeat; | 440 | background-repeat: no-repeat; |
441 | cursor: pointer; | 441 | cursor: pointer; |
442 | - width: 16px; | 442 | + width: 14px; |
443 | text-align: center; | 443 | text-align: center; |
444 | } | 444 | } |
445 | .x { | 445 | .x { |
css/i3geo6.css
@@ -1626,7 +1626,7 @@ margin-left: 1px; | @@ -1626,7 +1626,7 @@ margin-left: 1px; | ||
1626 | background-image: url("../imagens/ic_zoom.png"); | 1626 | background-image: url("../imagens/ic_zoom.png"); |
1627 | background-repeat: no-repeat; | 1627 | background-repeat: no-repeat; |
1628 | cursor: pointer; | 1628 | cursor: pointer; |
1629 | -width: 16px; | 1629 | +width: 14px; |
1630 | text-align: center; | 1630 | text-align: center; |
1631 | } | 1631 | } |
1632 | .x { | 1632 | .x { |
css/i3geo6.css.php
@@ -1626,7 +1626,7 @@ margin-left: 1px; | @@ -1626,7 +1626,7 @@ margin-left: 1px; | ||
1626 | background-image: url("../imagens/ic_zoom.png"); | 1626 | background-image: url("../imagens/ic_zoom.png"); |
1627 | background-repeat: no-repeat; | 1627 | background-repeat: no-repeat; |
1628 | cursor: pointer; | 1628 | cursor: pointer; |
1629 | -width: 16px; | 1629 | +width: 14px; |
1630 | text-align: center; | 1630 | text-align: center; |
1631 | } | 1631 | } |
1632 | .x { | 1632 | .x { |