/*
 * Allgemeine Funktionen
 *
 * Lars Vogel
 * 11-05-2005
 *
 */
 
 
 try {
	document.execCommand("BackgroundImageCache", false, true);
} catch(err) {}
 
 // Layout
 
 // Div Hoehen wie Tagbelle
 /*
 function layout_colheight() {
    var h = document.getElementById("content").scrollHeight;
    document.getElementById("contentRight").style.height = h+'px';
}
// benoetigt onLoad Event
*/
 
// Fenster absolut positionieren
/*
function getPosition () {
		self.moveTo(100, 100);
}*/

// Fenster in den Vordergrund
function getFocus() {
    window.focus();
    /*window.moveTo(400, 300);*/
}

//Pop-UP Fenster (nicht verwendet)
function popUp(link, name) {
    var w  = 540;
	var h = 700;
	//alert("top="+((screen.height/2)-(h/1.5))+", left="+((screen.width/2)-(+w/2))+"");
 	if (link!=null && name!=null) {
	    window.open(link, name,"resizable=no,scrollbars=yes,locationbar=no,menuebar=no,status=no,height="+h+",width="+w+", top="+((screen.height/2)-(h/1))+", screenY="+((screen.height/2)-(h/1.5))+", left="+((screen.width/2)-(+w/2))+",screenX="+((screen.width/2)-(+w/2)));
		//window.open(link, name,"resizable=no,scrollbars=yes,locationbar=no,menuebar=no,status=no, height="+height+", width="+width+",left="((screen.width/2-(width/2))",top="((screen.height/2)-(height/1.5)));
	} else {
    	// DEBUG
		alert("Link oder Fensternahme fehlt");
	}
}

/* Element einfärben */
function getCellOver(element, color) {

	//alert("licht an: "+status);
    self.document.getElementById(element).style.backgroundColor="#"+color+"";
	self.document.getElementById(element).style.cursor="pointer";

}
function getCellOut(element, color) {

	//alert("licht an: "+status);
    self.document.getElementById(element).style.backgroundColor="#"+color+""; 
}


/* Tabellen-Border einfärben */
function getElementBorderOver(element, color) {
	self.document.getElementById(element).style.border="1px solid " +color;
}
function getElementBorderOut(element, color) {

    self.document.getElementById(element).style.border="1px solid "+color;
}

// Fenster in den Vordergrund
function getFocus() {
	window.focus();
	//window.moveTo(60, 100);
}


// Pop Up Fenster oeffnen
function fenster(link,id,w,h) {
	//window.open(name,id,'width='+w+',height='+h);
	window.open(link, id,"resizable=no,scrollbars=no,locationbar=no,menuebar=no,status=yes,height="+h+",width="+w+", top="+((screen.height/2)-(h/1.5))+", screenY="+((screen.height/2)-(h/1.5))+", left="+((screen.width/2)-(+w/2))+",screenX="+((screen.width/2)-(+w/2)));
}




