Commit 7dcc3f5f77c0d87ac65cfe46f06ee0eb5e91b3c8

Authored by Edmar Moretti
1 parent 00a252f7

--no commit message

Showing 1 changed file with 12 additions and 6 deletions   Show diff stats
classesjs/classe_ajuda.js
... ... @@ -150,9 +150,10 @@ i3GEO.ajuda = {
150 150 abreJanela: function(){
151 151 if(typeof(console) !== 'undefined'){console.info("i3GEO.ajuda.abreJanela()");}
152 152 try {
153   - var nx,ny,pos,corpo,texto,janela,temp,
  153 + var nx,ny,corpo,texto,janela,temp,
154 154 largura=262,
155   - YU = YAHOO.util;
  155 + YU = YAHOO.util,
  156 + pos = [20,i3GEO.parametros.h / 2];
156 157 if(this.ATIVAJANELA === false){return;}
157 158 temp = $i("contemFerramentas");
158 159 if(temp){
... ... @@ -160,16 +161,21 @@ i3GEO.ajuda = {
160 161 }
161 162 if(!$i("janelaMenTexto")){
162 163 corpo = $i(i3GEO.Interface.IDCORPO);
163   - if(corpo){
164   - pos = YU.Dom.getXY(corpo);
165   - nx = pos[0] - largura - 3;
166   - ny = i3GEO.parametros.h - 78;
  164 + if(corpo){pos = YU.Dom.getXY(corpo);}
  165 + else{
  166 + corpo = $i(i3GEO.Interface.IDMAPA);
  167 + if(corpo){pos = YU.Dom.getXY(corpo);}
167 168 }
  169 + nx = pos[0] - largura - 3;
  170 + ny = i3GEO.parametros.h - 78;
168 171 texto = '<div id="janelaMenTexto" style="text-align:left;font-size:10px;color:rgb(80,80,80)">'+i3GEO.ajuda.MENSAGEMPADRAO+'</div>';
  172 + if(nx < 0)
  173 + {nx = 10;ny = ny - 50;}
169 174 janela = i3GEO.janela.cria(largura - 3,"auto","",nx,ny,"&nbsp;","i3geo_janelaMensagens",false,"hd","","",true);
170 175 janela[2].innerHTML = texto;
171 176 YU.Event.addListener(janela[0].close, "click", i3GEO.ajuda.fechaJanela);
172 177 this.ativaCookie();
  178 +
173 179 }
174 180 }
175 181 catch(e){
... ...