1// Adrien 10/05/23 : Attention, ce fichier n'est plus utilisé sur la majorité des sites web excepté sur le compte client et le script de résa 2 3function initAllCalendrierItea(){ 4 5 $$("div.calendrierITEANbMois").each(function(objCal){ 6 objCal.hide(); 7 var btPrec=objCal.select("span.calendrierITEA_navig_previous").first(); 8 var btSuiv=objCal.select("span.calendrierITEA_navig_next").first(); 9 var nbMois=objCal.getAttribute("nbMois"); 10 var div1mois=objCal.select("div.calendrierITEA1Mois").first(); 11 var objUl=objCal.select("ul.calendrierITEA_list").first(); 12 13 if (objUl){ 14 objUl.style.position="absolute"; 15 objUl.style.width="50000px"; 16 objCal.style.overflow="hidden"; 17 setScrollHorizontalOnDiv(objCal,objUl,{"nextButton":btSuiv,"prevButton":btPrec,"nbLiDecal":nbMois}); 18 } 19 objCal.show(); 20 }); 21} 22 23 24 25function setScrollHorizontalOnDiv(idDiv,idUl,params){ 26 if (!$(params.nextButton) || !$(params.prevButton)){return false;} 27 var btSuiv=$(params.nextButton); 28 var btPrec=$(params.prevButton); 29 var decal; 30 31 if (!params.noResizeToLi){ 32 if ($(idDiv) && $(idUl) && $(idUl).firstChild){ 33 $(idDiv).style.width=$(idUl).firstChild.offsetWidth+'px'; 34 $(idUl).style.padding='0px'; 35 } 36 } 37 //console.trace('effects.js on setScrollHorizontalOnDiv'); 38 btPrec.style.visibility="hidden"; 39 if (btSuiv){ 40 btSuiv.onclick=function (evt){ 41 if (params.decalage){ 42 decal=params.decalage; 43 } else if (params.nbLiDecal){ 44 var unLi=idUl.childNodes[1].offsetLeft; 45 decal=unLi*params.nbLiDecal; 46 } else { 47 decal=$(idDiv).getWidth(); 48 } 49 var posXLastChild=$(idUl).childElements().last().positionedOffset(idUl).left; 50 var posX0=$(idUl).positionedOffset(idDiv).left; 51 var posX1=posXLastChild+$(idUl).childElements().last().getWidth()+posX0; 52 var posFinal=posXLastChild+$(idUl).childElements().last().getWidth(); 53 if (posX1-decal<decal){ 54 decal=posX1-decal; 55 } 56 if(btPrec){ 57 btPrec.style.visibility="visible"; 58 } 59 if(params.scrollSansEffet){ 60 var position = $(idUl).positionedOffset(idDiv).left; 61 $(idUl).style.left = (position + (decal*-1))+"px"; 62 //console.log('effects.js setScrollHorizontalOnDiv btSuiv position:'+position*-1+' posFinal:'+posFinal+' decal: '+decal); 63 if(decal == 0){ 64 btSuiv.style.visibility="hidden"; 65 } 66 if ($(params.ulJumelle)){ 67 $(params.ulJumelle).style.left = $(params.ulJumelle).positionedOffset(idDiv).left + (decal*-1); 68 } 69 }else{ 70 new Effect.Move(idUl, {x: decal*-1, mode: 'relative'}) 71 if ($(params.ulJumelle)){ 72 new Effect.Move(params.ulJumelle, {x: decal*-1, mode: 'relative'}) 73 } 74 } 75 } 76 } 77 if(btPrec){ 78 btPrec.onclick=function(evt){ 79 if (params.decalage){ 80 decal=params.decalage; 81 } else if (params.objDecalage){ 82 decal=params.objDecalage.getWidth(); 83 if (params.multipDecal){ 84 decal*=params.multipDecal; 85 } 86 } else { 87 decal=$(idDiv).getWidth(); 88 } 89 var posX=$(idUl).positionedOffset(idDiv).left; 90 if (posX+decal>0){ 91 decal=posX*-1; 92 } 93 if(btSuiv){ 94 btSuiv.style.visibility="visible"; 95 } 96 if(params.scrollSansEffet){ 97 var position = $(idUl).positionedOffset(idDiv).left; 98 $(idUl).style.left = (position + decal)+"px"; 99 //console.log('effects.js setScrollHorizontalOnDiv btPrec position:'+position+' decal: '+decal); 100 if((position + decal)==0){ 101 btPrec.style.visibility="hidden"; 102 } 103 if ($(params.ulJumelle)){ 104 $(params.ulJumelle).style.left = $(params.ulJumelle).positionedOffset(idDiv).left + decal; 105 } 106 } else { 107 new Effect.Move(idUl, {x: decal, mode: 'relative'}) 108 if ($(params.ulJumelle)){ 109 new Effect.Move(params.ulJumelle, {x: decal, mode: 'relative'}) 110 } 111 } 112 } 113 } 114 return true; 115} 116 117 118function setScrollVerticalOnDiv(idDiv,idUl,params){ 119 var btSuiv=$(params.nextButton); 120 var btPrec=$(params.prevButton); 121 var decal; 122 //if (!$(params.nextButton) || !$(params.prevButton)){return false;} 123 if (!params.noResizeToLi){ 124 if ($(idDiv) && $(idUl) && $(idUl).firstChild){ 125 //valeur par defaut 126 //if(params.resizeOnlyDiv)var tailleMax = normaliseTaille(idDiv, idUl+" li","fieldset",{}); 127 var tailleMax = normaliseTaille(idDiv, idUl+" li","fieldset",{"height":true,"width":true, "conteneur":"li"}); 128 if(getVersionIE()<9){ 129 var hauteurMax = parseInt(tailleMax['h'])+10; 130 var largeurMax = parseInt(tailleMax['w'])+20; 131 }else{ 132 var largeurMax = parseInt(tailleMax['w'])+15; 133 var hauteurMax = parseInt(tailleMax['h'])+10; 134 } 135 if(!params.nbLi){ 136 $(idDiv).style.width= largeurMax*2+'px'; 137 $(idDiv).style.height = hauteurMax*3+'px'; 138 $(idUl).style.width=(largeurMax-5)*2+'px'; 139 }else{ 140 if (parseInt(params.nbLi)<=2){ 141 $(idDiv).style.height = hauteurMax+'px'; 142 if(parseInt(params.nbLi)<=1){ 143 $(idDiv).style.width=largeurMax+'px'; 144 $(idUl).style.width=largeurMax-5+'px'; 145 } 146 else{ 147 $(idDiv).style.width=largeurMax*2+'px'; 148 $(idUl).style.width=(largeurMax-5)*2+'px'; 149 } 150 }else if(parseInt(params.nbLi)>2 && (parseInt(params.nbLi)<7)){ 151 $(idDiv).style.height = hauteurMax*(Math.ceil(params.nbLi/2))+'px'; 152 $(idDiv).style.width = largeurMax*2+'px' 153 $(idUl).style.width=(largeurMax-5)*2+'px'; 154 }else{ 155 $(idDiv).style.width= largeurMax*2+'px' 156 $(idDiv).style.height = hauteurMax*3+'px'; 157 $(idUl).style.width=(largeurMax-5)*2+'px' 158 } 159 } 160 $(idUl).style.padding='0px'; 161 162 } 163 } 164 if (btSuiv){ 165 btSuiv.onclick=function (evt){ 166 //$(idDiv).style.width=$(idUl).firstChild.offsetWidth+'px'; 167 if (params.decalage)decal=params.decalage; 168 else if (params.nbLiDecal){ 169 var unLi=$(idUl).childNodes[1].offsetHeight; 170 decal=unLi*params.nbLiDecal; 171 }else if(params.listeBulle){ 172 //jslog($(idUl).childNodes[1].offsetHeight); 173 174 if($(idUl).positionedOffset(idDiv).top>0){ 175 if(getVersionIE()<9)decal = hauteurMax+25; 176 else decal = hauteurMax+20; 177 } 178 else{ 179 decal = hauteurMax+2; 180 } 181 }else decal=$(idDiv).getHeight();
182 var posYLastChild=$(idUl).childElements().last().positionedOffset(idUl).top; 183 var posY0=$(idUl).positionedOffset(idDiv).top; 184 var posY1=posYLastChild+$(idUl).childElements().last().getHeight()+posY0; 185 if (posY1-decal<decal){ 186 decal=posY1-decal; 187 } 188 if(params.scrollSansEffet){ 189 $(idUl).style.top = ($(idUl).positionedOffset(idDiv).top + (decal*-1))+"px"; 190 if ($(params.ulJumelle))$(params.ulJumelle).style.top = $(params.ulJumelle).positionedOffset(idDiv).top + (decal*-1); 191 }else{ 192 new Effect.Move(idUl, {y: decal*-1, mode: 'relative'}) 193 if ($(params.ulJumelle))new Effect.Move(params.ulJumelle, {y: decal*-1, mode: 'relative'}) 194 } 195 } 196 } 197 if(btPrec){ 198 btPrec.onclick=function(evt){ 199 if (params.decalage)decal=params.decalage; 200 else if (params.objDecalage){ 201 decal=params.objDecalage.getHeight(); 202 if (params.multipDecal)decal*=params.multipDecal; 203 }else if(params.listeBulle){ 204 if($(idUl).positionedOffset(idDiv).top>0){ 205 if(getVersionIE()<9)decal = hauteurMax+20; 206 else decal = hauteurMax+20; 207 } 208 else decal = hauteurMax+2; 209 } 210 else decal=$(idDiv).getHeight(); 211 212 var posY=$(idUl).positionedOffset(idDiv).top; 213 if (posY+decal>0){ 214 decal=posY*-1; 215 } 216 if(params.scrollSansEffet){ 217 $(idUl).style.top = ($(idUl).positionedOffset(idDiv).top + decal)+"px"; 218 if ($(params.ulJumelle))$(params.ulJumelle).style.top = $(params.ulJumelle).positionedOffset(idDiv).top + decal; 219 }else{ 220 new Effect.Move(idUl, {y: decal, mode: 'relative'}) 221 if ($(params.ulJumelle))new Effect.Move(params.ulJumelle, {y: decal, mode: 'relative'}) 222 } 223 } 224 } 225 226 return true; 227 228} 229 230 231function setScrollHorizontalOnLstGenerePage(idDiv,idUl,params){ 232 233 if (!$(idDiv) || !$(idUl) || !$(params.idDivPastePage))return false; 234 235 236 var eltUl=new Element("ul",{'class': 'ulScrollPage'}); 237 var numPage=1; 238 $(idUl).childElements().each(function (eltPage){ 239 var eltLi=new Element("li",{'class':'liScrollPage'}) 240 if (numPage==1)eltLi.addClassName("liScrollPage_select"); 241 eltLi.numPage=numPage; 242 eltLi.update(numPage++); 243 eltLi.observe("click",function(evt){ 244 $$("li.liScrollPage_select").each(function(obj){obj.removeClassName("liScrollPage_select");}); 245 this.addClassName("liScrollPage_select"); 246 247 var liAAfficher=$(idUl).childElements().toArray()[(this.numPage-1)]; 248 var decalLi=liAAfficher.positionedOffset(idDiv).left; 249 250 var decalCurr=$(idUl).positionedOffset(idDiv).left; 251 var decal=(decalLi+decalCurr)*-1; 252 253 new Effect.Move(idUl, {x: decal, mode: 'relative'}) 254 255 }); 256 eltUl.appendChild(eltLi); 257 258 }); 259 switch (params.position){ 260 case "bottom": 261 default: 262 $(params.idDivPastePage).appendChild(eltUl); 263 break; 264 case "top": 265 $(params.idDivPastePage).insertBefore(eltUl,$(params.idDivPastePage).childElements().first()); 266 break; 267 } 268 return true; 269 270 271} 272 273function normaliseTaille(idDiv,idConteneur,elementChild, params){ 274 275 var maxHeight = 0; 276 var maxWidth = 0; 277 var maxTaille = new Array(); 278 $$("#"+idConteneur+" "+elementChild).each(function(obj){ 279 if(getVersionIE()<9){ 280 if(obj.clientHeight>=maxHeight)maxHeight = obj.clientHeight; 281 if( obj.clientWidth>=maxWidth)maxWidth = obj.clientWidth; 282 }else{ 283 if(obj.offsetHeight>=maxHeight)maxHeight = obj.offsetHeight; 284 if(obj.offsetWidth>=maxWidth)maxWidth = obj.offsetWidth; 285 } 286 }); 287 if(params.conteneur){ 288 $$("#"+idConteneur).each(function(obj1){ 289 if(params.height){ 290 if(getVersionIE()<9)obj1.style.height=parseInt(maxHeight)+"px"; 291 else obj1.style.height=parseInt(maxHeight)+10+"px"; 292 } 293 if(params.width){ 294 if(getVersionIE()<9)obj1.style.width=parseInt(maxWidth)+10+"px"; 295 else obj1.style.width=parseInt(maxWidth)+10+"px"; 296 } 297 }); 298 } 299 $$("#"+idConteneur+" "+elementChild).each(function(obj){ 300 if(params.height){ 301 if(getVersionIE()<9)obj.style.height=parseInt(maxHeight)-10+"px"; 302 else obj.style.height=parseInt(maxHeight)+"px"; 303 } 304 if(params.width){ 305 if(getVersionIE()<9)obj.style.width=parseInt(maxWidth)-10+"px"; 306 else obj.style.width=parseInt(maxWidth)+"px"; 307 } 308 }); 309 maxTaille['h']=maxHeight; 310 maxTaille['w']=maxWidth; 311 return maxTaille; 312} 313 314function setActionSurDiaporama(){ 315 //on fait le diaporama en jquery maintenant 316 if(jQuery(".div_mediaDiapoPage").length>0){ 317 jQuery(".div_mediaDiapoPage").each(function(){ 318 if(jQuery(this).find("li").length>1){ 319 var time = jQuery(this).attr("data-temps"); 320 var hauteur = jQuery(this).attr("data-hauteur"); 321 var largeur = jQuery(this).attr("data-largeur"); 322 var afficherNavigation = jQuery(this).attr("data-navigation"); 323 var status_controls = false;
324 if(afficherNavigation == '1'){ 325 status_controls = true; 326 } 327 if(jQuery(this).attr("data-sudoslider") == '1'){ 328 var auto = false; 329 if(time>0){ 330 time *= 1000; 331 auto = true 332 } 333 //ne pas faire de fade: les textes ne sont pas gérés! 334 jQuery(this).css('width',largeur+'px'); 335 jQuery(this).css('position','relative'); 336 jQuery(this).css('overflow','hidden'); 337 jQuery(this).children('ul').css('position','relative'); 338 var sudoSliderLook = jQuery(this).sudoSlider({ 339 autowidth:false, 340 slideCount:1, 341 moveCount:1, 342 pause:time, 343 auto:auto 344 }); 345 346 } 347 else if(time>0){ 348 349 jQuery(this).jDiaporama({ 350 delay:time, 351 theme:"default", 352 useThumbs: false, 353 width:largeur, 354 height:hauteur, 355 transition:"fade", 356 status_controls: status_controls, 357 keyboard: false, 358 infos: true, 359 onrollover: false, 360 currentimage: status_controls, 361 controls:status_controls, 362 constraintWidth:false 363 }); 364 365 } 366 } 367 }); 368 } 369 if(jQuery(".SudoSlider_numeric").length>0){ 370 jQuery(".SudoSlider_numeric").each(function(){ 371 var sudoSlider = jQuery(this).sudoSlider({ 372 fade: true, 373 crossFade:false, 374 numeric:true, 375 prevNext:false 376 }); 377 }); 378 } 379 if(jQuery(".SudoSlider_auto").length>0){ 380 jQuery(".SudoSlider_auto").each(function(){ 381 var sudoSlider = jQuery(this).sudoSlider({ 382 fade: true, 383 auto:true, 384 prevNext:false 385 }); 386 }); 387 } 388 389 if(jQuery(".iteaV5_responsiveSlides").length>0){ 390 setTimeout(function(){ 391 jQuery('.iteaV5_responsiveSlides li img').each(function(){ 392 if(jQuery(this).data('srcfullquality')){ 393 jQuery(this).attr('src',jQuery(this).data('srcfullquality')); 394 } 395 }); 396 },5000); 397 jQuery(".iteaV5_responsiveSlides").each(function(){ 398 var time = 1000 * jQuery(this).attr("data-temps"); // temps d'affichage de la diapo 399 var speed = jQuery(this).attr("data-speed");//durée de la transition. 500ms pour tous, 1000 pour fédé 400 var nav = false;//afficher/masquer les boutons de navigation 401 402 var auto = true; 403 if(jQuery(this).attr("data-auto")=="false"){ 404 var auto = false; 405 } 406 407 if(jQuery(this).attr("data-nav") == '1'){ 408 nav = true; 409 } 410 if(!speed){ 411 speed = 500; 412 } 413 jQuery(this).responsiveSlides({ 414 timeout: time, // Integer: Time between slide transitions, in milliseconds 415 speed: speed, 416 nav : nav, 417 pager: nav, 418 prevText:"", 419 nextText:"", 420 auto:auto 421 }); 422 }); 423 424 iteaV5_responsiveSlidesLoadFondLi(); 425 jQuery(window).resize(function(){ 426 setTimeout(function(){ 427 iteaV5_responsiveSlidesLoadFondLi(); 428 },500); 429 430 }); 431 } 432 //ceci est l'ancienne version en prototype 433 /* 434 if($$('.div_mediaDiapoPage')){ 435 window.compteurImgInDiapoMedia=new Array();
436 //afficheNextImgInDiapo(); 437 var temps; 438 $$('.div_mediaDiapoPage').each(function(elt){ 439 temps = elt.getAttribute("id"); 440 if(getVersionIE()<9)document.tidIntervalDiap=window.setInterval(afficheNextImgInDiapo, 5000); 441 else document.tidIntervalDiap=setInterval("afficheNextImgInDiapo()",5000); 442 }); 443 }*/ 444} 445 446function iteaV5_responsiveSlidesLoadFondLi(){ 447 jQuery('li[data-diaporamasrcli]').each(function(){ 448 jQuery(this).css('background-image','url('+jQuery(this).data('diaporamasrcli')+'?width='+jQuery(this).width()+'&height='+jQuery(this).height()+')'); 449 }); 450} 451 452function afficheNextImgInDiapo(){ 453 $$('.div_mediaDiapoPage').each(function(elt){ 454 var divImgAAfficher = $(elt.childNodes[0]); 455 var listeMediaDispoInDiapo=$(elt.childNodes[2]).children; 456 457 if(window.compteurImgInDiapoMedia[elt.id]==undefined){ 458 if($(elt.childNodes[2]).children.length>2)window.compteurImgInDiapoMedia[elt.id]=1; 459 else window.compteurImgInDiapoMedia[elt.id]=0; 460 } 461 462 divImgAAfficher.childNodes[0].style.position="absolute"; 463 divImgAAfficher.childNodes[1].style.position="absolute"; 464 465 if($(divImgAAfficher.childNodes[0]).style.display=="none"){ 466 $(divImgAAfficher.childNodes[0]).appear({duration:1.5, from:0.0, to:1.0}); 467 $(divImgAAfficher.childNodes[1]).fade({duration:1.5, from:1.0, to:0.0}); 468 } 469 if($(divImgAAfficher.childNodes[1]).style.display=="none"){ 470 $(divImgAAfficher.childNodes[1]).appear({duration:1.5, from:0.0, to:1.0}); 471 $(divImgAAfficher.childNodes[0]).fade({duration:1.5, from:1.0, to:0.0}); 472 } 473 474 //window.setTimeout("",1000); 475 476 //on change le SRC de l'image en attente par la prochaine image 477 if($(divImgAAfficher.childNodes[0]).style.display=="none"){ 478 $(divImgAAfficher.childNodes[0]).src=$(listeMediaDispoInDiapo[window.compteurImgInDiapoMedia[elt.id]]).readAttribute("source"); 479 }else $(divImgAAfficher.childNodes[1]).src=$(listeMediaDispoInDiapo[window.compteurImgInDiapoMedia[elt.id]]).readAttribute("source"); 480 481 //on incrémente le compteur en vérifiant de ne pas sortir du tableau 482 window.compteurImgInDiapoMedia[elt.id]+=1; 483 if(window.compteurImgInDiapoMedia[elt.id]>=$(elt.childNodes[2]).children.length){ 484 window.compteurImgInDiapoMedia[elt.id]=0; 485 } 486 }); 487} 488 489function blindUpDown(idDiv){ 490 var div = $(idDiv); 491 if(!div) return; 492 if(div.showing!=true){ 493 div.showing=true; 494 Effect.BlindDown($(div), {duration: 0.5}); 495 } 496 else{ 497 div.showing=false; 498 Effect.BlindUp($(div), {duration: 0.5 }); 499 } 500} 501 502function blindUpDownByClass(classe){ 503 var elems = $$(classe); 504 if(!elems)return; 505 elems.each(function(elem){ 506 blindUpDown(elem.identify()); 507 }); 508}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.