/*Script qui gère le menu dynamique*/
/*Réalisation : A.Bouquier - ESPRIT MULTIMEDIA*/

textfont = "Verdana"
textcolor= "#336699";
textcolor2= "#696969";
bgcolor2 = "#696969";
bgcolor = "#B3B3B3";
lastmv3 = "debut";
bgcolor = "#FFFFFF";
bgcolor2 = "#DDDDDD";
mv3_menu = new Array;
mv3_lien = new Array;
fsize = new Array;
fopac = new Array;
mv3tempo = new Array;
mv3tempo2 = new Array;
mv3_menu[0] = 'LA RESIDENCE';
fsize[0] = 0;
fopac[0] = 0;
mv3_menu[1] = 'SITUATION';
fsize[1] = 0;
fopac[1] = 0;
mv3_menu[2] = 'LOISIRS';
fsize[2] = 0;
fopac[2] = 0;
mv3_menu[3] = 'RESERVATIONS';
fsize[3] = 0;
fopac[3] = 0;
mv3_menu[4] = 'INFOS-CONTACT';
fsize[4] = 0;
fopac[4] = 0;


mv3_lien[0] = ''
mv3_lien[1] = ''
mv3_lien[2] = ''
mv3_lien[3] = ''
mv3_lien[4] = ''

mv3_lien[0] += '<A HREF="locations.html" CLASS=mv3style TARGET="fen-B"> . Locations saisonnières</A><BR>';
mv3_lien[0] += '<A HREF="images/photos/photosresidence.html" CLASS=mv3style TARGET="fen-B"> . Photos de la Résidence</A><BR>';
mv3_lien[0] += '<A HREF="types1.html" CLASS=mv3style TARGET="fen-B"> . Les Types 1</A><BR>';
mv3_lien[0] += '<A HREF="types3.html" CLASS=mv3style TARGET="fen-B"> . Les Types 3</A><BR>';

mv3_lien[1] += '<A HREF="bauduen.html" CLASS=mv3style TARGET="fen-B"> . Bauduen sur Verdon</A><BR>';
mv3_lien[1] += '<A HREF="gorgesverdon.html" CLASS=mv3style TARGET="fen-B"> . Gorges du Verdon</A><BR>';
mv3_lien[1] += '<A HREF="lacsaintecroix.html" CLASS=mv3style TARGET="fen-B"> . Le lac de Sainte Croix</A><BR>';
mv3_lien[1] += '<A HREF="moustiers.html" CLASS=mv3style TARGET="fen-B"> . Moustiers Sainte Marie</A><BR>';
mv3_lien[1] += '<A HREF="images/photos/photosenvirons.html" CLASS=mv3style TARGET="fen-B"> . Les alentours en PHOTOS</A><BR>';

mv3_lien[2] += '<A HREF="gr.html" CLASS=mv3style TARGET="fen-B"> . Randonnées</A><BR>';
mv3_lien[2] += '<A HREF="sporteau.html" CLASS=mv3style TARGET="fen-B"> . Sports d\'eau</A><BR>';
mv3_lien[2] += '<A HREF="sportnature.html" CLASS=mv3style TARGET="fen-B"> . Sports Nature</A><BR>';
mv3_lien[2] += '<A HREF="loisirdetente.html" CLASS=mv3style TARGET="fen-B"> . Loisirs et Détente</A><BR>';

mv3_lien[3] += '<A HREF="tarifs.html" CLASS=mv3style TARGET="fen-B"> . Prix Semaine/Week-end</A><BR>';
mv3_lien[3] += '<A HREF="reservations.html" CLASS=mv3style TARGET="fen-B"> . Procédure de réservation</A><BR>';

mv3_lien[4] += '<A HREF="coordonnees.html" CLASS=mv3style TARGET="fen-B"> . Nos coordonnées</A><BR>';
mv3_lien[4] += '<A HREF="formulairecontact.html" CLASS=mv3style TARGET="fen-B"> . Vous avez une question?</A><BR>';

function d(texte)
	{
	document.write(texte);
	}

function LanceAction(mode,sousmenu,id)
	{
	clearTimeout(mv3tempo[id]);
	clearTimeout(mv3tempo2[id]);
	if(mode == 1)
		{
		if(lastmv3 != "debut")
			LanceAction(0,"mv3sm"+lastmv3,lastmv3)
		drawmv3(sousmenu,id)
		}
	if(mode == 0)
		killmv3(sousmenu,id)
	}

function drawmv3(sousmenu,id)
	{
	lastmv3 = id;
	document.getElementById(sousmenu).innerHTML = "<TABLE ALIGN=center BORDER=0 CELLPADDING=0 CELLSPACING=0 WIDTH=160 STYLE=\"filter:alpha(opacity="+fopac[id]+")\"><TR><TD><DIV STYLE=\"font-size:"+fsize[id]+";font-family:Verdana\">"+mv3_lien[id]+"</DIV></TD></TR></TABLE>";
	if(fsize[id] < 10)
		{
		fsize[id]++;
		mv3tempo[id] = setTimeout("drawmv3('"+sousmenu+"',"+id+")",10)
		}
	else
		{
		if(fopac[id] < 100)
			{
			fopac[id] += 5
			mv3tempo[id] = setTimeout("drawmv3('"+sousmenu+"',"+id+")",10)
			}
		}
	}

function killmv3(sousmenu,id)
	{
	document.getElementById(sousmenu).innerHTML = "<TABLE ALIGN=center BORDER=0 CELLPADDING=0 CELLSPACING=0 WIDTH=160 STYLE=\"filter:alpha(opacity="+fopac[id]+")\"><TR><TD><SPAN STYLE=\"font-size:"+fsize[id]+"\"><FONT FACE="+textfont+">"+mv3_lien[id]+"</FONT></DIV></TD></TR></TABLE>";

	if(fopac[id] > 0)
		{
		fopac[id] -= 10
		mv3tempo2[id] = setTimeout("killmv3('"+sousmenu+"',"+id+")",5)
		}
	else
		{
		if(fsize[id] > 0)
			{
			fsize[id] -= 2;
			mv3tempo2[id] = setTimeout("killmv3('"+sousmenu+"',"+id+")",5)
			}
		}
	}

mv3_pos = -1;

d('<STYLE TYPE="text/css">\na.mv3style {color:'+textcolor+';text-decoration:none;}\na:hover.mv3style {color:'+textcolor2+';text-decoration:underlined;}\n</STYLE>');

d('<table bgcolor=#7788AA cellspacing=0 cellpadding=3 border=1 bordercolorlight=#4B4B4B bordercolordark=#C0C0C0 WIDTH=169>');

for(a=0;a<mv3_menu.length;a++)
	{
	if(document.getElementById && document.all)
		d("<TR><TD BGCOLOR="+bgcolor+" onMouseOver=\"this.style.background='"+bgcolor2+"'\" onClick=\"LanceAction('1','mv3sm"+a+"',"+a+")\" onMouseOut=\"this.style.background='"+bgcolor+"'\" STYLE=\"cursor:hand\"><FONT FACE=\""+textfont+"\" SIZE=2 COLOR="+textcolor+"><B><CENTER>"+mv3_menu[a]+"</CENTER></B></FONT><DIV ID=mv3sm"+a+"></DIV></TD></TR>");
	else
		d("<TR><TD BGCOLOR="+bgcolor+"><FONT FACE=\""+textfont+"\" SIZE=2 COLOR="+textcolor+"><B>"+mv3_menu[a]+"</B></FONT></TD></TR>");

	if(!(document.getElementById && document.all))
		d("<TR><TD BGCOLOR="+bgcolor+"><FONT FACE=\""+textfont+"\" SIZE=1><B>"+mv3_lien[a]+"</B></FONT></TD></TR>")
	}

d("</TABLE>");