// Galerie, slide show
function findPosX(obj){var posx=0;if (obj.offsetParent){while (obj.offsetParent){posx+=obj.offsetLeft
obj=obj.offsetParent;}}
else if (obj.x){posx+=obj.x;}
return posx;}
function jumpTo(num){location.href="page_"+num+".html";if (parent.index && parent.slide){if (num=="1"){parent.index.scrollTo(0,0)
}
else if (parent.index.document.images["thumb"+num]){var x=findPosX(parent.index.document.images["thumb"+num]);if (x > 0){parent.index.scrollTo(x,0);}}
else if (parent.index.document.anchors["anchor"+num]){parent.index.location.hash="anchor"+num;}}}
function loadNextImage(num){if (document.images){if (navigator.userAgent.indexOf("Opera") !=-1){nextimage=new Image();nextimage.src="../mediafiles/l"+num+".jpg";}
else if (navigator.userAgent.indexOf("MSIE") !=-1 && navigator.userAgent.indexOf("Mac") !=-1){;}
else{nextimage=new Image();nextimage.src="../mediafiles/l"+num+".jpg";}}}
function testCookie(cname, cvalue){val=0;if (document.cookie.length > 0){offset=document.cookie.indexOf(cname+"=");if (offset !=-1){val=unescape(document.cookie.substring(offset+cname.length+1,cname.length+offset+2));}
return val==cvalue;}}
function jumpIfShow(num){if (document.cookie.length > 0){if (testCookie("galerieslide",1)){jumpTo(num);}}
else{jumpTo(num)
}}
function setShow(num){if (document.cookie.length > 0){if (testCookie("galerieslide",1)){document.cookie="galerieslide=0; path=/";location.reload();}
else{document.cookie="galerieslide=1; path=/";jumpTo(num);}}
else{alert ("To be able to stop and start the slide show, please enable cookies in your web browser.\n\nIf cookies are enabled and you are viewing this gallery from a local disk (not from a web server), you may want to try a different browser. Some browsers, like Safari, do not use cookies locally.")
}}
function StartStopText(num){if (document.cookie.length > 0){if (testCookie("galerieslide",1)){document.write('<a href="javascript:setShow('+num+');">Stop slide show</a>');}
else{document.write('<a href="javascript:setShow('+num+');">Start slide show</a>');}}
else{document.write('<a href="javascript:setShow('+num+');">Stop slide show</a>');}}
function StartStopButton(num){if (document.cookie.length > 0){if (testCookie("galerieslide",1)){document.write('<form action="javascript:setShow('+num+');"><input type="submit" value="&nbsp;Stop slide show&nbsp;"></form>');}
else{document.write('<form action="javascript:setShow('+num+');"><input type="submit" value="&nbsp;Start slide show&nbsp;"></form>');}}
else{document.write('<form action="javascript:setShow('+num+');"><input type="submit" value="&nbsp;Stop slide show&nbsp;"></form>');}}
function StartStopImage(num){if (document.cookie.length > 0){if (testCookie("galerieslide",1)){document.write('<a href="javascript:setShow('+num+');"><img name="btnstop" src="showstop.gif" border="0" alt="Stop slide show"</a>');}
else{document.write('<a href="javascript:setShow('+num+');"><img name="btnstart" src="showstart.gif" border="0" alt="Start slide show"</a>');stopbutton=new Image();stopbutton.src="showstop.gif";}}
else{document.write('<a href="javascript:setShow('+num+');"><img name="btnstop" src="showstop.gif" border="0" alt="Stop slide show"</a>');}}
