//<![CDATA[
var IE = document.all;
var obj;

var BlendCountIMG, BlendCountIMGHG;
function FullSize(Picture, PicHeight, PicWidth) {
	ScrollPosition();
	ScrnY();
	var PicHgW = PicWidth + 8;
	var PicHgH = PicHeight + 38;
	var ImgMarginX	= parseInt(-PicHgW / 2);
	var ImgMarginY	= parseInt(-PicHgH / 2);
	var ShMarginX		= parseInt(-PicHgW / 2 + 10);
	var ShMarginY		= parseInt(-PicHgH / 2 + 10);
	obj = document.getElementById('SCRD');
	SetOpacity(obj, 0);
	obj = document.getElementById('IMGhg');
	SetOpacity(obj, 0);
	obj = document.getElementById('IMGShadow');
	
	SetOpacity(obj, 0);
	document.getElementById('SCR').style.top			=  ScrollPosY + 'px';
	document.getElementById('SCR').style.display	= 'block';
	document.getElementById('SCRD').style.top			=  ScrollPosY + 'px';
	document.getElementById('SCRD').style.height	=  ScrnHeight + 'px';
	document.getElementById('SCRD').style.display	= 'block';
	document.getElementById('IMGhg').style.display= 'block';
	document.getElementById('IMGhg').style.width	= PicHgW + 'px';
	document.getElementById('IMGhg').style.height	= PicHgH + 'px';
	document.getElementById('IMGhg').style.margin	= ImgMarginY + 'px 0 0 ' +  ImgMarginX + 'px';
	document.getElementById('IMGShadow').style.display= 'block';
	document.getElementById('IMGShadow').style.width	= PicHgW + 'px';
	document.getElementById('IMGShadow').style.height	= PicHgH + 'px';
	document.getElementById('IMGShadow').style.margin = ShMarginY + 'px 0 0 ' +  ShMarginX + 'px';
	document.getElementById('SCRIMG').src = Picture;
	BlendCountIMG	= 0;
	BlendCountIMGHG = 0;
	BlendAct = 1;
	StartOn();
}

function SetOpacity(obj, opacity) {
 opacity = (opacity == 100)?99.999:opacity;
 if(IE) {
 	obj.style.filter = "alpha(opacity:"+opacity+")";
 } else {
	 obj.style.KHTMLOpacity = opacity/100;
	 obj.style.MozOpacity = opacity/100;
	 obj.style.opacity = opacity/100;
	}
}

function StartOn() {
	if(BlendAct == 1) {
		BlendCountIMG = BlendCountIMG + 10;
		BlendCountIMGHG = BlendCountIMGHG + 3;
		if(BlendCountIMG < 101) {
			obj = document.getElementById('IMGhg');
			SetOpacity(obj, BlendCountIMG);
			obj = document.getElementById('IMGShadow');
			SetOpacity(obj, BlendCountIMGHG);
			obj = document.getElementById('SCRD');
			SetOpacity(obj, BlendCountIMGHG);
			window.setTimeout("StartOn()")
		}
	} else {
		StartOff();
	}
}
function PictureOff() {
	BlendAct = 2;
	StartOff();
}
function StartOff() {
	BlendCountIMG = BlendCountIMG - 10;
	BlendCountIMGHG = BlendCountIMGHG - 3;
	if(BlendCountIMG > 1) {
			obj = document.getElementById('IMGhg');
			SetOpacity(obj, BlendCountIMG);
			obj = document.getElementById('IMGShadow');
			SetOpacity(obj, BlendCountIMGHG);
			obj = document.getElementById('SCRD');
			SetOpacity(obj, BlendCountIMGHG);
		window.setTimeout("StartOff()")
	} else {
		BlendAct = 0;
		document.getElementById("SCR").style.display = "none";
		document.getElementById("SCRD").style.display = "none";
		document.getElementById("IMGShadow").style.display = "none";
		document.getElementById("SCRIMG").src = "images/gla-blank.gif";
	}
}
// ===
var ScrnHeight;
function ScrnY() {
	if (self.innerHeight) {
		ScrnHeight = self.innerHeight;}
	else if (document.documentElement && document.documentElement.clientHeight) {
		ScrnHeight = document.documentElement.clientHeight;}
	else if (document.body) {
		ScrnHeight = document.body.clientHeight;}
}
// ===
var ScrollPosY;
function ScrollPosition() {
	if (typeof window.pageYOffset != 'undefined') {
		ScrollPosY = window.pageYOffset;
	}
	else if (typeof document.compatMode != 'undefined' &&
		document.compatMode != 'BackCompat') {
		ScrollPosY = document.documentElement.scrollTop;
	}
	else if (typeof document.body != 'undefined') {
		ScrollPosY = document.body.scrollTop;
	}
}

	var Frage;
	function OK(Frage) {
		var conf = window.confirm(Frage);
		if (!conf) return false;
	}

	function vfStart() {
		// All blur
		vsLinks = document.getElementsByTagName('a');
		for(i = 0; i < vsLinks.length; i++){
			vsLinks[i].onfocus = vfLinkBlur;
			if(vsLinks[i].id.substring(0, 1) =='N') {
				vsLinks[i].onmouseover = vfSubShow;
				vsLinks[i].onmouseout = vfSubHide;
			}
		}
		
	
		vsDownLinks = document.getElementsByTagName('ul');
		var z = 0;
		for(i = 0; i < vsDownLinks.length; i++){
			if(vsDownLinks[i].id.substring(0, 1) =='U') {
				vsDownLinks[i].onmouseover = vfSubShow;
				vsDownLinks[i].onmouseout = vfSubHide;
			}
		}
		
		if(document.getElementById('FadeDiv')) BlendStart();
		if(document.getElementById('MapG')) load();
	}

	function vfLinkBlur(evt) {
		this.blur();
	}
	
	function vfSubShow(evt) {
		var i = this.id.substring(1);
		if(document.getElementById('P' + i).className == "Ph") {
			document.getElementById('P' + i).style.backgroundColor = MenuVCol[i];
		}
		if(document.getElementById('U' + i)) {
			document.getElementById('U' + i).style.left = document.getElementById('P' + i).offsetLeft + 12 + 'px';
			document.getElementById('U' + i).style.backgroundColor = MenuBCol[i];
			document.getElementById('U' + i).style.display = 'block';
		}
	}
	function vfSubHide(evt) {
		var i = this.id.substring(1);
		if(document.getElementById('P' + i).className == "Ph") {
			document.getElementById('P' + i).style.backgroundColor = StColor;
		}
		if(document.getElementById('U' + i)) {
			document.getElementById('U' + i).style.display = 'none';
		}
	}


	window.onload = function() {vfStart();}

//]]>
