// JavaScript Document
var base = document.getElementsByTagName('base')[0].href;
	
function init(){
	var divs = document.getElementById('menu').getElementsByTagName('div');
	var i;
	for(i=0; i<divs.length;i++){
		var tt = divs[i];
		if(tt.className == 'menu_div_s'){
			tt.tim;
			tt.ss_menu = tt.getElementsByTagName('div')[0];
			tt.nbl = tt.ss_menu.getElementsByTagName('a').length;
			
			tt.twn = new Tween(tt.ss_menu, {'height':0,'opacity':0});

			
			tt.onmouseover = menu_d;
			tt.onmouseout 	= menu_i;
			tt.trans = 300;
			tt.fermer = function(){
				this.twn.moveTo({'height':0,'opacity':0},this.trans);
			}
		}
		if(i>25)return;
	}
}

function menu_d(){
	var nh = this.nbl*25+15;
	this.ss_menu.style.display = 'block';
	this.twn.moveTo({'height':nh,'opacity':100},this.trans);
	clearTimeout(this.ti);
}

function menu_i(){
	var cls = this;
	this.ti = setTimeout(function(){cls.fermer()},this.trans);
}
