var thumbnailviewer={enableTitle:true,enableAnimation:true,definefooter:'<div class="footerbar">Schließen X</div>',defineLoading:'<img src="/Pages/JavaCSS/ThumbnailLoading.gif"/><div class="Fototitel"> Loading Image... </div>',scrollbarwidth:16,opacitystring:'filter:progid:DXImageTransform.Microsoft.alpha(opacity=10); -moz-opacity: 0.1; opacity: 0.1',targetlinks:[],createthumbBox:function(){document.write('<div id="thumbBox" onClick="thumbnailviewer.closeit()"><div id="thumbImage"></div>'+this.definefooter+'</div>')
document.write('<div id="thumbLoading">'+this.defineLoading+'</div>')
this.thumbBox=document.getElementById("thumbBox")
this.thumbImage=document.getElementById("thumbImage")
this.thumbLoading=document.getElementById("thumbLoading")
this.standardbody=(document.compatMode=="CSS1Compat")?document.documentElement:document.body},centerDiv:function(divobj){var ie=document.all&&!window.opera
var dom=document.getElementById
var scroll_top=(ie)?this.standardbody.scrollTop:window.pageYOffset
var scroll_left=(ie)?this.standardbody.scrollLeft:window.pageXOffset
var docwidth=(ie)?this.standardbody.clientWidth:window.innerWidth-this.scrollbarwidth
var docheight=(ie)?this.standardbody.clientHeight:window.innerHeight
var docheightcomplete=(this.standardbody.offsetHeight>this.standardbody.scrollHeight)?this.standardbody.offsetHeight:this.standardbody.scrollHeight
var objwidth=divobj.offsetWidth
var objheight=divobj.offsetHeight
var topposition=(docheight>objheight)?scroll_top+docheight/2-objheight/2+"px":scroll_top+10+"px"
divobj.style.left=docwidth/2-objwidth/2+"px"
divobj.style.top=Math.floor(parseInt(topposition))+"px"
divobj.style.visibility="visible"},showthumbBox:function(){this.centerDiv(this.thumbBox)
if(this.enableAnimation){this.currentopacity=0.1
this.opacitytimer=setInterval("thumbnailviewer.opacityanimation()",20)}},loadimage:function(link){if(this.thumbBox.style.visibility=="visible")
this.closeit()
var imageHTML='<img src="'+link.getAttribute("href")+'" style="'+this.opacitystring+'" />'
if(this.enableTitle&&link.getAttribute("title"))
imageHTML+='<div class="Fototitel"/>'+link.getAttribute("title")+'</div/>'
this.centerDiv(this.thumbLoading)
this.thumbImage.innerHTML=imageHTML
this.featureImage=this.thumbImage.getElementsByTagName("img")[0]
this.featureImage.onload=function(){thumbnailviewer.thumbLoading.style.visibility="hidden"
thumbnailviewer.showthumbBox()}
if(document.all&&!window.createPopup)
this.featureImage.src=link.getAttribute("href")
this.featureImage.onerror=function(){thumbnailviewer.thumbLoading.style.visibility="hidden"}},setimgopacity:function(value){var targetobject=this.featureImage
if(targetobject.filters&&targetobject.filters[0]){if(typeof targetobject.filters[0].opacity=="number")
targetobject.filters[0].opacity=value*100
else
targetobject.style.filter="alpha(opacity="+value*100+")"}
else if(typeof targetobject.style.MozOpacity!="undefined")
targetobject.style.MozOpacity=value
else if(typeof targetobject.style.opacity!="undefined")
targetobject.style.opacity=value
else
this.stopanimation()},opacityanimation:function(){this.setimgopacity(this.currentopacity)
this.currentopacity+=0.1
if(this.currentopacity>1)
this.stopanimation()},stopanimation:function(){if(typeof this.opacitytimer!="undefined")
clearInterval(this.opacitytimer)},closeit:function(){this.stopanimation()
this.thumbBox.style.visibility="hidden"
this.thumbImage.innerHTML=""
this.thumbBox.style.left="-2000px"
this.thumbBox.style.top="-2000px"},cleanup:function(){this.thumbLoading=null
if(this.featureImage)this.featureImage.onload=null
this.featureImage=null
this.thumbImage=null
for(var i=0;i<this.targetlinks.length;i++)
this.targetlinks[i].onclick=null
this.thumbBox=null},dotask:function(target,functionref,tasktype){var tasktype=(window.addEventListener)?tasktype:"on"+tasktype
if(target.addEventListener)
target.addEventListener(tasktype,functionref,false)
else if(target.attachEvent)
target.attachEvent(tasktype,functionref)},init:function(){if(!this.enableAnimation)
this.opacitystring=""
var pagelinks=document.getElementsByTagName("a")
for(var i=0;i<pagelinks.length;i++){if(pagelinks[i].getAttribute("rel")&&pagelinks[i].getAttribute("rel")=="thumbnail"){pagelinks[i].onclick=function(){thumbnailviewer.stopanimation()
thumbnailviewer.loadimage(this)
return false}
this.targetlinks[this.targetlinks.length]=pagelinks[i]}}
this.dotask(window,function(){if(thumbnailviewer.thumbBox.style.visibility=="visible")thumbnailviewer.centerDiv(thumbnailviewer.thumbBox)},"resize")}}
thumbnailviewer.createthumbBox()
thumbnailviewer.dotask(window,function(){thumbnailviewer.init()},"load")
thumbnailviewer.dotask(window,function(){thumbnailviewer.cleanup()},"unload")
var temp,temp2,cookieArray,cookieArray2,cookieCount;function initiate(){cookieCount=0;if(document.cookie){cookieArray=document.cookie.split(";");cookieArray2=new Array();for(i in cookieArray){cookieArray2[cookieArray[i].split("=")[0].replace(/ /g,"")]=cookieArray[i].split("=")[1].replace(/ /g,"");}}
cookieArray=(document.cookie.indexOf("state=")>=0)?cookieArray2["state"].split(","):new Array();temp=document.getElementById("Tree");for(var o=0;o<temp.getElementsByTagName("li").length;o++){if(temp.getElementsByTagName("li")[o].getElementsByTagName("ul").length>0){temp2=document.createElement("span");temp2.className="symbols";temp2.style.backgroundImage=(cookieArray.length>0)?((cookieArray[cookieCount]=="true")?"url(/Pages/JavaCSS/Tree_minus.gif)":"url(/Pages/JavaCSS/Tree_plus.gif)"):"url(/Pages/JavaCSS/Tree_plus.gif)";temp2.onclick=function(){showhide(this.parentNode);writeCookie();}
temp.getElementsByTagName("li")[o].insertBefore(temp2,temp.getElementsByTagName("li")[o].firstChild)
temp.getElementsByTagName("li")[o].getElementsByTagName("ul")[0].style.display="none";if(cookieArray[cookieCount]=="true"){showhide(temp.getElementsByTagName("li")[o]);}
cookieCount++;}
else{temp2=document.createElement("span");temp2.className="symbols";temp2.style.backgroundImage="url(/Pages/JavaCSS/Tree_doc.gif)";temp.getElementsByTagName("li")[o].insertBefore(temp2,temp.getElementsByTagName("li")[o].firstChild);}}}
function showhide(el){el.getElementsByTagName("ul")[0].style.display=(el.getElementsByTagName("ul")[0].style.display=="block")?"none":"block";el.getElementsByTagName("span")[0].style.backgroundImage=(el.getElementsByTagName("ul")[0].style.display=="block")?"url(/Pages/JavaCSS/Tree_minus.gif)":"url(/Pages/JavaCSS/Tree_plus.gif)";}
function writeCookie(){cookieArray=new Array()
for(var q=0;q<temp.getElementsByTagName("li").length;q++){if(temp.getElementsByTagName("li")[q].childNodes.length>0){if(temp.getElementsByTagName("li")[q].childNodes[0].nodeName=="SPAN"&&temp.getElementsByTagName("li")[q].getElementsByTagName("ul").length>0){cookieArray[cookieArray.length]=(temp.getElementsByTagName("li")[q].getElementsByTagName("ul")[0].style.display=="block");}}}
document.cookie="state="+cookieArray.join(",")+";expires="+new Date(new Date().getTime()+365*24*60*60*1000).toGMTString();}
if(window.navigator.systemLanguage&&!window.navigator.language){function hoverIE(){var LI=document.getElementById("MainNav").firstChild;do{if(sucheUL(LI.firstChild)){LI.onmouseover=einblenden;LI.onmouseout=ausblenden;}
LI=LI.nextSibling;}
while(LI);}
function sucheUL(UL){do{if(UL)UL=UL.nextSibling;if(UL&&UL.nodeName=="UL")return UL;}
while(UL);return false;}
function einblenden(){var UL=sucheUL(this.firstChild);UL.style.display="block";UL.style.backgroundColor="#80A080";}
function ausblenden(){sucheUL(this.firstChild).style.display="none";}
window.onload=hoverIE;}