var timer;
var uroven = 1;
var menuID = new Array();

function hide_menu(uroven,time){
	this.uroven = uroven;
	this.timer = setTimeout("hide('')",time);
}
function hide(uroven){
	var od = (uroven == '') ? this.uroven : uroven;
	for(var i=od; i<this.menuID.length; i++){
		document.getElementById(this.menuID[i]).style.display = 'none';
	}
}

function show(uroven,id){
	clearTimeout(this.timer);
	this.menuID[uroven] = id;
	document.getElementById(id).style.display = 'block';
}

function wait(){
	clearTimeout(this.timer);
}

function set_left(menuTop,uroven,idMenu){
	var left = document.body.clientWidth/2 + 70;
	document.getElementById(idMenu).style.top = menuTop+'px';
	document.getElementById(idMenu).style.left = (left+(uroven-1)*159)+'px';
}