Commit 1830c303734e154228f6a52f80b1f4cf59114f76
1 parent
2c3a1ef3
Exists in
master
and in
7 other branches
V6 - nova opção para inclusão de ícone na janela flutuante
Showing
4 changed files
with
63 additions
and
29 deletions
Show diff stats
classesjs/classe_janela.js
@@ -227,15 +227,20 @@ i3GEO.janela = { | @@ -227,15 +227,20 @@ i3GEO.janela = { | ||
227 | funcaoAposRedim {function} - (opcional) funcao que será executada para alterar o tamanho da janela | 227 | funcaoAposRedim {function} - (opcional) funcao que será executada para alterar o tamanho da janela |
228 | 228 | ||
229 | dimensionavel {boolean} - (opcional) a janela pode ser redimensionada ou nao pelo usuario | 229 | dimensionavel {boolean} - (opcional) a janela pode ser redimensionada ou nao pelo usuario |
230 | + | ||
231 | + icone {string} | ||
230 | 232 | ||
231 | Return: | 233 | Return: |
232 | 234 | ||
233 | {Array} Array contendo: objeto YAHOO.panel criado,elemento HTML com o cabecalho, elemento HTML com o corpo | 235 | {Array} Array contendo: objeto YAHOO.panel criado,elemento HTML com o cabecalho, elemento HTML com o corpo |
234 | */ | 236 | */ |
235 | - cria: function(wlargura,waltura,wsrc,nx,ny,texto,id,modal,classe,funcaoCabecalho,funcaoMinimiza, funcaoAposRedim, dimensionavel){ | 237 | + cria: function(wlargura,waltura,wsrc,nx,ny,texto,id,modal,classe,funcaoCabecalho,funcaoMinimiza, funcaoAposRedim, dimensionavel,icone){ |
236 | if(typeof(console) !== 'undefined'){console.info("i3GEO.janela.cria()");} | 238 | if(typeof(console) !== 'undefined'){console.info("i3GEO.janela.cria()");} |
237 | if(!dimensionavel){ | 239 | if(!dimensionavel){ |
238 | - dimensionavel == true; | 240 | + dimensionavel = true; |
241 | + } | ||
242 | + if(!icone){ | ||
243 | + icone = ""; | ||
239 | } | 244 | } |
240 | if($i(id)){ | 245 | if($i(id)){ |
241 | janela = YAHOO.i3GEO.janela.manager.find(id); | 246 | janela = YAHOO.i3GEO.janela.manager.find(id); |
@@ -244,45 +249,58 @@ i3GEO.janela = { | @@ -244,45 +249,58 @@ i3GEO.janela = { | ||
244 | return; | 249 | return; |
245 | } | 250 | } |
246 | var i,wlargurA,ins,novoel,wdocaiframe,temp,fix,underlay,ifr,janela; | 251 | var i,wlargurA,ins,novoel,wdocaiframe,temp,fix,underlay,ifr,janela; |
247 | - if(navm && !chro) | ||
248 | - {this.TRANSICAOSUAVE = false;} | 252 | + if(navm && !chro){ |
253 | + this.TRANSICAOSUAVE = false; | ||
254 | + } | ||
249 | //executa as funções default de antes de qualquer criação de janela | 255 | //executa as funções default de antes de qualquer criação de janela |
250 | if(this.ANTESCRIA){ | 256 | if(this.ANTESCRIA){ |
251 | for(i=0;i<this.ANTESCRIA.length;i++) | 257 | for(i=0;i<this.ANTESCRIA.length;i++) |
252 | {eval(this.ANTESCRIA[i]);} | 258 | {eval(this.ANTESCRIA[i]);} |
253 | } | 259 | } |
254 | //define os parametros default | 260 | //define os parametros default |
255 | - if(!classe || classe == "") | ||
256 | - {classe = "hd";} | ||
257 | - if(!id || id === "") | ||
258 | - {id = "wdoca";} | ||
259 | - if(!modal || modal === "") | ||
260 | - {modal = false;} | 261 | + if(!classe || classe == ""){ |
262 | + classe = "hd"; | ||
263 | + } | ||
264 | + if(!id || id === ""){ | ||
265 | + id = "wdoca"; | ||
266 | + } | ||
267 | + if(!modal || modal === ""){ | ||
268 | + modal = false; | ||
269 | + } | ||
261 | ifr = false; | 270 | ifr = false; |
262 | if(i3GEO.Interface && i3GEO.Interface != undefined && i3GEO.Interface.ATUAL === "googleearth"){ | 271 | if(i3GEO.Interface && i3GEO.Interface != undefined && i3GEO.Interface.ATUAL === "googleearth"){ |
263 | i3GEO.janela.TRANSICAOSUAVE = false; | 272 | i3GEO.janela.TRANSICAOSUAVE = false; |
264 | ifr = true; | 273 | ifr = true; |
265 | } | 274 | } |
266 | fix = "contained"; | 275 | fix = "contained"; |
267 | - if(nx === "" || nx === "center") | ||
268 | - {fix = true;} | 276 | + if(nx === "" || nx === "center"){ |
277 | + fix = true; | ||
278 | + } | ||
269 | //no IE, com CSS3, a sombra não funciona | 279 | //no IE, com CSS3, a sombra não funciona |
270 | - if(modal === true) | ||
271 | - {underlay = "none";} | ||
272 | - else | ||
273 | - {underlay = "shadow";} | 280 | + if(modal === true){ |
281 | + underlay = "none"; | ||
282 | + } | ||
283 | + else{ | ||
284 | + underlay = "shadow"; | ||
285 | + } | ||
274 | //cria as marcações html para a janela | 286 | //cria as marcações html para a janela |
275 | temp = navm ? 0:2; | 287 | temp = navm ? 0:2; |
276 | wlargurA = parseInt(wlargura,10)+temp+"px"; | 288 | wlargurA = parseInt(wlargura,10)+temp+"px"; |
277 | ins = '<div id="'+id+'_cabecalho" class="'+classe+'" >'; | 289 | ins = '<div id="'+id+'_cabecalho" class="'+classe+'" >'; |
278 | - if(i3GEO.configura !== undefined) | ||
279 | - {ins += "<img id='"+id+"_imagemCabecalho' class='i3GeoAguardeJanela' style='visibility:hidden;' src=\'"+i3GEO.configura.locaplic+"/imagens/aguarde2.gif\' />";} | 290 | + if(i3GEO.configura !== undefined){ |
291 | + ins += "<img id='"+id+"_imagemCabecalho' class='i3GeoAguardeJanela' style='visibility:hidden;' src=\'"+i3GEO.configura.locaplic+"/imagens/aguarde2.gif\' />"; | ||
292 | + } | ||
293 | + if(icone != ""){ | ||
294 | + ins += "<img class='i3GeoIconeJanela' src='"+icone+"' >"; | ||
295 | + } | ||
280 | ins += "<span style='font-size:10px;'>"+texto+"</span>"; | 296 | ins += "<span style='font-size:10px;'>"+texto+"</span>"; |
281 | - if(funcaoMinimiza) | ||
282 | - {ins += "<div id='"+id+"_minimizaCabecalho' class='container-minimiza'></div>";} | 297 | + if(funcaoMinimiza){ |
298 | + ins += "<div id='"+id+"_minimizaCabecalho' class='container-minimiza'></div>"; | ||
299 | + } | ||
283 | ins += '</div><div id="'+id+'_corpo" class="bd" style="'+this.ESTILOBD+'">'; | 300 | ins += '</div><div id="'+id+'_corpo" class="bd" style="'+this.ESTILOBD+'">'; |
284 | - if(wsrc !== "") | ||
285 | - {ins += '<iframe name="'+id+'i" id="'+id+'i" valign="top" style="border:0px white solid"></iframe>';} | 301 | + if(wsrc !== ""){ |
302 | + ins += '<iframe name="'+id+'i" id="'+id+'i" valign="top" style="border:0px white solid"></iframe>'; | ||
303 | + } | ||
286 | ins += '</div>'; | 304 | ins += '</div>'; |
287 | ins += '<div class="ft"></div>'; | 305 | ins += '<div class="ft"></div>'; |
288 | novoel = document.createElement("div"); | 306 | novoel = document.createElement("div"); |
@@ -360,10 +378,12 @@ i3GEO.janela = { | @@ -360,10 +378,12 @@ i3GEO.janela = { | ||
360 | janela.bringToTop(); | 378 | janela.bringToTop(); |
361 | 379 | ||
362 | //ajusta estilos e outras características da janela criada | 380 | //ajusta estilos e outras características da janela criada |
363 | - if(navm && id !== "i3geo_janelaMensagens" && i3GEO.Interface && i3GEO.Interface != undefined && i3GEO.Interface.ATUAL === "googleearth") | ||
364 | - {janela.moveTo(0,0);} | ||
365 | - if(ifr === true) | ||
366 | - {janela.iframe.style.zIndex = 4;} | 381 | + if(navm && id !== "i3geo_janelaMensagens" && i3GEO.Interface && i3GEO.Interface != undefined && i3GEO.Interface.ATUAL === "googleearth"){ |
382 | + janela.moveTo(0,0); | ||
383 | + } | ||
384 | + if(ifr === true){ | ||
385 | + janela.iframe.style.zIndex = 4; | ||
386 | + } | ||
367 | 387 | ||
368 | YAHOO.util.Event.addListener($i(id+'_corpo'), "click", YAHOO.util.Event.stopPropagation); | 388 | YAHOO.util.Event.addListener($i(id+'_corpo'), "click", YAHOO.util.Event.stopPropagation); |
369 | //finaliza | 389 | //finaliza |
css/corrigeyui_geral.css
@@ -189,6 +189,12 @@ td.ygtvcell { | @@ -189,6 +189,12 @@ td.ygtvcell { | ||
189 | min-height: 1em; | 189 | min-height: 1em; |
190 | padding: 0 10px; | 190 | padding: 0 10px; |
191 | } | 191 | } |
192 | +.yui-skin-sam .yui-button { | ||
193 | + border-color: #D3D3D3; | ||
194 | +} | ||
195 | +.yui-skin-sam .yui-button .first-child { | ||
196 | + border-color: #D3D3D3; | ||
197 | +} | ||
192 | 198 | ||
193 | .ygtvcontent { | 199 | .ygtvcontent { |
194 | font-size: 12px; | 200 | font-size: 12px; |
css/geral.css
@@ -4,8 +4,13 @@ | @@ -4,8 +4,13 @@ | ||
4 | padding: 5px; | 4 | padding: 5px; |
5 | margin: 7px; | 5 | margin: 7px; |
6 | } | 6 | } |
7 | +.i3GeoIconeJanela{ | ||
8 | + position:absolute; | ||
9 | + left:2px; | ||
10 | + top:5px; | ||
11 | +} | ||
7 | .i3GeoAguardeJanela{ | 12 | .i3GeoAguardeJanela{ |
8 | - height: 1px; | 13 | + height: 2px; |
9 | left: 0; | 14 | left: 0; |
10 | position: absolute; | 15 | position: absolute; |
11 | top: 29px; | 16 | top: 29px; |
@@ -64,7 +69,7 @@ | @@ -64,7 +69,7 @@ | ||
64 | color:black; | 69 | color:black; |
65 | } | 70 | } |
66 | .comboTemasCabecalho{ | 71 | .comboTemasCabecalho{ |
67 | -z-index: 100; position: absolute; left: 0px; top:3px; | 72 | +z-index: 100; position: absolute; left: 22px; top:3px; |
68 | } | 73 | } |
69 | fieldset | 74 | fieldset |
70 | {text-align:left; padding: 10px; border: 0px solid gray; border-radius: 5px 5px 5px 5px; box-shadow: 0 1px 3px gray ; background-color:rgb(250,250,250); margin:15px;} | 75 | {text-align:left; padding: 10px; border: 0px solid gray; border-radius: 5px 5px 5px 5px; box-shadow: 0 1px 3px gray ; background-color:rgb(250,250,250); margin:15px;} |
ferramentas/tabela/index.js
@@ -360,7 +360,10 @@ i3GEOF.tabela = { | @@ -360,7 +360,10 @@ i3GEOF.tabela = { | ||
360 | false, | 360 | false, |
361 | "hd", | 361 | "hd", |
362 | cabecalho, | 362 | cabecalho, |
363 | - minimiza | 363 | + minimiza, |
364 | + "", | ||
365 | + true, | ||
366 | + i3GEO.configura.locaplic+"/imagens/oxygen/16x16/view-form-table.png" | ||
364 | ); | 367 | ); |
365 | divid = janela[2].id; | 368 | divid = janela[2].id; |
366 | $i("i3GEOF.tabela_corpo").style.backgroundColor = "white"; | 369 | $i("i3GEOF.tabela_corpo").style.backgroundColor = "white"; |