diff --git a/admin/admin.db b/admin/admin.db
index 1897aaf..774dfbe 100644
Binary files a/admin/admin.db and b/admin/admin.db differ
diff --git a/classesjs/classe_guias.js b/classesjs/classe_guias.js
index 2010db5..107d5bc 100644
--- a/classesjs/classe_guias.js
+++ b/classesjs/classe_guias.js
@@ -33,183 +33,264 @@ Você deve ter recebido uma cópia da Licença Pública G
GNU junto com este programa; se não, escreva para a
Free Software Foundation, Inc., no endereço
59 Temple Street, Suite 330, Boston, MA 02111-1307 USA.
-*/
-if(typeof(i3GEO) === 'undefined'){
+ */
+if (typeof (i3GEO) === 'undefined') {
var i3GEO = {};
}
i3GEO.guias = {
/*
- Variavel: ATUAL
-
- Guia que está ativa ou que será ativada ao iniciar o mapa
-
- O nome da guia é a definida na variável i3GEO.guias.CONFIGURA
-
- Tipo:
- {string}
-
- Default:
- {"temas"}
- */
- ATUAL: "temas",
+ * Variavel: ATUAL
+ *
+ * Guia que está ativa ou que será ativada ao iniciar o mapa
+ *
+ * O nome da guia é a definida na variável
+ * i3GEO.guias.CONFIGURA
+ *
+ * Tipo: {string}
+ *
+ * Default: {"temas"}
+ */
+ ATUAL : "temas",
/*
- Propriedade: ALTURACORPOGUIAS
-
- Altura em pixels que será aplicado em cada guia
-
- Por default, a altura é calculada automaticamente, mas em alguns casos, pode ser necessário especificar o valor para permitir um melhor ajuste do layout do mapa
-
- Mantenha como 0 para que o cálculo seja automático
-
- Tipo:
- {numeric}
-
- Default: 0
- */
- ALTURACORPOGUIAS: 0,
+ * Propriedade: ALTURACORPOGUIAS
+ *
+ * Altura em pixels que será aplicado em cada guia
+ *
+ * Por default, a altura é calculada automaticamente, mas em alguns
+ * casos, pode ser necessário especificar o valor para permitir um
+ * melhor ajuste do layout do mapa
+ *
+ * Mantenha como 0 para que o cálculo seja automático
+ *
+ * Tipo: {numeric}
+ *
+ * Default: 0
+ */
+ ALTURACORPOGUIAS : 0,
/*
- Propriedade: CONFIGURA
-
- Define os parâmetros de cada guia que será mostrada no mapa, como título, conteúdo, etc.
-
- Você pode modificar o nome de uma guia como no exemplo
-
- i3GEO.guias.CONFIGURA.legenda.titulo = "nome diferente";
-
- Por padrão são definidas as guias legenda, temas, adiciona e mapas (links)
-
- Exemplo
-
- i3GEO.guias.CONFIGURA.legenda = {
- titulo:"Legenda do mapa",
- id:"guia4",
- idconteudo:"guia4obj",//id do elemento HTML que contém o conteúdo da guia
- click: function(){
- i3GEO.guias.mostra("legenda");//mostra a guia
- i3GEO.mapa.legendaHTML.cria("guia4obj");
- }
- }
-
- Tipo:
- {JSON}
- */
- CONFIGURA: {
- "temas":{
- icone:"imagens/gisicons/show-layers.png",
- titulo:$trad("g4a"),
- id:"guia1",
- idconteudo:"guia1obj",
- click:""
+ * Propriedade: CONFIGURA
+ *
+ * Define os parâmetros de cada guia que será mostrada no mapa,
+ * como título, conteúdo, etc.
+ *
+ * Você pode modificar o nome de uma guia como no exemplo
+ *
+ * i3GEO.guias.CONFIGURA.legenda.titulo = "nome diferente";
+ *
+ * Por padrão são definidas as guias legenda, temas, adiciona
+ * e mapas (links)
+ *
+ * Exemplo
+ *
+ * i3GEO.guias.CONFIGURA.legenda = { titulo:"Legenda do mapa", id:"guia4",
+ * idconteudo:"guia4obj",//id do elemento HTML que contém o
+ * conteúdo da guia click: function(){
+ * i3GEO.guias.mostra("legenda");//mostra a guia
+ * i3GEO.mapa.legendaHTML.cria("guia4obj"); } }
+ *
+ * Tipo: {JSON}
+ */
+ CONFIGURA : {
+ "temas" : {
+ icone : "imagens/gisicons/show-layers.png",
+ titulo : $trad("g4a"),
+ id : "guia1",
+ idconteudo : "guia1obj",
+ click : ""
},
- "adiciona":{
- icone:"imagens/gisicons/show-catalog.png",
- titulo:$trad("g1a"),
- id:"guia2",
- idconteudo:"guia2obj",
- click: function(){
+ "adiciona" : {
+ icone : "imagens/gisicons/show-catalog.png",
+ titulo : $trad("g1a"),
+ id : "guia2",
+ idconteudo : "guia2obj",
+ click : function() {
var ondeArvore;
i3GEO.guias.mostra("adiciona");
- if(!$i("arvoreAdicionaTema"))
- {
- try{ondeArvore = objmapa.guiaMenu+"obj";}
- catch(e){ondeArvore = "guia2obj";}
+ if (!$i("arvoreAdicionaTema")) {
+ try {
+ ondeArvore = objmapa.guiaMenu
+ + "obj";
+ } catch (e) {
+ ondeArvore = "guia2obj";
+ }
+ } else {
+ ondeArvore = "arvoreAdicionaTema";
}
- else
- {ondeArvore = "arvoreAdicionaTema";}
- //para efeitos de compatibilidade
- if(document.getElementById("outrasOpcoesAdiciona")){
+ // para efeitos de compatibilidade
+ if (document.getElementById("outrasOpcoesAdiciona")) {
i3GEO.arvoreDeTemas.OPCOESADICIONAIS.idonde = "outrasOpcoesAdiciona";
i3GEO.arvoreDeTemas.OPCOESADICIONAIS.incluiArvore = false;
}
- i3GEO.arvoreDeTemas.cria(i3GEO.configura.sid,i3GEO.configura.locaplic,ondeArvore);
+ i3GEO.arvoreDeTemas.cria(
+ i3GEO.configura.sid,
+ i3GEO.configura.locaplic,
+ ondeArvore);
}
},
- "legenda":{
- icone:"imagens/gisicons/show-legend.png",
- titulo:$trad("g3"),
- id:"guia4",
- idconteudo:"guia4obj",
- click: function(){
+ "legenda" : {
+ icone : "imagens/gisicons/show-legend.png",
+ titulo : $trad("g3"),
+ id : "guia4",
+ idconteudo : "guia4obj",
+ click : function() {
i3GEO.guias.mostra("legenda");
i3GEO.mapa.legendaHTML.cria("guia4obj");
}
},
- "mapas":{
- icone:"imagens/gisicons/show-links.png",
- titulo:"Links",
- id:"guia5",
- idconteudo:"guia5obj",
- mostraLink: function(id,url){
- $i("i3geoMapasLink_"+id).innerHTML = ""+url+" ";
+ "mapas" : {
+ icone : "imagens/gisicons/show-links.png",
+ titulo : "Links",
+ id : "guia5",
+ idconteudo : "guia5obj",
+ mostraLink : function(id, url) {
+ $i("i3geoMapasLink_"
+ + id).innerHTML = ""
+ + url
+ + " ";
},
- click: function(onde){
- if(!onde){
+ click : function(onde) {
+ if (!onde) {
onde = i3GEO.guias.CONFIGURA.mapas.idconteudo;
}
- var pegaMapas = function(retorno){
- var ins,mapa,ig1lt,ig1,nome,lkd,link,temp,combo,urlinterface;
- ins = "
" +
- "
"+$trad("x89")+" ";
+ var pegaMapas = function(retorno) {
+ var ins, mapa, ig1lt, ig1, nome, lkd, link, temp, combo, urlinterface;
+ ins = "
"
+ + "
"
+ + $trad("x89")
+ + " ";
mapa = retorno.data.mapas;
ig1lt = mapa.length;
- ig1=0;
- urlinterface = window.location.origin+window.location.pathname;
- if(ig1lt > 0){
- do{
+ ig1 = 0;
+ urlinterface = window.location.origin
+ + window.location.pathname;
+ if (ig1lt > 0) {
+ do {
temp = mapa[ig1];
nome = temp.NOME;
- if(temp.PUBLICADO){
- if(temp.PUBLICADO.toLowerCase() === "nao")
- {nome = "
"+nome+" ";}
+ if (temp.PUBLICADO) {
+ if (temp.PUBLICADO.toLowerCase() === "nao") {
+ nome = "
"
+ + nome
+ + " ";
+ }
}
lkd = temp.LINK;
- link = i3GEO.configura.locaplic+"/ms_criamapa.php?temasa="+temp.TEMAS+"&layers="+temp.LIGADOS;
- if (temp.EXTENSAO !== "")
- {link += "&mapext="+temp.EXTENSAO;}
- if (temp.OUTROS !== "")
- {link += "&"+temp.OUTROS;}
- if (lkd !== "")
- {link = lkd;}
+ link = i3GEO.configura.locaplic
+ + "/ms_criamapa.php?temasa="
+ + temp.TEMAS
+ + "&layers="
+ + temp.LIGADOS;
+ if (temp.EXTENSAO !== "") {
+ link += "&mapext="
+ + temp.EXTENSAO;
+ }
+ if (temp.OUTROS !== "") {
+ link += "&"
+ + temp.OUTROS;
+ }
+ if (lkd !== "") {
+ link = lkd;
+ }
ins += "
";
- if(temp.IMAGEM && temp.IMAGEM != ""){
- ins += "
";
+ if (temp.IMAGEM
+ && temp.IMAGEM != "") {
+ ins += "
";
}
- //verifica se o mapfile esta salvo no banco diretamente
- if(temp.CONTEMMAPFILE == "nao"){
- ins += "
";
- }
- else{
- //combo de opcoes para abrir os mapas salvos como mapfiles
- //esses links tambem sao colocados em admin/php/xml.php geraRSSmapas
- combo = "
" +
- "" + $trad("x103") + ": " +
- "Como foi salvo " +
- "Com a interface atual " +
- "Openlayers com todos os botoes " +
- "Sem o fundo " +
- "Com booes principais " +
- "Botoes de navegacao " +
- " ";
- ins += "
";
+ // verifica se o mapfile esta salvo no banco
+ // diretamente
+ if (temp.CONTEMMAPFILE == "nao") {
+ ins += "
";
+ } else {
+ // combo de opcoes para abrir os mapas salvos
+ // como mapfiles
+ // esses links tambem sao colocados em
+ // admin/php/xml.php geraRSSmapas
+ combo = "
"
+ + ""
+ + $trad("x103")
+ + ": "
+ + "Como foi salvo "
+ + "Com a interface atual "
+ + "Openlayers com todos os botoes "
+ + "Sem o fundo "
+ + "Com booes principais "
+ + "Botoes de navegacao "
+ + " ";
+ ins += "
";
}
ins += "
";
ig1++;
- }
- while(ig1
";
+ $i(onde).innerHTML = ins
+ + " ";
};
- if($i(i3GEO.guias.CONFIGURA.mapas.idconteudo)){
+ if ($i(i3GEO.guias.CONFIGURA.mapas.idconteudo)) {
$i(i3GEO.guias.CONFIGURA.mapas.idconteudo).innerHTML = "Aguarde...";
}
i3GEO.guias.mostra("mapas");
@@ -218,264 +299,347 @@ i3GEO.guias = {
}
},
/*
- Propriedade: ORDEM
-
- Ordem de inclusão das guias no mapa. Essa opção é mais útil no caso do tipo sanfona, pois nesse caso,
- a primeira guia é sempre a que fica ativa. Se esse par�metro for uma string vazia, a ordem
- utilizada será a ordem existente em i3GEO.guias.CONFIGURA.
-
- Ao ser definida, apenas as guias indicadas no array serão incluídas
-
- Exemplo:
-
- i3GEO.guias.ORDEM = ["temas","adiciona","legenda"];
-
- Tipo:
- {array}
-
- Default:
- {""}
- */
- ORDEM: "",
+ * Propriedade: ORDEM
+ *
+ * Ordem de inclusão das guias no mapa. Essa opção
+ * é mais útil no caso do tipo sanfona, pois nesse caso, a
+ * primeira guia é sempre a que fica ativa. Se esse par�metro for uma
+ * string vazia, a ordem utilizada será a ordem existente em
+ * i3GEO.guias.CONFIGURA.
+ *
+ * Ao ser definida, apenas as guias indicadas no array serão
+ * incluídas
+ *
+ * Exemplo:
+ *
+ * i3GEO.guias.ORDEM = ["temas","adiciona","legenda"];
+ *
+ * Tipo: {array}
+ *
+ * Default: {""}
+ */
+ ORDEM : "",
/*
- Propriedade: TIPO
-
- Tipo de guia
-
- Quando TIPO = "movel", a inicialização da guia é feita em i3GEO.inicia
- Isso é ne cessário pq a guia móvel só pode ser criada após o posicionamento do corpo do mapa
-
- Tipo:
- {string}
-
- Default:
- {"guia"}
-
- Values:
- guia|sanfona|tablet|movel
- */
- TIPO: "guia",
+ * Propriedade: TIPO
+ *
+ * Tipo de guia
+ *
+ * Quando TIPO = "movel", a inicialização da guia é
+ * feita em i3GEO.inicia Isso é ne cessário pq a guia
+ * móvel só pode ser criada após o posicionamento do
+ * corpo do mapa
+ *
+ * Tipo: {string}
+ *
+ * Default: {"guia"}
+ *
+ * Values: guia|sanfona|tablet|movel
+ */
+ TIPO : "guia",
/*
- Propriedade: idguias
-
- ID do elemento DOM, criado pelo YUI, onde serão inseridas as guias
-
- Tipo:
- {String}
-
- Default:
- {"guiasYUI"}
- */
- IDGUIAS: "guiasYUI",
+ * Propriedade: idguias
+ *
+ * ID do elemento DOM, criado pelo YUI, onde serão inseridas as guias
+ *
+ * Tipo: {String}
+ *
+ * Default: {"guiasYUI"}
+ */
+ IDGUIAS : "guiasYUI",
/*
- Function: cria
-
- Cria as guias com base na variável i3GEO.guias.CONFIGURA
-
- As guias podem ser definidas no HTML do mapa, sem necessariamente estarem na variável configura.
- As guias, nesse caso, devem ter como ID "guia'n'", por exemplo id="guia6". Para cada uma dessas guias
- deve haver um DIV com o conteúdo. Esse DIV deve ter como ID "guia'n'obj", por exemplo id="guia6obj".
- No caso de ser utilizado a guia móvel, com i3GEO.guias.TIPO = "movel" , "guia'n" não é necessário, uma vez que são
- utilizados os ícones definidos em i3GEO.guias.CONFIGURA
-
- Parametro:
-
- onde {String} - id do elemento que conterá as guias
- */
- cria: function(onde){
-
- if(typeof(console) !== 'undefined'){console.info("i3GEO.guias.cria()");}
+ * Function: cria
+ *
+ * Cria as guias com base na variável i3GEO.guias.CONFIGURA
+ *
+ * As guias podem ser definidas no HTML do mapa, sem necessariamente estarem
+ * na variável configura. As guias, nesse caso, devem ter como ID
+ * "guia'n'", por exemplo id="guia6". Para cada uma dessas guias deve haver
+ * um DIV com o conteúdo. Esse DIV deve ter como ID "guia'n'obj", por
+ * exemplo id="guia6obj". No caso de ser utilizado a guia móvel, com
+ * i3GEO.guias.TIPO = "movel" , "guia'n" não é
+ * necessário, uma vez que são utilizados os ícones
+ * definidos em i3GEO.guias.CONFIGURA
+ *
+ * Parametro:
+ *
+ * onde {String} - id do elemento que conterá as guias
+ */
+ cria : function(onde) {
+
+ if (typeof (console) !== 'undefined') {
+ console.info("i3GEO.guias.cria()");
+ }
//
- //obtém outras guias que podem existir no mapa
+ // obtém outras guias que podem existir no mapa
//
- var nguiasreal = 0,guiaconteudo,id,guia,g,re,ng,tituloguia,i,ins,altura,temp,
- CONFIGURA = i3GEO.guias.CONFIGURA,
- guias = i3GEO.util.listaChaves(CONFIGURA),
- nguias = guias.length;
+ var nguiasreal = 0, guiaconteudo, id, guia, g, re, ng, tituloguia, i, ins, altura, temp, CONFIGURA = i3GEO.guias.CONFIGURA, guias = i3GEO.util.listaChaves(CONFIGURA), nguias = guias.length;
//
- //no caso de TIPO === "movel", as guias não são construídas de imediato, apenas é criado um objeto
- //com os parâmetros necessários para a criação das guias
+ // no caso de TIPO === "movel", as guias não são
+ // construídas de imediato, apenas é criado um objeto
+ // com os parâmetros necessários para a
+ // criação das guias
//
- if(i3GEO.guias.TIPO === "movel"){
+ if (i3GEO.guias.TIPO === "movel") {
i3GEO.guias.IDGUIAS = "i3GEOguiaMovelConteudo";
- for(ng=0;ng'+i3GEO.guias.CONFIGURA[guias[ng]].titulo+'
';}
+ for (ng = 0; ng < nguias; ng++) {
+ if ($i(i3GEO.guias.CONFIGURA[guias[ng]].id)) {
+ if ($i(i3GEO.guias.CONFIGURA[guias[ng]].idconteudo)) {
+ ins += ''
+ + i3GEO.guias.CONFIGURA[guias[ng]].titulo
+ + '
';
+ }
}
}
- //adiciona uma guia que permite esconder todas as outras guias se for do tipo tablet
+ // adiciona uma guia que permite esconder todas as outras guias
+ // se for do tipo tablet
ins += "";
onde.innerHTML = ins;
}
- if(i3GEO.guias.TIPO === "sanfona"){
- ins = '';
- //verifica a quantidade certa de guias
- if(i3GEO.guias.ORDEM === ""){
- for(ng=0;ng';
+ // verifica a quantidade certa de guias
+ if (i3GEO.guias.ORDEM === "") {
+ for (ng = 0; ng < nguias; ng++) {
+ if ($i(i3GEO.guias.CONFIGURA[guias[ng]].id)) {
nguiasreal++;
}
}
+ } else {
+ nguiasreal = i3GEO.guias.ORDEM.length;
}
- else
- {nguiasreal = i3GEO.guias.ORDEM.length;}
- if(navn)
- {altura = i3GEO.parametros.h - (nguiasreal * 25) - 1;}
- else
- {altura = i3GEO.parametros.h - (nguiasreal * 23) + 1;}
- for(ng=0;ng' +
- ''+i3GEO.guias.CONFIGURA[guias[ng]].titulo+'
' +
- '' +
- ' ';
+ ins += ''
+ + ''
+ + i3GEO.guias.CONFIGURA[guias[ng]].titulo
+ + '
'
+ + ' '
+ + ''
+ + '
'
+ + guiaconteudo
+ + '
';
}
}
}
ins += " ";
onde.innerHTML = ins;
- onde.style.height = altura+"px";
- YAHOO.lutsr.accordion.init(true,5,false,"sanfona"+onde.id,altura);
+ onde.style.height = altura
+ + "px";
+ YAHOO.lutsr.accordion.init(
+ true,
+ 5,
+ false,
+ "sanfona"
+ + onde.id,
+ altura);
i3GEO.guias.ALTURACORPOGUIAS = altura;
}
- for(g=0;g
';
- temp = $i("i3geo") ? $i("i3geo").appendChild(novoel) : document.body.appendChild(novoel);
- janela = new YAHOO.widget.Panel("janelaguias", {width:"270px", fixedcenter: true, constraintoviewport: false, underlay:"none", close:false, visible:true, draggable:true, modal:false,iframe:true } );
+ temp = $i("i3geo") ? $i(
+ "i3geo").appendChild(
+ novoel) : document.body.appendChild(novoel);
+ janela = new YAHOO.widget.Panel("janelaguias", {
+ width : "270px",
+ fixedcenter : true,
+ constraintoviewport : false,
+ underlay : "none",
+ close : false,
+ visible : true,
+ draggable : true,
+ modal : false,
+ iframe : true
+ });
YAHOO.i3GEO.janela.manager.register(janela);
janela.render();
janela.show();
- janela.cfg.setProperty("y", 0);
+ janela.cfg.setProperty(
+ "y",
+ 0);
i = $i(i3GEO.guias.IDGUIAS);
- $i("conteudojanelaguias_corpo").appendChild(i);
- i.style.borderLeft="1px solid black";
- i.style.borderRight="1px solid black";
+ $i(
+ "conteudojanelaguias_corpo").appendChild(
+ i);
+ i.style.borderLeft = "1px solid black";
+ i.style.borderRight = "1px solid black";
guias = i3GEO.util.listaChaves(i3GEO.guias.CONFIGURA);
nguias = guias.length;
- for(g=0;g ";
- //verifica se existe um id na interface
- //se existir, o icone e inserido nesse id
- if(!$i("iconeGuia_"+temp.chaves[i])){
+ * Mostra os ícones que acionam cada guia
+ */
+ mostraIcones : function() {
+ if ($i("i3GEOguiaMovelIcones")
+ && $i("i3GEOguiaMovelIcones").innerHTML != "") {
+ return;
+ }
+ var n = i3GEO.guias.guiaMovel.config.guias.icones.length, i, temp = i3GEO.guias.guiaMovel.config.guias, ins = "", ico;
+ if (i3GEO.guias.ORDEM !== "") {
+ temp.chaves = i3GEO.guias.ORDEM;
+ }
+ for (i = 0; i < n; i++) {
+ if (temp.chaves[i]) {
+ ico = " ";
+ // verifica se existe um id na interface
+ // se existir, o icone e inserido nesse id
+ if (!$i("iconeGuia_"
+ + temp.chaves[i])) {
ins += ico;
- }
- else{
- $i("iconeGuia_"+temp.chaves[i]).innerHTML = ico;
+ } else {
+ $i("iconeGuia_"
+ + temp.chaves[i]).innerHTML = ico;
}
}
}
- if($i("i3GEOguiaMovelIcones")){
+ if ($i("i3GEOguiaMovelIcones")) {
$i("i3GEOguiaMovelIcones").innerHTML = ins;
}
i3GEO.guias.guiaMovel.desativaIcones();
- if(i3GEO.guias.ATUAL != ""){
+ if (i3GEO.guias.ATUAL != "") {
ico = $i(i3GEO.guias.CONFIGURA[i3GEO.guias.ATUAL].id);
- if(ico){
- YAHOO.util.Dom.setStyle(ico, "opacity", 0.9);
+ if (ico) {
+ YAHOO.util.Dom.setStyle(
+ ico,
+ "opacity",
+ 0.9);
ico.parentNode.style.boxShadow = "none";
}
}
},
/*
- Altera a cor do fundo dos ícones, voltando ao original
- */
- desativaIcones:function(){
+ * Altera a cor do fundo dos ícones, voltando ao original
+ */
+ desativaIcones : function() {
var ims, n, i;
ims = $i("i3GEOguiaMovelIcones");
- if(ims){
+ if (ims) {
ims = ims.getElementsByTagName("button");
n = ims.length;
- for(i=0;i 0){
+ for (i = 0; i < n; i++) {
+ if ($i("iconeGuia_"
+ + temp.chaves[i])) {
+ ims = $i(
+ "iconeGuia_"
+ + temp.chaves[i]).getElementsByTagName(
+ "button");
+ if (ims.length > 0) {
ims[0].style.backgroundColor = "white";
ims[0].style.boxShadow = "";
ims[0].style.margin = "0px";
ims[0].style.padding = "0px";
- if(chro === true){
+ if (chro === true) {
ims[0].style.padding = "1.7px";
}
ims[0].style.border = "1px solid gray";
- ims[0].style.borderRight = "2px solid white";
- YAHOO.util.Dom.setStyle(ims[0], "opacity", 0.6);
+ if (i3GEO.guias.guiaMovel.config.posicao[1] === "l"){
+ ims[0].style.borderLeft = "2px solid white";
+ }
+ else{
+ ims[0].style.borderRight = "2px solid white";
+ }
+
+ YAHOO.util.Dom.setStyle(
+ ims[0],
+ "opacity",
+ 0.6);
ims[0].blur();
}
}
}
},
/*
- Ativa o conteúdo de determinada guia
-
- Parametro:
-
- chave {string} - código da guia, definido em i3GEO.guias.CONFIGURA
- */
- ativa: function(chave){
- if(chave === ""){
+ * Ativa o conteúdo de determinada guia
+ *
+ * Parametro:
+ *
+ * chave {string} - código da guia, definido em
+ * i3GEO.guias.CONFIGURA
+ */
+ ativa : function(chave) {
+ if (chave === "") {
i3GEO.guias.guiaMovel.desativaIcones();
return;
}
i3GEO.guias.escondeGuias();
i3GEO.guias.guiaMovel.desativaIcones();
- if(i3GEO.guias.ATUAL === chave && $i("i3GEOguiaMovelMolde").style.display === "block"){
+ if (i3GEO.guias.ATUAL === chave
+ && $i("i3GEOguiaMovelMolde").style.display === "block") {
i3GEO.guias.ATUAL = "";
i3GEO.guias.guiaMovel.abreFecha("fecha");
- }
- else{
+ } else {
i3GEO.guias.ATUAL = chave;
i3GEO.guias.guiaMovel.abreFecha("abre");
- if(i3GEO.guias.CONFIGURA[chave].click){
+ if (i3GEO.guias.CONFIGURA[chave].click) {
i3GEO.guias.CONFIGURA[chave].click.call();
}
i3GEO.guias.mostra(chave);
var ico = $i(i3GEO.guias.CONFIGURA[chave].id);
- if(ico){
+ if (ico) {
ico.parentNode.blur();
- YAHOO.util.Dom.setStyle(ico.parentNode, "opacity", 0.9);
+ YAHOO.util.Dom.setStyle(
+ ico.parentNode,
+ "opacity",
+ 0.9);
ico.parentNode.style.boxShadow = "none";
- //verifica se esta fora do lugar normal e muda a borda
- if($i("iconeGuia_"+chave)){
- ico.parentNode.style.borderRight = "2px solid white";
+ // verifica se esta fora do lugar normal e muda a borda
+ if ($i("iconeGuia_"
+ + chave)) {
+ if (i3GEO.guias.guiaMovel.config.posicao[1] === "l"){
+ ico.parentNode.style.borderLeft = "2px solid white";
+ }
+ else{
+ ico.parentNode.style.borderRight = "2px solid white";
+ }
}
}
}
},
/*
- Reposiciona a guia móvel quando o mapa muda de tamanho
- */
- reposiciona: function(){
+ * Reposiciona a guia móvel quando o mapa muda de tamanho
+ */
+ reposiciona : function() {
var temp = $i("i3GEOguiaMovel").style.top;
- //i3GEO.guias.guiaMovel.config.guias.icones = [];
- //i3GEO.guias.guiaMovel.config.guias.ids = [];
- //i3GEO.guias.guiaMovel.config.guias.idsconteudos = [];
- //i3GEO.guias.guiaMovel.config.guias.titulos = [];
- //i3GEO.guias.guiaMovel.config.guias.chaves = [];
i3GEO.guias.guiaMovel.config.alturaGuiaMovel = 0;
i3GEO.guias.ALTURACORPOGUIAS = 0;
- if($i("i3GEOguiaMovelIcones")){
+ if ($i("i3GEOguiaMovelIcones")) {
$i("i3GEOguiaMovelIcones").style.display = "none";
}
$i("i3GEOguiaMovelConteudo").style.display = "none";
@@ -981,75 +1324,119 @@ i3GEO.guias = {
$i("i3GEOguiaMovel").style.top = temp;
},
/*
- Function: abreFecha
-
- Abre ou fecha a guia móvel
- */
- abreFecha: function(forca){
- var molde = $i("i3GEOguiaMovelMolde"),
- guia = $i("i3GEOguiaMovel"),
- attributes,
- anim,
- anim1,
- temp;
- //para efeitos de compatibilidade caso seja chamado com i3GEO.guias.guiaMovel.abreFecha()
- if(!forca){
- if(molde.style.display === "block"){
+ * Function: abreFecha
+ *
+ * Abre ou fecha a guia móvel
+ */
+ abreFecha : function(forca) {
+ var molde = $i("i3GEOguiaMovelMolde"), guia = $i("i3GEOguiaMovel"), attributes, anim, anim1, anim2, temp;
+ // para efeitos de compatibilidade caso seja chamado com
+ // i3GEO.guias.guiaMovel.abreFecha()
+ if (!forca) {
+ if (molde.style.display === "block") {
forca = "fecha";
- }
- else{
+ } else {
temp = i3GEO.guias.ATUAL;
i3GEO.guias.ATUAL = "";
i3GEO.guias.guiaMovel.ativa(temp);
return;
}
}
- if(forca === "fecha"){//esconde
- if($i("i3GEOguiaMovelIcones")){
+ if (forca === "fecha") {// esconde
+ if ($i("i3GEOguiaMovelIcones")) {
$i("i3GEOguiaMovelIcones").style.display = "none";
}
$i("i3GEOguiaMovelConteudo").style.display = "none";
attributes = {
- left: { to: parseInt(i3GEO.guias.guiaMovel.left,10) },
- id: "i3GEOguiaMovel"
+ left : {
+ to : parseInt(
+ i3GEO.guias.guiaMovel.left,
+ 10)
+ },
+ id : "i3GEOguiaMovel"
};
anim = new YAHOO.util.Anim(guia, attributes, 1, YAHOO.util.Easing.easeNone);
attributes = {
- width: { to: 0 },
- id: "i3GEOguiaMovelMolde"
+ width : {
+ to : 0
+ },
+ id : "i3GEOguiaMovelMolde"
};
anim1 = new YAHOO.util.Anim(molde, attributes, 1, YAHOO.util.Easing.easeNone);
anim.duration = 0.5;
anim1.duration = 0.5;
- anim.animate();
- anim1.animate();
- anim1.onComplete.subscribe(function(){
+ anim1.onComplete.subscribe(function() {
molde.style.display = "none";
});
- }
- else if(molde.style.display != "block"){
- //conteudo.style.display = "block";
- molde.style.display = "block";
- attributes = {
- left: { to: parseInt(guia.style.left,10) - i3GEO.guias.guiaMovel.config.larguraGuiaMovel },
- id: "i3GEOguiaMovel"
- };
+ if (i3GEO.guias.guiaMovel.config.posicao[1] === "l"
+ && $i("i3GEOguiaMovelIconesPuxador")) {
+ attributes = {
+ left : {
+ to : 0
+ }
+ };
+ anim2 = new YAHOO.util.Anim("i3GEOguiaMovelIconesPuxador", attributes, 1, YAHOO.util.Easing.easeNone);
+ anim2.duration = 0.5;
+ anim2.animate();
+ }
+ anim.animate();
+ anim1.animate();
+
+ } else if (molde.style.display != "block") {
+ molde.style.display = "block";
+ if (i3GEO.guias.guiaMovel.config.posicao[1] === "l") {
+ attributes = {
+ rigth : {
+ to : (parseInt(
+ guia.style.left,
+ 10) - i3GEO.guias.guiaMovel.config.larguraGuiaMovel)
+ * -1
+ },
+ id : "i3GEOguiaMovel"
+ };
+ } else {
+ attributes = {
+ left : {
+ to : parseInt(
+ guia.style.left,
+ 10)
+ - i3GEO.guias.guiaMovel.config.larguraGuiaMovel
+ },
+ id : "i3GEOguiaMovel"
+ };
+ }
anim = new YAHOO.util.Anim(guia, attributes, 1, YAHOO.util.Easing.easeNone);
attributes = {
- width: { to: i3GEO.guias.guiaMovel.config.larguraGuiaMovel },
- id: "i3GEOguiaMovelMolde"
+ width : {
+ to : i3GEO.guias.guiaMovel.config.larguraGuiaMovel
+ },
+ id : "i3GEOguiaMovelMolde"
};
anim1 = new YAHOO.util.Anim(molde, attributes, 1, YAHOO.util.Easing.easeNone);
anim.duration = 0.5;
anim1.duration = 0.5;
- anim1.onComplete.subscribe(function(){
- if($i("i3GEOguiaMovelIcones")){
+ anim1.onComplete.subscribe(function() {
+ if ($i("i3GEOguiaMovelIcones")) {
$i("i3GEOguiaMovelIcones").style.display = "block";
}
$i("i3GEOguiaMovelConteudo").style.display = "block";
- //i3GEO.guias.guiaMovel.mostraIcones();
- YAHOO.util.Dom.setStyle("i3GEOguiaMovelMolde", "opacity", 0.9);
+ // i3GEO.guias.guiaMovel.mostraIcones();
+ YAHOO.util.Dom.setStyle(
+ "i3GEOguiaMovelMolde",
+ "opacity",
+ 0.9);
});
+ if (i3GEO.guias.guiaMovel.config.posicao[1] === "l"
+ && $i("i3GEOguiaMovelIconesPuxador")) {
+ attributes = {
+ left : {
+ to : i3GEO.guias.guiaMovel.config.larguraGuiaMovel
+ }
+ };
+ anim2 = new YAHOO.util.Anim("i3GEOguiaMovelIconesPuxador", attributes, 1, YAHOO.util.Easing.easeNone);
+ anim2.duration = 0.5;
+ anim2.animate();
+ }
anim.animate();
anim1.animate();
}
diff --git a/exemplos/guiaesquerda.htm b/exemplos/guiaesquerda.htm
new file mode 100644
index 0000000..64b016e
--- /dev/null
+++ b/exemplos/guiaesquerda.htm
@@ -0,0 +1,281 @@
+
+
+
+
+
+i3GEO - OpenLayers
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ i3Geo - Software livre para criação de mapas interativos e geoprocessamento
+ Baseado no Mapserver, é licenciado sob GPL e integra o Portal do Software Público Brasileiro
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Aguarde...
+
+
+
+
+
+
+
+
+
diff --git a/imagens/openbars2.png b/imagens/openbars2.png
new file mode 100755
index 0000000..c8ffc05
Binary files /dev/null and b/imagens/openbars2.png differ
--
libgit2 0.21.2