// JavaScript Document

var windowHeight = 0;
var windowWidth = 0;
/*
 *Stellt Browser-abhängig die Höhe des Browser-Fensters fest.
 */
function calcWindowSize() {
	//Höhenangabe für Netscape, Mozilla und Opera
	if (typeof(window.innerHeight)=='number') {
		windowHeight=window.innerHeight-7;
		windowWidth=window.innerWidth;
	}
	//Internet Explorer
	else {
		//IE 6
		if ( document.documentElement && document.documentElement.clientHeight) {
			windowHeight= document.documentElement.clientHeight-7;
			windowWidth=document.documentElement.clientWidth;
		}
		//IE 4 & 5
		else {
			if (document.body&&document.body.clientHeight) {
				windowHeight=document.body.clientHeight-7;
				windowWidth=document.body.clientWidth;
			}
		}
	}
	//return windowHeight;
}
/**
 * Dummy function fuer Bestenliste
 */
function ShowEvents(button, idClass){
	return true;
}
/*Legt die Größe des Inhaltsfensters(cnt) abhängig von der Auflösung fest.
 *Falls der Benutzer Netscape/Mozilla verwendet, wird nichts gemacht,
 *da hier position:fixed funktioniert.
 */
function setContentHeight()
{
	//Abrufen der Fensterhöhe
	calcWindowSize();
	//Von der Fensterhöhe wird noch die Höhe der Kopf- und Fußleiste abgezogen
	//Logohöhe : 86 px
	//Fusszeile:  20 px
	var extraHeight = 18;
	//if( navigator.appName == "Opera" ){
	/*if ( navigator.appName != "Netscape" ){
		extraHeight = 20;
	}*/
	var contentHeight = (windowHeight -  55  - 20 - extraHeight );
	
	var windowHeightStr = contentHeight + "px";
	//alert( "<"+navigator.appName +">  ---  <" + contentHeight +">  ---  " + windowWidth );
    document.getElementById("content").style.height = windowHeightStr;
	// Limit content width for window width > 1024
	/*if( windowWidth <= 1024 ){
		document.getElementById("contentcenter").style.width = "auto";
	}*/
	document.getElementById("inhalt").focus();
	//document.getElementById("logoText").title = windowHeight;
    //alert(windowHeight);
}
/* Bei Änderung der Fenstergrösse wird ein Event ausgelöst.
Die Event-Funktion ruft dann setContentHeight auf */
 window.onresize = doChangeHeight;
 function doChangeHeight( e ){
	setContentHeight(); 
 }
