Commit 0159e31f8d528aab84f6705607f79942d22669b8
1 parent
b309c6ad
Exists in
master
and in
7 other branches
inclusão de opção de seleção por clique na ferramenta linha do tempo
Showing
4 changed files
with
60 additions
and
36 deletions
Show diff stats
classesphp/graficos.php
@@ -514,7 +514,7 @@ function dadosLinhaDoTempo($map_file,$tema) | @@ -514,7 +514,7 @@ function dadosLinhaDoTempo($map_file,$tema) | ||
514 | $eventos[] = array( | 514 | $eventos[] = array( |
515 | 'start'=>$dado[$iteminicio], | 515 | 'start'=>$dado[$iteminicio], |
516 | 'end'=>$fim, | 516 | 'end'=>$fim, |
517 | - 'title'=>"<span onmouseover='tituloover(\"".$dado["centroide"]."\")' onmouseout='tituloout()'>".$titulo."</span>", | 517 | + 'title'=>"<span title='clique para selecionar' onclick='tituloclique(\"".$dado["centroide"]."\")' onmouseover='tituloover(\"".$dado["centroide"]."\")' onmouseout='tituloout()'>".$titulo."</span>", |
518 | 'description'=>$dado[$iteminicio]." ".$fim."<br>".$desc, | 518 | 'description'=>$dado[$iteminicio]." ".$fim."<br>".$desc, |
519 | 'icon'=>$icone, | 519 | 'icon'=>$icone, |
520 | 'image'=>$image, | 520 | 'image'=>$image, |
@@ -525,8 +525,8 @@ function dadosLinhaDoTempo($map_file,$tema) | @@ -525,8 +525,8 @@ function dadosLinhaDoTempo($map_file,$tema) | ||
525 | //echo "<pre>"; | 525 | //echo "<pre>"; |
526 | return array( | 526 | return array( |
527 | "dateTimeFormat"=>$layer->getmetadata("ltempoformatodata"), | 527 | "dateTimeFormat"=>$layer->getmetadata("ltempoformatodata"), |
528 | - "wikiURL"=>"http://simile.mit.edu/shelf/", | ||
529 | - "wikiSection"=>"Simile Cubism Timeline", | 528 | + "wikiURL"=>"", |
529 | + "wikiSection"=>"", | ||
530 | "events"=>$eventos | 530 | "events"=>$eventos |
531 | ); | 531 | ); |
532 | } | 532 | } |
ferramentas/linhadotempo/index.php
@@ -122,34 +122,39 @@ function tituloover(wkt){ | @@ -122,34 +122,39 @@ function tituloover(wkt){ | ||
122 | if(!window.parent.i3GEO.calculo){return;} | 122 | if(!window.parent.i3GEO.calculo){return;} |
123 | } | 123 | } |
124 | catch(e){if(typeof(console) !== 'undefined'){console.error(e);};return;} | 124 | catch(e){if(typeof(console) !== 'undefined'){console.error(e);};return;} |
125 | - var ext = i3GEO.util.wkt2ext(wkt,"point"); | ||
126 | - if(ext == false){alert("wkt invalido");return;} | ||
127 | - var ext = ext.split(" "); | ||
128 | - var xMin = ext[0]; | ||
129 | - var xMax = ext[2]; | ||
130 | - var yMin = ext[1]; | ||
131 | - var yMax = ext[3]; | ||
132 | 125 | ||
133 | - var xyMin = window.parent.i3GEO.calculo.dd2tela(xMin,yMin,window.parent.document.getElementById("img"),window.parent.i3GEO.parametros.mapexten,window.parent.i3GEO.parametros.pixelsize) | ||
134 | - var xyMax = window.parent.i3GEO.calculo.dd2tela(xMax,yMax,window.parent.document.getElementById("img"),window.parent.i3GEO.parametros.mapexten,window.parent.i3GEO.parametros.pixelsize) | 126 | + re = new RegExp("POINT", "g"); |
127 | + wkt = wkt.replace(re,""); | ||
128 | + wkt = wkt.split("(")[1].split(")")[0]; | ||
129 | + wkt = wkt.split(" "); | ||
130 | + | ||
131 | + var xy = window.parent.i3GEO.calculo.dd2tela(wkt[0],wkt[1],window.parent.document.getElementById("img"),window.parent.i3GEO.parametros.mapexten,window.parent.i3GEO.parametros.pixelsize) | ||
135 | 132 | ||
136 | - /* | ||
137 | - window.parent.i3GEO.util.criaBox("boxg"); | ||
138 | - var box = window.parent.$i("boxg"); | ||
139 | - var w = xyMax[0]-xyMin[0]; | ||
140 | - var h = xyMin[1]-xyMax[1]; | ||
141 | - box.style.display = "block"; | ||
142 | - box.style.width = w; | ||
143 | - box.style.height = h; | ||
144 | - box.style.top = xyMax[1]+"px"; | ||
145 | - box.style.left = xyMin[0]+"px"; | ||
146 | - */ | ||
147 | window.parent.i3GEO.util.criaPin('marcaIdentifica',window.parent.i3GEO.configura.locaplic+"/imagens/marker.png","21px","25px"); | 133 | window.parent.i3GEO.util.criaPin('marcaIdentifica',window.parent.i3GEO.configura.locaplic+"/imagens/marker.png","21px","25px"); |
148 | var i = window.parent.document.getElementById('marcaIdentifica') | 134 | var i = window.parent.document.getElementById('marcaIdentifica') |
149 | - i.style.top = xyMax[1]-15+"px"; | ||
150 | - i.style.left = xyMin[0]-2+"px"; | 135 | + i.style.top = xy[1]-25+"px"; |
136 | + i.style.left = xy[0]-10+"px"; | ||
151 | i.style.display = "block" | 137 | i.style.display = "block" |
152 | } | 138 | } |
139 | +function tituloclique(wkt){ | ||
140 | + try{ | ||
141 | + if(!window.parent){return;} | ||
142 | + if(!window.parent.i3GEO){return;} | ||
143 | + if(!window.parent.i3GEO.calculo){return;} | ||
144 | + } | ||
145 | + catch(e){if(typeof(console) !== 'undefined'){console.error(e);};return;} | ||
146 | + re = new RegExp("POINT", "g"); | ||
147 | + wkt = wkt.replace(re,""); | ||
148 | + wkt = wkt.split("(")[1].split(")")[0]; | ||
149 | + wkt = wkt.split(" "); | ||
150 | + var retorna = function(retorno) | ||
151 | + {window.parent.i3GEO.atualiza(retorno);}; | ||
152 | + | ||
153 | + window.parent.i3GEO.janela.abreAguarde("i3GEO.atualiza",$trad("o1")); | ||
154 | + window.parent.i3GEO.php.selecaopt(retorna,$i("tema").value,wkt[0]+" "+wkt[1],"adiciona",0); | ||
155 | + | ||
156 | +} | ||
157 | + | ||
153 | function tituloout(){ | 158 | function tituloout(){ |
154 | window.parent.i3GEO.util.escondePin(); | 159 | window.parent.i3GEO.util.escondePin(); |
155 | } | 160 | } |
menutemas/admin.db
No preview for this file type
pacotes/simile/timeline_2.3.0/timeline_js/timeline-bundle.js
@@ -2466,6 +2466,8 @@ if(C==null||C.length==0){C=this.getText(); | @@ -2466,6 +2466,8 @@ if(C==null||C.length==0){C=this.getText(); | ||
2466 | }if(C==null||C.length==0){return ; | 2466 | }if(C==null||C.length==0){return ; |
2467 | }D.style.display="inline"; | 2467 | }D.style.display="inline"; |
2468 | C=C.replace(/\s/g,"_"); | 2468 | C=C.replace(/\s/g,"_"); |
2469 | +/* | ||
2470 | +modificado por edmar moretti para o i3geo | ||
2469 | var B=this._wikiURL+this._wikiSection.replace(/\s/g,"_")+"/"+C; | 2471 | var B=this._wikiURL+this._wikiSection.replace(/\s/g,"_")+"/"+C; |
2470 | var A=document.createElement("a"); | 2472 | var A=document.createElement("a"); |
2471 | A.href=B; | 2473 | A.href=B; |
@@ -2474,17 +2476,34 @@ A.innerHTML=Timeline.strings[Timeline.clientLocale].wikiLinkLabel; | @@ -2474,17 +2476,34 @@ A.innerHTML=Timeline.strings[Timeline.clientLocale].wikiLinkLabel; | ||
2474 | D.appendChild(document.createTextNode("[")); | 2476 | D.appendChild(document.createTextNode("[")); |
2475 | D.appendChild(A); | 2477 | D.appendChild(A); |
2476 | D.appendChild(document.createTextNode("]")); | 2478 | D.appendChild(document.createTextNode("]")); |
2477 | -},fillTime:function(A,B){if(this._instant){if(this.isImprecise()){A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._start))); | ||
2478 | -A.appendChild(A.ownerDocument.createElement("br")); | ||
2479 | -A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._end))); | ||
2480 | -}else{A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._start))); | ||
2481 | -}}else{if(this.isImprecise()){A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._start)+" ~ "+B.labelPrecise(this._latestStart))); | ||
2482 | -A.appendChild(A.ownerDocument.createElement("br")); | ||
2483 | -A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._earliestEnd)+" ~ "+B.labelPrecise(this._end))); | ||
2484 | -}else{A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._start))); | ||
2485 | -A.appendChild(A.ownerDocument.createElement("br")); | ||
2486 | -A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._end))); | ||
2487 | -}}},fillInfoBubble:function(A,E,M){var K=A.ownerDocument; | 2479 | +*/ |
2480 | +}, | ||
2481 | +fillTime:function(A,B){ | ||
2482 | + /* | ||
2483 | + if(this._instant){ | ||
2484 | + if(this.isImprecise()){ | ||
2485 | + A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._start))); | ||
2486 | + A.appendChild(A.ownerDocument.createElement("br")); | ||
2487 | + A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._end))); | ||
2488 | + } | ||
2489 | + else{ | ||
2490 | + A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._start))); | ||
2491 | + } | ||
2492 | + }else{ | ||
2493 | + if(this.isImprecise()){ | ||
2494 | + A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._start)+" ~ "+B.labelPrecise(this._latestStart))); | ||
2495 | + A.appendChild(A.ownerDocument.createElement("br")); | ||
2496 | + A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._earliestEnd)+" ~ "+B.labelPrecise(this._end))); | ||
2497 | + } | ||
2498 | + else{ | ||
2499 | + A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._start))); | ||
2500 | + A.appendChild(A.ownerDocument.createElement("br")); | ||
2501 | + A.appendChild(A.ownerDocument.createTextNode(B.labelPrecise(this._end))); | ||
2502 | + } | ||
2503 | + } | ||
2504 | + */ | ||
2505 | +}, | ||
2506 | +fillInfoBubble:function(A,E,M){var K=A.ownerDocument; | ||
2488 | var J=this.getText(); | 2507 | var J=this.getText(); |
2489 | var H=this.getLink(); | 2508 | var H=this.getLink(); |
2490 | var B=this.getImage(); | 2509 | var B=this.getImage(); |