divStyleScroller=function(e,g,h,i,j,b){document.getElementById(e);this.get=function(a){return document.getElementById(a)};this.scroller=this.get(i);this.scrollerBar=this.get(h);this.menu=this.get(g);this.content=this.get(e);this.scrollerTrackHeight=j;this.objectHeight=this.content.offsetHeight;this.objectTrackHeight=this.menu.offsetHeight;e=Math.round(this.objectHeight*this.scrollerTrackHeight/this.objectTrackHeight);this.scrollerHeight=b!=""&&b!=0?b:e;this.scrollEnabled=e<this.scrollerTrackHeight? true:false;this.scrollerBar.style.display=this.scrollEnabled?"block":"none";try{this.scroller.style.height=this.scrollerHeight+"px"}catch(k){this.scroller.style.height="0px"}this.delta=this.scrollEnabled?(this.objectTrackHeight-this.objectHeight)/(this.scrollerTrackHeight-this.scrollerHeight):0;this.step=10/this.delta;this.canDrag=false;this.shift_y=0;this.jump=function(a){if(!a)a=window.event;if(a.target!=this.scroller){var c=a.layerY?a.layerY:a.offsetY,f=parseInt(this.scroller.style.marginTop); this.setPosition(2*(c>f?1:-1)*this.step+f);this.fixForBrowsers(a)}return false};this.drag=function(a){if(!a)a=window.event;this.canDrag=true;this.shift_y=a.clientY-parseInt(this.scroller.style.marginTop);return false};this.move=function(a){if(!a)a=window.event;this.canDrag&&this.setPosition(a.clientY-this.shift_y);return false};this.drop=function(){this.canDrag=false};this.setPosition=function(a){this.scroller.style.marginTop=a<=this.scrollerTrackHeight-this.scrollerHeight&&a>=0?a+"px":a>this.scrollerTrackHeight- this.scrollerHeight?this.scrollerTrackHeight-this.scrollerHeight+"px":"0px";this.menu.style.marginTop=Math.round(parseInt(this.scroller.style.marginTop)*this.delta*-1)+"px";return false};this.blockEvent=function(a){if(!a)a=window.event;if(a.stopPropagation)a.stopPropagation();else a.cancelBubble=true;if(a.preventDefault)a.preventDefault();else a.returnValue=false};this.wheel=function(a){var c=0;if(!a)a=window.event;if(a.wheelDelta)c=-a.wheelDelta/120;else if(a.detail)c=a.detail/3;if(c){var f=parseInt(this.scroller.style.marginTop); this.setPosition(c*this.step+f)}a.preventDefault&&a.preventDefault();a.returnValue=false;this.blockEvent(a)};this.fixForBrowsers=function(a){if(!a)a=window.event;if(a.stopPropagation)a.stopPropagation();else a.cancelBubble=true;if(a.preventDefault)a.preventDefault();else a.returnValue=false};b=function(){};if(this.scrollEnabled==true){var d=this;this.scrollerBar.onmousedown=function(a){d.drag(a)};this.scrollerBar.onmousemove=function(a){d.move(a)};this.scrollerBar.onmouseup=function(a){d.drop(a)}; this.scrollerBar.onclick=function(a){d.jump(a)};if(this.content.addEventListener)this.content.addEventListener("DOMMouseScroll",b=function(a){d.wheel(a)},false);this.content.onmousewheel=function(a){d.wheel(a)}}else{this.content.removeEventListener&&this.content.removeEventListener("DOMMouseScroll",b,false);this.content.onmousewheel=null}};