var globEbene=0;;

function init(ebene){
	if(ebene==1){
		$zInd=3;
		for(x=0;x<3;x++){
			document.getElementById('nav'+x).style.zIndex=$zInd;
//			alert("init:"+document.getElementById('nav'+x).style.zIndex);
			$zInd--;
		}
	}

}

function modZindex(myEbene){
	maxZIndex=0;
	for(x=0;x<3;x++){
		thisZIndex=document.getElementById('nav'+x).style.zIndex;
/* alert("thisZIndex="+thisZIndex); */
		if(thisZIndex>=maxZIndex) maxZIndex=++thisZIndex;
	}
	document.getElementById('nav'+(myEbene-1)).style.zIndex=maxZIndex;
/* alert("nav"+(myEbene-1)+" wird zu maxZIndex: "+maxZIndex);  */
}


function saveZIndexes(){
	getstr="";
	z=0;
	for(x=0;x<3;x++){
		thisZIndex=document.getElementById('nav'+x).style.zIndex;
		alert(thisZIndex);
		getstr+="zI"+x+"="+thisZIndex+"&";
		z++;
	}
	getstr+="anzZIs="+z;
//	alert(getstr);
	savepos=new domXml("act/saveZIs.php",getstr);
//	alert(savepos.xmlDoc.responseText);
}

function makeInvisible(ebene){
	for(i=(ebene);i<3;i++){
		document.getElementById('nav'+i).style.visibility='hidden';
	}
}

function dumpTrace(valueString){
	getstr="valueString="+valueString;
//	alert(getstr);
	savepos=new domXml("act/dumpTrace.php",getstr);
//alert(savepos.xmlDoc.responseText);
}

function overColor(obj){
	obj.style.backgroundColor="green";	
}
function outColor(obj){
	obj.style.backgroundColor="";	
}
