//change it's style when mouse over or leave it
function lib_changeStyle(){
if(this.isover){
this.css.backgroundColor=this.overcolor;
//this.css.fontWeight='bold';
this.css.borderRightWidth=0;
}else{
this.css.backgroundColor=this.bgcolor;
// this.css.fontWeight='normal';
if(this.owner.align=='Ver'||(this.owner.align=='Hor'&&this.levelIndex!=0)) this.css.borderRightWidth=1;
}
}
function lib_go(){
if(this.link) location.href=this.link;
else return false;
}
/* menu events*-----*/
function lib_menuMOver(){ //1.change style |2.show submenu
this.owner.currentover=this;
this.isover=true;
this.changeStyle();
this.checkMenu()
if(this.link) window.status=this.link;
else window.status='';
this.showSub()
clearTimeout(this.owner.time);
}
function lib_menuMOut(){//1.hide submenu
this.owner.lastover=this;
this.owner.time=setTimeout(this.owner.name+".hideAllSub()",600)
}
function lib_menuMClick(){
this.go()
}
/*** 类MENU***************************/
function TMenu(name){
this.name=name;
this.topmenu=new Array();
this.items=new Array();//store all menu items order by create line;
this.panel=new Array();
this.stylecode="";
this.htmlcode=""
this.levelcount=0
this.align='Hor' // H:horizontal|| V:vertical
//....................
//define level style,whick include this menuitem;first-line client setting,otherwise use default setting;
//if you wanna define every menuitem please :this.userLevlStyle=new Array();
//if you wanna define every menulevel please :this.userItemStyle=new Array();
//.............................................
this.userLevlStyle=new Array();
this.userItemStyle=new Array();
this.deftStyle=new Array();
//菜单项属性
this.deftStyle.itemheight=25;
this.deftStyle.bgcolor='#ffffff';
this.deftStyle.overcolor='#f7f7f7';
this.deftStyle.fontcolor='#333366';
this.deftStyle.fontsize=15;
this.deftStyle.fontfamily='tahoma, arial,helvetica';
this.deftStyle.border=1;
this.deftStyle.bordercolor='#e1e1e1';
this.deftStyle.borderstyle='dashed';
this.deftStyle.img=0;