startList = function() {
if (document.all&&document.getElementById) {
navRoot = document.getElementById("nav");
for (i=0; i<navRoot.childNodes.length; i++) {
node = navRoot.childNodes[i];
if (node.nodeName=="LI") {
node.onmouseover=function() {
this.className+=" over";
  }
  node.onmouseout=function() {
  this.className=this.className.replace(" over", "");
   }
   }
  }
 }
}
window.onload=startList;

function Help(thisverweis)
  {
if (thisverweis!="leer"){
var  MyFenster = open("Help_frames?helpfile="+thisverweis,"Fenster1","width=450,height=450,screenX=70,screenY=70,menubar=yes,resizable=yes");
   MyFenster.focus();
 }
  }

function NewWin(url,xw,yw){
 if (!xw){xw='470'}
 if (!yw){yw='650'}
 fin =  window.open(url,"ExtraWin","height="+yw+",width="+xw+",screenX=100,screenY=80,resizable=yes,scrollbars=yes");
 fin.focus();
}


function initSelect()
{
	var theSelect = document.getElementById("selector");
	
	theSelect.changed = false;
	theSelect.onfocus = selectFocussed;
	theSelect.onchange = selectChanged;
	theSelect.onkeydown = selectKeyed;
	theSelect.onclick = selectClicked;
	
	return true;
}




function selectChanged(theElement)
{
	var theSelect;
	
	if (theElement && theElement.value)
	{
		theSelect = theElement;
	}
	else
	{
		theSelect = this;
	}
	
	if (!theSelect.changed)
	{
		return false;
	}
	alert("The select has been changed to " + theSelect.value);
	return true;
}

function selectClicked()
{
	this.changed = true;
}

function selectFocussed()
{
	this.initValue = this.value;
	return true;
}

function selectKeyed(e)
{
	var theEvent;
	var keyCodeTab = "9";
	var keyCodeEnter = "13";
	var keyCodeEsc = "27";
	
	if (e)
	{
		theEvent = e;
	}
	else
	{
		theEvent = event;
	}

	if ((theEvent.keyCode == keyCodeEnter || theEvent.keyCode == keyCodeTab) && this.value != this.initValue)
	{
		this.changed = true;
		selectChanged(this);
	}
	else if (theEvent.keyCode == keyCodeEsc)
	{
		this.value = this.initValue;
	}
	else
	{
		this.changed = false;
	}
	return true;
}

