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 | 227 | funcaoAposRedim {function} - (opcional) funcao que será executada para alterar o tamanho da janela |
228 | 228 | |
229 | 229 | dimensionavel {boolean} - (opcional) a janela pode ser redimensionada ou nao pelo usuario |
230 | + | |
231 | + icone {string} | |
230 | 232 | |
231 | 233 | Return: |
232 | 234 | |
233 | 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 | 238 | if(typeof(console) !== 'undefined'){console.info("i3GEO.janela.cria()");} |
237 | 239 | if(!dimensionavel){ |
238 | - dimensionavel == true; | |
240 | + dimensionavel = true; | |
241 | + } | |
242 | + if(!icone){ | |
243 | + icone = ""; | |
239 | 244 | } |
240 | 245 | if($i(id)){ |
241 | 246 | janela = YAHOO.i3GEO.janela.manager.find(id); |
... | ... | @@ -244,45 +249,58 @@ i3GEO.janela = { |
244 | 249 | return; |
245 | 250 | } |
246 | 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 | 255 | //executa as funções default de antes de qualquer criação de janela |
250 | 256 | if(this.ANTESCRIA){ |
251 | 257 | for(i=0;i<this.ANTESCRIA.length;i++) |
252 | 258 | {eval(this.ANTESCRIA[i]);} |
253 | 259 | } |
254 | 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 | 270 | ifr = false; |
262 | 271 | if(i3GEO.Interface && i3GEO.Interface != undefined && i3GEO.Interface.ATUAL === "googleearth"){ |
263 | 272 | i3GEO.janela.TRANSICAOSUAVE = false; |
264 | 273 | ifr = true; |
265 | 274 | } |
266 | 275 | fix = "contained"; |
267 | - if(nx === "" || nx === "center") | |
268 | - {fix = true;} | |
276 | + if(nx === "" || nx === "center"){ | |
277 | + fix = true; | |
278 | + } | |
269 | 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 | 286 | //cria as marcações html para a janela |
275 | 287 | temp = navm ? 0:2; |
276 | 288 | wlargurA = parseInt(wlargura,10)+temp+"px"; |
277 | 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 | 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 | 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 | 304 | ins += '</div>'; |
287 | 305 | ins += '<div class="ft"></div>'; |
288 | 306 | novoel = document.createElement("div"); |
... | ... | @@ -360,10 +378,12 @@ i3GEO.janela = { |
360 | 378 | janela.bringToTop(); |
361 | 379 | |
362 | 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 | 388 | YAHOO.util.Event.addListener($i(id+'_corpo'), "click", YAHOO.util.Event.stopPropagation); |
369 | 389 | //finaliza | ... | ... |
css/corrigeyui_geral.css
... | ... | @@ -189,6 +189,12 @@ td.ygtvcell { |
189 | 189 | min-height: 1em; |
190 | 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 | 199 | .ygtvcontent { |
194 | 200 | font-size: 12px; | ... | ... |
css/geral.css
... | ... | @@ -4,8 +4,13 @@ |
4 | 4 | padding: 5px; |
5 | 5 | margin: 7px; |
6 | 6 | } |
7 | +.i3GeoIconeJanela{ | |
8 | + position:absolute; | |
9 | + left:2px; | |
10 | + top:5px; | |
11 | +} | |
7 | 12 | .i3GeoAguardeJanela{ |
8 | - height: 1px; | |
13 | + height: 2px; | |
9 | 14 | left: 0; |
10 | 15 | position: absolute; |
11 | 16 | top: 29px; |
... | ... | @@ -64,7 +69,7 @@ |
64 | 69 | color:black; |
65 | 70 | } |
66 | 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 | 74 | fieldset |
70 | 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 | 360 | false, |
361 | 361 | "hd", |
362 | 362 | cabecalho, |
363 | - minimiza | |
363 | + minimiza, | |
364 | + "", | |
365 | + true, | |
366 | + i3GEO.configura.locaplic+"/imagens/oxygen/16x16/view-form-table.png" | |
364 | 367 | ); |
365 | 368 | divid = janela[2].id; |
366 | 369 | $i("i3GEOF.tabela_corpo").style.backgroundColor = "white"; | ... | ... |