
DynLayer.nestRefArray=new Array();
DynLayer.refArray=new Array();
DynLayer.refArray.i=0;
DynLayer.set=false;
function DynLayer(id,nestref){
 var a=arguments;
 if(!DynLayer.set)DynLayerInit();
this.elm=this.event=document.getElementById(id);
 this.css=document.getElementById(id).style;
 this.doc=document;
this.x=this.elm.offsetLeft;
 this.y=this.elm.offsetTop;
 this.w=this.elm.offsetWidth;
 this.h=this.elm.offsetHeight;
this.id=id;
 this.nestref=nestref;
 this.obj=id+"DynLayer";
 eval(this.obj+"=this");
 if(a[2]&&a[3])this.moveTo(a[2],a[3]);
}
function DynLayerInit(nestref){
 if(!DynLayer.set)DynLayer.set=true;
for(var i=0;i<document.getElementsByTagName('DIV').length;i++){
 var divname=document.getElementsByTagName('DIV')[i].id;
 var index=divname.indexOf("Div");
 if(index > 0){
 eval(divname.substr(0,index)+' = new DynLayer("'+divname+'")');
}
}
return true
}
DynLayer.prototype.moveTo=function(x,y){
 if(x!=null){
 this.x=parseInt(x);
 if(browser.nav)this.css.left=this.x;
 else this.css.pixelLeft=this.x;
}
 if(y!=null){
 this.y=parseInt(y);
 if(browser.nav)this.css.top=this.y;
 else this.css.pixelTop=this.y;
}
};
DynLayer.prototype.moveBy=function(x,y){
 this.moveTo(this.x+parseInt(x),this.y+parseInt(y));
};
DynLayer.prototype.show=function(){
 this.css.visibility=(browser.nav4)?"show" : "visible";
};
DynLayer.prototype.hide=function(){
 this.css.visibility=(browser.nav4)?"hide" : "hidden";
};
DynLayer.prototype.toggleVisible=function(){
((this.css.visibility=="hide")||(this.css.visibility=="hidden"))?this.show(): this.hide();
};