
function splashOver(){splashStop();spash_over=true;}
function splashOut(){splashStart();spash_over=false;}
function splashButton(value){if(value==spash_cur){return false;}
if(value>3){value=1;}
spash_old=spash_cur;spash_cur=value;splashHide.start();}
function splashPrew(){splashStop();value=spash_cur-1;if(value<1){value=3;}
splashButton(value);}
function splashNext(){splashStop();value=spash_cur+1;splashButton(value);}
function splashStop(){window.clearTimeout(spash_timeout);}
function splashStart(){spash_timeout=window.setTimeout("splashNext()",4000);}
var spash_timeout=-1;var spash_old=1;var spash_cur=1;var spash_over=false;var splashHide=null;var splashShow=null;window.addEvent('domready',function(){if(getObj('splash-buttons')){splashHide=new Spry.Effect.Fade('splash-header',{duration:0,from:100,to:0,setup:function(){setClass('splash-header-bg','splash'+spash_old);},finish:function(){setClass('splash-header','splash'+spash_cur);setText('splash-text',getObj('splash-text'+spash_cur).innerHTML);unsetSelected('splash-buttons','');setClass('splash-button'+spash_cur,'selected');splashShow.start();}});splashShow=new Spry.Effect.Fade('splash-header',{duration:1000,from:0,to:100,finish:function(){if(!spash_over){splashStart();}}});getObj('splash-button1').onclick=function(){splashButton(1);};getObj('splash-button1').onmouseover=function(){splashOver();};getObj('splash-button1').onmouseout=function(){splashOut();};getObj('splash-button2').onclick=function(){splashButton(2);};getObj('splash-button2').onmouseover=function(){splashOver();};getObj('splash-button2').onmouseout=function(){splashOut();};getObj('splash-button3').onclick=function(){splashButton(3);};getObj('splash-button3').onmouseover=function(){splashOver();};getObj('splash-button3').onmouseout=function(){splashOut();};getObj('splash-button-prew').onclick=function(){splashPrew();};getObj('splash-button-prew').onmouseover=function(){splashOver();};getObj('splash-button-prew').onmouseout=function(){splashOut();};getObj('splash-button-next').onclick=function(){splashNext();};getObj('splash-button-next').onmouseover=function(){splashOver();};getObj('splash-button-next').onmouseout=function(){splashOut();};splashStart();}});function SetBigImage(el,imgFile,imgTitle,width,height,imgFileBig,first){var image=document.getElementById('bigImageInner');if(!image)return false;if(el){unsetSelected('photos','A');setSelected(el);}
if(first){if(imgFileBig){image.innerHTML='<a href="'+imgFileBig+'" rel="lightbox" title="'+imgTitle+'" target="_blank"><img src="'+imgFile+'" width="'+width+'" height="'+height+'" alt="'+imgTitle+'" title="'+imgTitle+'" /></a>';}else{image.innerHTML='<img src="'+imgFile+'" width="'+width+'" height="'+height+'" alt="'+imgTitle+'" title="'+imgTitle+'" />';}
if(Slimbox){Slimbox.scanPage();}}else{se=new Fx.Tween(image,{property:'opacity',duration:200});se.start(1,0).chain(function(){tmp=new Fx.Morph(image,{duration:400,transition:Fx.Transitions.Quad.easeIn});tmp.start({'height':height,'width':width}).chain(function(){tmp=new Fx.Tween(image,{property:'opacity',duration:0});tmp.start(0,1).chain(function(){image.innerHTML='';preload=new Image();preload.onload=function(){tmp=new Fx.Tween(image,{property:'opacity',duration:0});tmp.start(1,0).chain(function(){if(imgFileBig){image.innerHTML='<a href="'+imgFileBig+'" rel="lightbox" title="'+imgTitle+'" target="_blank"><img src="'+imgFile+'" width="'+width+'" height="'+height+'" alt="'+imgTitle+'" title="'+imgTitle+'" /></a>';}else{image.innerHTML='<img src="'+imgFile+'" width="'+width+'" height="'+height+'" alt="'+imgTitle+'" title="'+imgTitle+'" />';}
tmp=new Fx.Tween(image,{property:'opacity',duration:200});tmp.start(0,1);if(Slimbox){Slimbox.scanPage();}})};preload.src=imgFile;});});});}
return false;}
function showAJAXicon(_item,_mode){if(document.getElementById(_item)){if(_item=='ajax-icon'){AJAXFade('content-wrapper');}
if(_mode==0){document.getElementById(_item).innerHTML='<div style="clear:both; margin:5px 0 10px 0;"><img src="'+site_url+'images/icon-ajax.gif" width="31" height="31" alt="-" /></div>';}
if(_mode==1){document.getElementById(_item).innerHTML=document.getElementById(_item).innerHTML+' ';setSelected(_item);}
if(_mode==2){document.getElementById(_item).innerHTML='<div align="center" style="clear:both; margin:0px;"><img src="'+site_url+'images/icon-ajax-bg.gif" width="31" height="31" alt="-" /></div>';}}}
function hideAJAXicon(_item,_mode){if(document.getElementById(_item)){if(_mode==1){unsetSelected(_item,'SPAN');}else{document.getElementById(_item).innerHTML='';}}}
function showTop(_y){if(_y){scrollTo(0,_y);}else{scrollTo(0,450);}}
