var slideshow_images=new Array();var preload=new Array();var slideshow_link=new Array();var slide=0;var slideshowImgDiv="slideshowImg";var slideshowWrapper="slideshow_pic";var slideshowLink="slideshowHref";var speed=6000;var featurePhotoPaused=false;var displayFeatureControls=false;function slideshow_loadNextImg(B,A){if(B){slide=slide-1;if(slide<0){slide=(slideshow_images.length-1)}}else{if(!A){slide=slide+1}if(slide>=slideshow_images.length){slide=0}}document.getElementById(slideshowImgDiv).src=preload[slide].src;document.getElementById(slideshowLink).href=slideshow_link[slide]}function slideshow_start(A){setTimeout(slideshow_switch(A),A)}function slideshow_loadImg(C,B,A){if(C){new Effect.Fade(slideshowWrapper,{duration:C,afterFinish:function(){new Effect.Appear(slideshowWrapper,{beforeStart:function(){slideshow_loadNextImg(B)},duration:C})}})}}function slideshow_switch(A){return(function(){slideshow_loadImg(1);timer=setTimeout(slideshow_switch(A),A);if(timer){if(displayFeatureControls==false){Effect.Appear("featurePhotoPaused",{duration:1});displayFeatureControls=true}}})}function stoper(){clearTimeout(timer)}function slideshow_pause(){if(featurePhotoPaused==false){featurePhotoPaused=true;document.getElementById("featurePhotoPaused").style.display="none";document.getElementById("featurePhotoPlay").style.display="block";stoper()}else{featurePhotoPaused=false;document.getElementById("featurePhotoPaused").style.display="block";document.getElementById("featurePhotoPlay").style.display="none";slideshow_start(speed)}}function slideshow_back(){if(featurePhotoPaused==false){slideshow_pause()}slideshow_loadImg(0.5,true)}function slideshow_next(){if(featurePhotoPaused==false){slideshow_pause()}slideshow_loadImg(0.5,false)}function slideshow_init(){slideshow_loadNextImg(false,true);slideshow_start(speed)}function slideshow_PreLoad(){for(var A=0;A<slideshow_images.length;A++){preload[A]=imageObj=new Image();preload[A].src=slideshow_images[A]}slideshow_init()}function slideshow_addImg(C,D,A){if(C){for(var B=0;B<slideshow_images.length;B++){if(slideshow_images[B]==C){return false}}slideshow_images[B]=C;if(!D){D="#"}slideshow_link[B]=D}return true};