//Javascript   (c) Karl Engelhart   15.10.2009



function OverEffect(objekt)
{
	//
	var nam = objekt.className.toString();
	//alert(nam);
	nam=nam.replace(/n$/,"o");
	//alert(nam);
	objekt.className = nam;		
	
}

function OutEffect(objekt)
{
	var nam = objekt.className.toString();
	nam=nam.replace(/o$/,"n");
	objekt.className = nam;		
}
function OverButtonEffect(objekt)
{	
	objary = $(objekt).childElements();
	for(i=0;i<objary.length;i++)
	{
		OverEffect($(objary[i]));
	}

}

function OutButtonEffect(objekt)
{
	objary = $(objekt).childElements();
	for(i=0;i<objary.length;i++)
	{
		OutEffect($(objary[i]));
	}

}


/*****************************************
//Supportfunktionen
**********************+++++++++++********/
var intro = function()
{
	//alert('introstart');
	$('gimg').show();
	$('containt').hide();
	ba=$('gimg').childElements();
	//alert(ba.length);
	for(i=ba.length-2;i>0;i--)
	{
		pause(1000);
		obj=$('gimg').childNodes[i];
		new Effect.Fade($(obj),{duration:1.5});
		//alert('dia'+i);
	}
	$('gimg').hide();
	$('containt').show();
}

var intropica = function()
{
	new Effect.Fade($('gimg01'),{duration:1.5});
}
var intropicb = function()
{
	new Effect.Fade($('gimg02'),{duration:1.5});
}
var introout = function()
{
	$('gimg').hide();
	$('gimg01').show();
	$('gimg02').show();
	$('containt').show();
}
/**  layout site  aufleb **/
var layout_site = function()
{
	xy = $("text").getHeight();
	bx = $("bild").getHeight();
	dy = $("download").getHeight() + 340;
	if(xy<bx)
	{	xy=bx;
		$('text').writeAttribute('style','height:'+(xy)+'px');	
	}
	if(xy<dy)
	{	xy=dy;
		$('text').writeAttribute('style','height:'+(xy)+'px');	
	}
	$('groundbox').writeAttribute('style','height:'+(xy+180)+'px');	
	$('footer').writeAttribute('style','top:'+(xy+210)+'px');	
}

