//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
// MENU
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

var undefined;

var istbild=0;
var warbild=0;

startStatus = 0;
var startStatus2 = 0;
var zeit;
var time;


//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
// Allgemeine Funktionen
//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
// onMouseover Funktion Hauptmenü
//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

var hmenu=new Array;
var hmenu2=new Array;
var hmenu3=new Array;

for (var i=1;i<6;i++){
  hmenu[i] = new Image();
  hmenu2[i] = new Image();
  hmenu3[i] = new Image();
  hmenu[i].src="http://www.schaaf-homefeeling.de/grafik/hm_"+i+".gif";
  hmenu2[i].src="http://www.schaaf-homefeeling.de/grafik/hm_"+i+"_.gif";
  hmenu3[i].src="http://www.schaaf-homefeeling.de/grafik/hm_"+i+"__.gif";
}

function over(x){
  document.images["hm"+x].src=hmenu2[x].src;
}

function out(x){
  warbild=istbild;
  if (warbild != x){
    document.images["hm"+x].src=hmenu[x].src;
  }
}

function fix(x){
  warbild=istbild;

  if (warbild != 0){
    document.images["hm"+warbild].src=hmenu[warbild].src;
  }
  if (x != 0){
    document.images["hm"+x].src=hmenu3[x].src;
  }
  istbild=x;
}


//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
// Untermenu 1
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++


function untermenu1()
{
	menu1 = document.getElementById('untermenu_1');
	untermenu1_einblenden();
}

function untermenu1_einblenden()
{
	startStatus = 1;
	aleft=-6;
	atop=105;
	menu1.style.zIndex = '1';
	menu1.style.display = 'block';
	menu1.style.position = 'absolute';
	menu1.style.left = aleft + 'px';
	menu1.style.top = atop + 'px';
	einfahren();
}

function untermenu1_eingeblendet()
{
	startStatus = 1;
	aleft=184;
	atop=105;
	menu1.style.zIndex = '10000';
	menu1.style.display = 'block';
	menu1.style.position = 'absolute';
	menu1.style.left = aleft + 'px';
	menu1.style.top = atop + 'px';
}


function einfahren()
{
	if (time)
	{
		window.clearTimeout(time);
	}
	if (aleft<184)
	{
		aleft=aleft+10;
		menu1.style.left=aleft + 'px';
		time = window.setTimeout ('einfahren()', 0);
  }
  if (aleft==184)
  {
		menu1.style.zIndex = '10000';
		zeit = window.setTimeout("weguntermenu1_ausblenden ();", 50);
  } 

}

//+++++++++++++++++++++++++++++++++++++++++++++++
// Ausblenden
//+++++++++++++++++++++++++++++++++++++++++++++++


function weguntermenu1 ()
{
  startStatus = 0;
  zeit = window.setTimeout("weguntermenu1_ausblenden ();", 50);  
}

function weguntermenu1_ausblenden ()
{
  weg_menu1 = document.getElementById('untermenu_1');
  if (startStatus == 0)
 	{
 		weg_menu1.style.display = 'none';
	}
  if (startStatus == 1)
 	{
    return;
 	}
  
}


//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
// Untermenu 2
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++


function untermenu2 ()
{
	menu2 = document.getElementById('untermenu_2');
	untermenu2_einblenden();
}

function untermenu2_einblenden ()
{ 
  startStatus2 = 1;
  bleft=-36;
	btop=125;
	menu2.style.zIndex = '1';
	menu2.style.display = 'block';
	menu2.style.position = 'absolute';
	menu2.style.left = bleft + 'px';
	menu2.style.top = btop + 'px';
	einfahren2();
}

function untermenu2_eingeblendet()
{
	startStatus2 = 1;
	bleft=184;
	btop=125;
	menu2.style.zIndex = '10000';
	menu2.style.display = 'block';
	menu2.style.position = 'absolute';
	menu2.style.left = bleft + 'px';
	menu2.style.top = btop + 'px';
}

function einfahren2()
{
	if (time)
	{
		window.clearTimeout(time);
	}
	if (bleft<184)
	{
		bleft=bleft+10;
		menu2.style.left=bleft + 'px';
		time = window.setTimeout ('einfahren2()', 0);
  }
  if (bleft==184)
  {
		menu2.style.zIndex = '10000';
		zeit = window.setTimeout("weguntermenu2_ausblenden ();", 50);
  } 

}

//+++++++++++++++++++++++++++++++++++++++++++++++
// Ausblenden
//+++++++++++++++++++++++++++++++++++++++++++++++

function weguntermenu2 ()
{
  startStatus2 = 0;
  zeit = window.setTimeout("weguntermenu2_ausblenden ();", 50);  
}

function weguntermenu2_ausblenden ()
{
  weg_menu2 = document.getElementById('untermenu_2');
  if (startStatus2 == 0)
 	{
 		weg_menu2.style.display = 'none';
	}
  if (startStatus2 == 1)
 	{
    return;
 	}
  
}


