function $(obj){
	return document.getElementById(obj);
}
function menu(aObj,dObj,posL,posT){
	this.parentMenu=$(aObj);
	this.childMenu=$(dObj);
	var vScreenWidth=document.documentElement.clientWidth;
	if(vScreenWidth<1004)vScreenWidth=1004;
	this.childMenu.style.left=(vScreenWidth/2+posL)+"px";
	this.childMenu.style.top=posT+"px";
	
	this.parentMenu.menuObj=this;//保存menu object对象
	this.parentMenu.childDiv=this.childMenu;//保存需要显示的子菜单的ID
	this.parentMenu.onmouseover=this.show;//不能加括号
	this.parentMenu.onmouseout=function(){
		//alert(this.menuObj.childMenu.id);
		this.menuObj.hidden();
	}
	this.childMenu.onmouseover=this.show2;
	this.childMenu.onmouseout=this.hidden2;
}
menu.prototype.show=function(){
	this.childDiv.style.display="block";
}
menu.prototype.hidden=function(){
	//alert(this.childMenu.id);
	this.childMenu.style.display="none";
}
menu.prototype.show2=function(){
	this.style.display="block";
}
menu.prototype.hidden2=function(){
	this.style.display="none";
}
window.onload=initMenu;
window.onresize=initMenu;
function initMenu(){//在这里初始化菜单
	new menu("browser","menu_browser",-250,502);
	new menu("chat","menu_chat",-120,582);
	new menu("gsjj","menu_gsjj",-360,582);
}
