// fonction pour le menu horizontal
		var obj = null;
		function checkHover() {
			if (obj) {
				obj.find('ul').fadeOut('fast');	
			} //if
		} //checkHover


// fonction anti spam pour le courriel
function courriel (txt, disp) {
var v = "contact";var w = "@";var x = "maps";var y = "designers";var z = "com";
var ad = v + w + x  + y + "." + z ;
document.write ("<a id='courriel_script' href='mailto:" + ad +"?subject=MapsDesigners Contact' style='height:15px; display:" + disp + "'>" + txt +"</a>");
}




$(document).ready(function(){

// animations des photos			
			$(".reseau_photo img").hide().fadeIn(2000);
			$(".photo_id, .reseau_photo img").hover(function() {$(this).fadeTo("fast", 0.33);},function() {$(this).fadeTo(1000, 1.00);});


// Préchargement du bando			
			$("#bando").removeAttr("style");
			$("#bando").addClass("bando");
			
// animation des membres du réseau			
/*
			$(".membre .icone").hover(
				function() {
					$(this).fadeTo("fast", 0.33);
				},
				function() {
					$(this).fadeTo("fast", 1.00);
				}
			);

			$(".membre .icone, .membre .nom").toggle(
				function() {
					$(this).parent().next().slideDown("fast");
				},
				function() {
					$(this).parent().next().slideUp("fast");
				}
			);
*/

			$(".lien_nom").click(
				function() {
					var designer = "#" + $(this).attr("id");
					console.log(designer);
					$("a[name="+designer+"]").click();
				}
			);
						
// animation des menus horizontaux	

/*

			var larg = 0;	
			$(".page").each(
				function(){
					//alert($(this).text() +" : "+$(this).width())
					var largeur = $(this).width();
					$(this).width(largeur); 
				}
			);

			//$("#Nav li ul").hide();


			$('#Nav > li:not(.separ)').hover(
				function() {
					if (!e) var e = window.event;
					e.cancelBubble = true;
					if (e.stopPropagation) e.stopPropagation();
					if (obj) {
						obj.find('ul').fadeOut('fast');
						obj = null;
					} //if
					$(this).css({backgroundColor:"#dc4a04"});
					$(this).find('ul').fadeIn('fast');
				},
				function() {
					if (!e) var e = window.event;
					e.cancelBubble = true;
					if (e.stopPropagation) e.stopPropagation();
					$(this).css({background: "none"});
					obj = $(this);
					setTimeout("checkHover()",0); // si vous souhaitez retarder la disparition, c'est ici

				}
			);


*/			
			function page_active() {
				var id_page = $("body").attr("id");
				if (id_page != 'index') {
					page = "#"+id_page;
					$(".page").filter(page).css({color: "white", backgroundColor: "black"});
					//$(".item").filter(page).parent("ul").parent(".page").fadeTo("slow", 1).css({backgroundColor:"#dc4a04"});
				}
			}

			page_active();

			
/*
			$("#Nav li:not(.separ)").hover(
				function (e) {
					if (!e) var e = window.event;
					e.cancelBubble = true;
					if (e.stopPropagation) e.stopPropagation();
					$(this).children("ul").slideDown("fast");
				},
				function(e){
					if (!e) var e = window.event;
					e.cancelBubble = true;
					if (e.stopPropagation) e.stopPropagation();
					$(this).children("ul").slideUp("fast");
			});

*/			
		

	
//css({backgroundColor:"#dc4a04"})


// animation du menu d'index			
			$("#menu").fadeIn(500);

/*
			$("#menu dt").hover(
				function () {
					var dd = $(this).next();
					$(this).siblings().not(dd).fadeTo("fast", 0.33);
				},function(){
					var dd = $(this).next();
					$(this).siblings().not(dd).fadeTo("fast", 1);
			});
*/
		


// EN TRAVAUX			
		
			$("#masque").fadeTo("slow", 0.8);
			$("#travaux").fadeTo("slow", 0.3);

});

