1!function(b){var c=!1,d=!1,e=5e3,f=2e3,g=0,h=function(){var a=document.getElementsByTagName("script"),a=a[a.length-1].src.split("?")[0];return 0<a.split("/").length?a.split("/").slice(0,-1).join("/")+"/":""}();Array.prototype.forEach||(Array.prototype.forEach=function(a,b){for(var c=0,d=this.length;c<d;++c)a.call(b,this[c],c,this)});var i=window.requestAnimationFrame||!1,j=window.cancelAnimationFrame||!1;["ms","moz","webkit","o"].forEach(function(a){i||(i=window[a+"RequestAnimationFrame"]),j||(j=window[a+"CancelAnimationFrame"]||window[a+"CancelRequestAnimationFrame"])});var k=window.MutationObserver||window.WebKitMutationObserver||!1,l={zindex:"auto",cursoropacitymin:0,cursoropacitymax:1,cursorcolor:"#424242",cursorwidth:"5px",cursorborder:"1px solid #fff",cursorborderradius:"5px",scrollspeed:60,mousescrollstep:24,touchbehavior:!1,hwacceleration:!0,usetransition:!0,boxzoom:!1,dblclickzoom:!0,gesturezoom:!0,grabcursorenabled:!0,autohidemode:!0,background:"",iframeautoresize:!0,cursorminheight:32,preservenativescrolling:!0,railoffset:!1,bouncescroll:!0,spacebarenabled:!0,railpadding:{top:0,right:0,left:0,bottom:0},disableoutline:!0,horizrailenabled:!0,railalign:"right",railvalign:"bottom",enabletranslate3d:!0,enablemousewheel:!0,enablekeyboard:!0,smoothscroll:!0,sensitiverail:!0,enablemouselockapi:!0,cursorfixedheight:!1,directionlockdeadzone:6,hidecursordelay:400,nativeparentscrolling:!0,enablescrollonselection:!0,overflowx:!0,overflowy:!0,cursordragspeed:.3,rtlmode:!1,cursordragontouch:!1},m=!1,n=function(){if(m)return m;var a=document.createElement("DIV"),b={haspointerlock:"pointerLockElement"in document||"mozPointerLockElement"in document||"webkitPointerLockElement"in document};b.isopera="opera"in window,b.isopera12=b.isopera&&"getUserMedia"in navigator,b.isie="all"in document&&"attachEvent"in a&&!b.isopera,b.isieold=b.isie&&!("msInterpolationMode"in a.style),b.isie7=b.isie&&!b.isieold&&(!("documentMode"in document)||7==document.documentMode),b.isie8=b.isie&&"documentMode"in document&&8==document.documentMode,b.isie9=b.isie&&"performance"in window&&9<=document.documentMode,b.isie10=b.isie&&"performance"in window&&10<=document.documentMode,b.isie9mobile=/iemobile.9/i.test(navigator.userAgent),b.isie9mobile&&(b.isie9=!1),b.isie7mobile=!b.isie9mobile&&b.isie7&&/iemobile/i.test(navigator.userAgent),b.ismozilla="MozAppearance"in a.style,b.iswebkit="WebkitAppearance"in a.style,b.ischrome="chrome"in window,b.ischrome22=b.ischrome&&b.haspointerlock,b.ischrome26=b.ischrome&&"transition"in a.style,b.cantouch="ontouchstart"in document.documentElement||"ontouchstart"in window,b.hasmstouch=window.navigator.msPointerEnabled||!1,b.ismac=/^mac$/i.test(navigator.platform),b.isios=b.cantouch&&/iphone|ipad|ipod/i.test(navigator.platform),b.isios4=b.isios&&!("seal"in Object),b.isandroid=/android/i.test(navigator.userAgent),b.trstyle=!1,b.hastransform=!1,b.hastranslate3d=!1,b.transitionstyle=!1,b.hastransition=!1,b.transitionend=!1;for(var c=["transform","msTransform","webkitTransform","MozTransform","OTransform"],d=0;d<c.length;d++)if(void 0!==a.style[c[d]]){b.trstyle=c[d];break}b.hastransform=0!=b.trstyle,b.hastransform&&(a.style[b.trstyle]="translate3d(1px,2px,3px)",b.hastranslate3d=/translate3d/.test(a.style[b.trstyle])),b.transitionstyle=!1,b.prefixstyle="",b.transitionend=!1;for(var c="transition webkitTransition MozTransition OTransition OTransition msTransition KhtmlTransition".split(" "),e=" -webkit- -moz- -o- -o -ms- -khtml-".split(" "),f="transitionend webkitTransitionEnd transitionend otransitionend oTransitionEnd msTransitionEnd KhtmlTransitionEnd".split(" "),d=0;d<c.length;d++)if(c[d]in a.style){b.transitionstyle=c[d],b.prefixstyle=e[d],b.transitionend=f[d];break}b.ischrome26&&(b.prefixstyle=e[1]),b.hastransition=b.transitionstyle;a:{for(c=["-moz-grab","-webkit-grab","grab"],(b.ischrome&&!b.ischrome22||b.isie)&&(c=[]),d=0;d<c.length;d++)if(e=c[d],a.style.cursor=e,a.style.cursor==e){c=e;break a}c="url(http://www.google.com/intl/en_ALL/mapfiles/openhand.cur),n-resize"}return b.cursorgrabvalue=c,b.hasmousecapture="setCapture"in a,b.hasMutationObserver=!1!==k,m=b},o=function(a,m){function o(){var a=t.win;if("zIndex"in a)return a.zIndex();for(;0<a.length&&9!=a[0].nodeType;){var b=a.css("zIndex");if(!isNaN(b)&&0!=b)return parseInt(b);a=a.parent()}return!1}function q(a,b,c){return b=a.css(b),a=parseFloat(b),isNaN(a)?(a=x[b]||0,c=3==a?c?t.win.outerHeight()-t.
1win.innerHeight():t.win.outerWidth()-t.win.innerWidth():1,t.isie8&&a&&(a+=1),c?a:0):a}function r(a,b,c,d){t._bind(a,b,function(d){d=d||window.event;var e={original:d,target:d.target||d.srcElement,type:"wheel",deltaMode:"MozMousePixelScroll"==d.type?0:1,deltaX:0,deltaZ:0,preventDefault:function(){return d.preventDefault?d.preventDefault():d.returnValue=!1,!1},stopImmediatePropagation:function(){d.stopImmediatePropagation?d.stopImmediatePropagation():d.cancelBubble=!0}};return"mousewheel"==b?(e.deltaY=-.025*d.wheelDelta,d.wheelDeltaX&&(e.deltaX=-.025*d.wheelDeltaX)):e.deltaY=d.detail,c.call(a,e)},d)}function s(a,b,c){var d,e;if(0==a.deltaMode?(d=-Math.floor(a.deltaX*(t.opt.mousescrollstep/54)),e=-Math.floor(a.deltaY*(t.opt.mousescrollstep/54))):1==a.deltaMode&&(d=-Math.floor(a.deltaX*t.opt.mousescrollstep),e=-Math.floor(a.deltaY*t.opt.mousescrollstep)),b&&0==d&&e&&(d=e,e=0),d&&(t.scrollmom&&t.scrollmom.stop(),t.lastdeltax+=d,t.debounced("mousewheelx",function(){var a=t.lastdeltax;t.lastdeltax=0,t.rail.drag||t.doScrollLeftBy(a)},120)),e){if(t.opt.nativeparentscrolling&&c&&!t.ispage&&!t.zoomactive)if(0>e){if(t.getScrollTop()>=t.page.maxh)return!0}else if(0>=t.getScrollTop())return!0;t.scrollmom&&t.scrollmom.stop(),t.lastdeltay+=e,t.debounced("mousewheely",function(){var a=t.lastdeltay;t.lastdeltay=0,t.rail.drag||t.doScrollBy(a)},120)}return a.stopImmediatePropagation(),a.preventDefault()}var t=this;if(this.version="3.4.0",this.name="nicescroll",this.me=m,this.opt={doc:b("body"),win:!1},b.extend(this.opt,l),this.opt.snapbackspeed=80,a)for(var u in t.opt)void 0!==a[u]&&(t.opt[u]=a[u]);this.iddoc=(this.doc=t.opt.doc)&&this.doc[0]?this.doc[0].id||"":"",this.ispage=/BODY|HTML/.test(t.opt.win?t.opt.win[0].nodeName:this.doc[0].nodeName),this.haswrapper=!1!==t.opt.win,this.win=t.opt.win||(this.ispage?b(window):this.doc),this.docscroll=this.ispage&&!this.haswrapper?b(window):this.win,this.body=b("body"),this.iframe=this.isfixed=this.viewport=!1,this.isiframe="IFRAME"==this.doc[0].nodeName&&"IFRAME"==this.win[0].nodeName,this.istextarea="TEXTAREA"==this.win[0].nodeName,this.forcescreen=!1,this.canshowonmouseevent="scroll"!=t.opt.autohidemode,this.page=this.view=this.onzoomout=this.onzoomin=this.onscrollcancel=this.onscrollend=this.onscrollstart=this.onclick=this.ongesturezoom=this.onkeypress=this.onmousewheel=this.onmousemove=this.onmouseup=this.onmousedown=!1,this.scroll={x:0,y:0},this.scrollratio={x:0,y:0},this.cursorheight=20,this.scrollvaluemax=0,this.observerremover=this.observer=this.scrollmom=this.scrollrunning=this.checkrtlmode=!1;do{this.id="ascrail"+f++}while(document.getElementById(this.id));this.hasmousefocus=this.hasfocus=this.zoomactive=this.zoom=this.selectiondrag=this.cursorfreezed=this.cursor=this.rail=!1,this.visibility=!0,this.hidden=this.locked=!1,this.cursoractive=!0,this.overflowx=t.opt.overflowx,this.overflowy=t.opt.overflowy,this.nativescrollingarea=!1,this.checkarea=0,this.events=[],this.saved={},this.delaylist={},this.synclist={},this.lastdeltay=this.lastdeltax=0,this.detected=n();var v=b.extend({},this.detected);if(this.ishwscroll=(this.canhwscroll=v.hastransform&&t.opt.hwacceleration)&&t.haswrapper,this.istouchcapable=!1,v.cantouch&&v.ischrome&&!v.isios&&!v.isandroid&&(this.istouchcapable=!0,v.cantouch=!1),v.cantouch&&v.ismozilla&&!v.isios&&(this.istouchcapable=!0,v.cantouch=!1),t.opt.enablemouselockapi||(v.hasmousecapture=!1,v.haspointerlock=!1),this.delayed=function(a,b,c,d){var e=t.delaylist[a],f=(new Date).getTime();if(!d&&e&&e.tt)return!1;e&&e.tt&&clearTimeout(e.tt),e&&e.last+c>f&&!e.tt?t.delaylist[a]={last:f+c,tt:setTimeout(function(){t.delaylist[a].tt=0,b.call()},c)}:e&&e.tt||(t.delaylist[a]={last:f,tt:0},setTimeout(function(){b.call()},0))},this.debounced=function(a,b,c){var d=t.delaylist[a];(new Date).getTime(),t.delaylist[a]=b,d||setTimeout(function(){var b=t.delaylist[a];t.delaylist[a]=!1,b.call()},c)},this.synched=function(a,b){return t.synclist[a]=b,function(){t.onsync||(i(function(){t.onsync=!1;for(a in t.synclist){var b=t.synclist[a];b&&b.call(t),t.synclist[a]=!1}}),t.onsync=!0)}(),a},this.unsynched=function(a){t.synclist[a]&&(t.synclist[a]=!1)},this.css=function(a,b){for(var c in b)t.saved.css.push([a,c,a.css(c)]),a.css(c,b[c])},this.scrollTop=function(a){return void 0===a?t.getScrollTop():t.setScrollTop(a)},this.scrollLeft=function(a){return void 0===a?t.getScrollLeft():t.setScrollLeft(a)},BezierClass=function(a,b,c,d,e,f,g){this.st=a,this.ed=b,this.spd=c,this.p1=d||0,this.p2=e||1,this.p3=f||0,this.p4=g||1,this.ts=(new Date).getTime(),this.df=this.ed-this.st},BezierClass.prototype={B2:function(a){return 3*a*a*(1-a)},B3:function(a){return 3*a*(1-a)*(1-a)},B4:function(a){return(1-a)*(1-a)*(1-a)},getNow:function(){var a=1-((new Date).getTime()-this.ts)/this.spd,b=this.B2(a)+this.B3(a)+this.B4(a);return 0>a?this.ed:this.st+Math.round(this.df*b)},update:function(a,b){return this.st=this.getNow(),this.ed=a,this.spd=b,this.ts=(new Date).getTime(),this.df=this.ed-this.st,this}},this.ishwscroll){this.doc.translate={x:0,y:0,tx:"0px",ty:"0px"},v.hastranslate3d&&v.isios&&this.doc.css("-webkit-backface-visibility","hidden");var w=function(){var a=t.doc.css(v.trstyle);return!(!a||"matrix"!=a.substr(0,6))&&a.replace(/^.*\((.*)\)$/g,"$1").replace(/px/g,"").split(/, +/)};
1this.getScrollTop=function(a){if(!a){if(a=w())return 16==a.length?-a[13]:-a[5];if(t.timerscroll&&t.timerscroll.bz)return t.timerscroll.bz.getNow()}return t.doc.translate.y},this.getScrollLeft=function(a){if(!a){if(a=w())return 16==a.length?-a[12]:-a[4];if(t.timerscroll&&t.timerscroll.bh)return t.timerscroll.bh.getNow()}return t.doc.translate.x},this.notifyScrollEvent=document.createEvent?function(a){var b=document.createEvent("UIEvents");b.initUIEvent("scroll",!1,!0,window,1),a.dispatchEvent(b)}:document.fireEvent?function(a){var b=document.createEventObject();a.fireEvent("onscroll"),b.cancelBubble=!0}:function(a,b){},v.hastranslate3d&&t.opt.enabletranslate3d?(this.setScrollTop=function(a,b){t.doc.translate.y=a,t.doc.translate.ty=-1*a+"px",t.doc.css(v.trstyle,"translate3d("+t.doc.translate.tx+","+t.doc.translate.ty+",0px)"),b||t.notifyScrollEvent(t.win[0])},this.setScrollLeft=function(a,b){t.doc.translate.x=a,t.doc.translate.tx=-1*a+"px",t.doc.css(v.trstyle,"translate3d("+t.doc.translate.tx+","+t.doc.translate.ty+",0px)"),b||t.notifyScrollEvent(t.win[0])}):(this.setScrollTop=function(a,b){t.doc.translate.y=a,t.doc.translate.ty=-1*a+"px",t.doc.css(v.trstyle,"translate("+t.doc.translate.tx+","+t.doc.translate.ty+")"),b||t.notifyScrollEvent(t.win[0])},this.setScrollLeft=function(a,b){t.doc.translate.x=a,t.doc.translate.tx=-1*a+"px",t.doc.css(v.trstyle,"translate("+t.doc.translate.tx+","+t.doc.translate.ty+")"),b||t.notifyScrollEvent(t.win[0])})}else this.getScrollTop=function(){return t.docscroll.scrollTop()},this.setScrollTop=function(a){return t.docscroll.scrollTop(a)},this.getScrollLeft=function(){return t.docscroll.scrollLeft()},this.setScrollLeft=function(a){return t.docscroll.scrollLeft(a)};this.getTarget=function(a){return!!a&&(a.target?a.target:!!a.srcElement&&a.srcElement)},this.hasParent=function(a,b){if(!a)return!1;for(var c=a.target||a.srcElement||a||!1;c&&c.id!=b;)c=c.parentNode||!1;return!1!==c};var x={thin:1,medium:3,thick:5};this.getOffset=function(){if(t.isfixed)return{top:parseFloat(t.win.css("top")),left:parseFloat(t.win.css("left"))};if(!t.viewport)return t.win.offset();var a=t.win.offset(),b=t.viewport.offset();return{top:a.top-b.top+t.viewport.scrollTop(),left:a.left-b.left+t.viewport.scrollLeft()}},this.updateScrollBar=function(a){if(t.ishwscroll)t.rail.css({height:t.win.innerHeight()}),t.railh&&t.railh.css({width:t.win.innerWidth()});else{var b=t.getOffset(),c=b.top,d=b.left,c=c+q(t.win,"border-top-width",!0);t.win.outerWidth(),t.win.innerWidth();var d=d+(t.rail.align?t.win.outerWidth()-q(t.win,"border-right-width")-t.rail.width:q(t.win,"border-left-width")),e=t.opt.railoffset;e&&(e.top&&(c+=e.top),t.rail.align&&e.left&&(d+=e.left)),t.locked||t.rail.css({top:c,left:d,height:a?a.h:t.win.innerHeight()}),t.zoom&&t.zoom.css({top:c+1,left:1==t.rail.align?d-20:d+t.rail.width+4}),t.railh&&!t.locked&&(c=b.top,d=b.left,a=t.railh.align?c+q(t.win,"border-top-width",!0)+t.win.innerHeight()-t.railh.height:c+q(t.win,"border-top-width",!0),d+=q(t.win,"border-left-width"),t.railh.css({top:a,left:d,width:t.railh.width}))}},this.doRailClick=function(a,b,c){var d;t.locked||(t.cancelEvent(a),b?(b=c?t.doScrollLeft:t.doScrollTop,d=c?(a.pageX-t.railh.offset().left-t.cursorwidth/2)*t.scrollratio.x:(a.pageY-t.rail.offset().top-t.cursorheight/2)*t.scrollratio.y,b(d)):(b=c?t.doScrollLeftBy:t.doScrollBy,d=c?t.scroll.x:t.scroll.y,a=c?a.pageX-t.railh.offset().left:a.pageY-t.rail.offset().top,c=c?t.view.w:t.view.h,b(d>=a?c:-c)))},t.hasanimationframe=i,t.hascancelanimationframe=j,t.hasanimationframe?t.hascancelanimationframe||(j=function(){t.cancelAnimationFrame=!0}):(i=function(a){return setTimeout(a,15-Math.floor(+new Date/1e3)%16)},j=clearInterval),this.init=function(){if(t.saved.css=[],v.isie7mobile)return!0;if(v.hasmstouch&&t.css(t.ispage?b("html"):t.win,{"-ms-touch-action":"none"}),t.zindex="auto",t.zindex=t.ispage||"auto"!=t.opt.zindex?t.opt.zindex:o()||"auto",!t.ispage&&"auto"!=t.zindex&&t.zindex>g&&(g=t.zindex),t.isie&&0==t.zindex&&"auto"==t.opt.zindex&&(t.zindex="auto"),!t.ispage||!v.cantouch&&!v.isieold&&!v.isie9mobile){var a=t.docscroll;t.ispage&&(a=t.haswrapper?t.win:t.doc),v.isie9mobile||t.css(a,{"overflow-y":"hidden"}),t.ispage&&v.isie7&&("BODY"==t.doc[0].nodeName?t.css(b("html"),{"overflow-y":"hidden"}):"HTML"==t.doc[0].nodeName&&t.css(b("body"),{"overflow-y":"hidden"})),v.isios&&!t.ispage&&!t.haswrapper&&t.css(b("body"),{"-webkit-overflow-scrolling":"touch"});var f=b(document.createElement("div"));f.css({position:"relative",top:0,float:"right",width:t.opt.cursorwidth,height:"0px","background-color":t.opt.cursorcolor,border:t.opt.cursorborder,"background-clip":"padding-box","-webkit-border-radius":t.opt.cursorborderradiu
1s,"-moz-border-radius":t.opt.cursorborderradius,"border-radius":t.opt.cursorborderradius}),f.hborder=parseFloat(f.outerHeight()-f.innerHeight()),t.cursor=f;var i=b(document.createElement("div"));i.attr("id",t.id),i.addClass("nicescroll-rails");var j,l,n,m=["left","right"];for(n in m)l=m[n],(j=t.opt.railpadding[l])?i.css("padding-"+l,j+"px"):t.opt.railpadding[l]=0;if(i.append(f),i.width=Math.max(parseFloat(t.opt.cursorwidth),f.outerWidth())+t.opt.railpadding.left+t.opt.railpadding.right,i.css({width:i.width+"px",zIndex:t.zindex,background:t.opt.background,cursor:"default"}),i.visibility=!0,i.scrollable=!0,i.align="left"==t.opt.railalign?0:1,t.rail=i,f=t.rail.drag=!1,t.opt.boxzoom&&!t.ispage&&!v.isieold&&(f=document.createElement("div"),t.bind(f,"click",t.doZoom),t.zoom=b(f),t.zoom.css({cursor:"pointer","z-index":t.zindex,backgroundImage:"url("+h+"zoomico.png)",height:18,width:18,backgroundPosition:"0px 0px"}),t.opt.dblclickzoom&&t.bind(t.win,"dblclick",t.doZoom),v.cantouch&&t.opt.gesturezoom&&(t.ongesturezoom=function(a){return 1.5<a.scale&&t.doZoomIn(a),.8>a.scale&&t.doZoomOut(a),t.cancelEvent(a)},t.bind(t.win,"gestureend",t.ongesturezoom))),t.railh=!1,t.opt.horizrailenabled){t.css(a,{"overflow-x":"hidden"}),f=b(document.createElement("div")),f.css({position:"relative",top:0,height:t.opt.cursorwidth,width:"0px","background-color":t.opt.cursorcolor,border:t.opt.cursorborder,"background-clip":"padding-box","-webkit-border-radius":t.opt.cursorborderradius,"-moz-border-radius":t.opt.cursorborderradius,"border-radius":t.opt.cursorborderradius}),f.wborder=parseFloat(f.outerWidth()-f.innerWidth()),t.cursorh=f;var q=b(document.createElement("div"));q.attr("id",t.id+"-hr"),q.addClass("nicescroll-rails"),q.height=Math.max(parseFloat(t.opt.cursorwidth),f.outerHeight()),q.css({height:q.height+"px",zIndex:t.zindex,background:t.opt.background}),q.append(f),q.visibility=!0,q.scrollable=!0,q.align="top"==t.opt.railvalign?0:1,t.railh=q,t.railh.drag=!1}if(t.ispage?(i.css({position:"fixed",top:"0px",height:"100%"}),i.align?i.css({right:"0px"}):i.css({left:"0px"}),t.body.append(i),t.railh&&(q.css({position:"fixed",left:"0px",width:"100%"}),q.align?q.css({bottom:"0px"}):q.css({top:"0px"}),t.body.append(q))):(t.ishwscroll?("static"==t.win.css("position")&&t.css(t.win,{position:"relative"}),a="HTML"==t.win[0].nodeName?t.body:t.win,t.zoom&&(t.zoom.css({position:"absolute",top:1,right:0,"margin-right":i.width+4}),a.append(t.zoom)),i.css({position:"absolute",top:0}),i.align?i.css({right:0}):i.css({left:0}),a.append(i),q&&(q.css({position:"absolute",left:0,bottom:0}),q.align?q.css({bottom:0}):q.css({top:0}),a.append(q))):(t.isfixed="fixed"==t.win.css("position"),a=t.isfixed?"fixed":"absolute",t.isfixed||(t.viewport=t.getViewport(t.win[0])),t.viewport&&(t.body=t.viewport,0==/relative|absolute/.test(t.viewport.css("position"))&&t.css(t.viewport,{position:"relative"})),i.css({position:a}),t.zoom&&t.zoom.css({position:a}),t.updateScrollBar(),t.body.append(i),t.zoom&&t.body.append(t.zoom),t.railh&&(q.css({position:a}),t.body.append(q))),v.isios&&t.css(t.win,{"-webkit-tap-highlight-color":"rgba(0,0,0,0)","-webkit-touch-callout":"none"}),v.isie&&t.opt.disableoutline&&t.win.attr("hideFocus","true"),v.iswebkit&&t.opt.disableoutline&&t.win.css({outline:"none"})),!1===t.opt.autohidemode?(t.autohidedom=!1,t.rail.css({opacity:t.opt.cursoropacitymax}),t.railh&&t.railh.css({opacity:t.opt.cursoropacitymax})):!0===t.opt.autohidemode?(t.autohidedom=b().add(t.rail),v.isie8&&(t.autohidedom=t.autohidedom.add(t.cursor)),t.railh&&(t.autohidedom=t.autohidedom.add(t.railh)),t.railh&&v.isie8&&(t.autohidedom=t.autohidedom.add(t.cursorh))):"scroll"==t.opt.autohidemode?(t.autohidedom=b().add(t.rail),t.railh&&(t.autohidedom=t.autohidedom.add(t.railh))):"cursor"==t.opt.autohidemode?(t.autohidedom=b().add(t.cursor),t.railh&&(t.autohidedom=t.autohidedom.add(t.cursorh))):"hidden"==t.opt.autohidemode&&(t.autohidedom=!1,t.hide(),t.locked=!1),v.isie9mobile)t.scrollmom=new p(t),t.onmangotouch=function(a){a=t.getScrollTop();var b=t.getScrollLeft();if(a==t.scrollmom.lastscrolly&&b==t.scrollmom.lastscrollx)return!0;var c=a-t.mangotouch.sy,d=b-t.mangotouch.sx;if(0!=Math.round(Math.sqrt(Math.pow(d,2)+Math.pow(c,2)))){var e=0>c?-1:1,f=0>d?-1:1,g=+new Date;t.mangotouch.lazy&&clearTimeout(t.mangotouch.lazy),80<g-t.mangotouch.tm||t.mangotouch.dry!=e||t.mangotouch.drx!=f?(t.scrollmom.stop(),t.scrollmom.reset(b,a),t.mangotouch.sy=a,t.mangotouch.ly=a,t.mangotouch.sx=b,t.mangotouch.lx=b,t.mangotouch.dry=e,t.mangotouch.drx=f,t.mangotouch.tm=g):(t.scrollmom.stop(),t.scrollmom.update(t.mangotouch.sx-d,t.mangotouch.sy-c),t.mangotouch.tm=g,c=Math.max(Math.abs(t.mangotouch.ly-a),Math.abs(t.mangotouch.lx-b)),t.mangotouch.ly=a,t.mangotouch.lx=b,2<c&&(t.mangotouch.lazy=setTimeout(function(){t.mangotouch.lazy=!1,t.mangotouch.dry=0,t.mangotouch.drx=0,t.mangotouch.tm=0,t.scrollmom.doMomentum(30)},100)))}},i=t.getScrollTop(),q=t.getScrollLeft(),t.mangotouch={sy:i,ly:i,dry:0,sx:q,lx:q,drx:0,lazy:!1,tm:0},t.bind(t.docscroll,"scroll",t.onmangotouch);else{if(v.cantouch||t.istouchcapable||t.opt.touchbehavior||v.hasmstouch){t.scrollmom=new p(t),t.ontouchstart=function(a){if
1(a.pointerType&&2!=a.pointerType)return!1;if(!t.locked){if(v.hasmstouch)for(var c=!!a.target&&a.target;c;){var d=b(c).getNiceScroll();if(0<d.length&&d[0].me==t.me)break;if(0<d.length)return!1;if("DIV"==c.nodeName&&c.id==t.id)break;c=!!c.parentNode&&c.parentNode}if(t.cancelScroll(),(c=t.getTarget(a))&&/INPUT/i.test(c.nodeName)&&/range/i.test(c.type))return t.stopPropagation(a);if(!("clientX"in a)&&"changedTouches"in a&&(a.clientX=a.changedTouches[0].clientX,a.clientY=a.changedTouches[0].clientY),t.forcescreen&&(d=a,a={original:a.original?a.original:a},a.clientX=d.screenX,a.clientY=d.screenY),t.rail.drag={x:a.clientX,y:a.clientY,sx:t.scroll.x,sy:t.scroll.y,st:t.getScrollTop(),sl:t.getScrollLeft(),pt:2,dl:!1},t.ispage||!t.opt.directionlockdeadzone)t.rail.drag.dl="f";else{var d=b(window).width(),e=b(window).height(),f=Math.max(document.body.scrollWidth,document.documentElement.scrollWidth),g=Math.max(document.body.scrollHeight,document.documentElement.scrollHeight),e=Math.max(0,g-e),d=Math.max(0,f-d);t.rail.drag.ck=!t.rail.scrollable&&t.railh.scrollable?0<e&&"v":!(!t.rail.scrollable||t.railh.scrollable)&&(0<d&&"h"),t.rail.drag.ck||(t.rail.drag.dl="f")}if(t.opt.touchbehavior&&t.isiframe&&v.isie&&(d=t.win.position(),t.rail.drag.x+=d.left,t.rail.drag.y+=d.top),t.hasmoving=!1,t.lastmouseup=!1,t.scrollmom.reset(a.clientX,a.clientY),!v.cantouch&&!this.istouchcapable&&!v.hasmstouch){if(!c||!/INPUT|SELECT|TEXTAREA/i.test(c.nodeName))return!t.ispage&&v.hasmousecapture&&c.setCapture(),t.cancelEvent(a);/SUBMIT|CANCEL|BUTTON/i.test(b(c).attr("type"))&&(pc={tg:c,click:!1},t.preventclick=pc)}}},t.ontouchend=function(a){return(!a.pointerType||2==a.pointerType)&&(t.rail.drag&&2==t.rail.drag.pt&&(t.scrollmom.doMomentum(),t.rail.drag=!1,t.hasmoving&&(t.hasmoving=!1,t.lastmouseup=!0,t.hideCursor(),v.hasmousecapture&&document.releaseCapture(),!v.cantouch))?t.cancelEvent(a):void 0)};var r=t.opt.touchbehavior&&t.isiframe&&!v.hasmousecapture;t.ontouchmove=function(a,c){if(a.pointerType&&2!=a.pointerType)return!1;if(t.rail.drag&&2==t.rail.drag.pt){if(v.cantouch&&void 0===a.original)return!0;if(t.hasmoving=!0,t.preventclick&&!t.preventclick.click&&(t.preventclick.click=t.preventclick.tg.onclick||!1,t.preventclick.tg.onclick=t.onpreventclick),a=b.extend({original:a},a),"changedTouches"in a&&(a.clientX=a.changedTouches[0].clientX,a.clientY=a.changedTouches[0].clientY),t.forcescreen){var d=a;a={original:a.original?a.original:a},a.clientX=d.screenX,a.clientY=d.screenY}if(d=ofy=0,r&&!c){var e=t.win.position(),d=-e.left;ofy=-e.top}var f=a.clientY+ofy,e=f-t.rail.drag.y,g=a.clientX+d,h=g-t.rail.drag.x,i=t.rail.drag.st-e;if(t.ishwscroll&&t.opt.bouncescroll?0>i?i=Math.round(i/2):i>t.page.maxh&&(i=t.page.maxh+Math.round((i-t.page.maxh)/2)):(0>i&&(f=i=0),i>t.page.maxh&&(i=t.page.maxh,f=0)),t.railh&&t.railh.scrollable){var j=t.rail.drag.sl-h;t.ishwscroll&&t.opt.bouncescroll?0>j?j=Math.round(j/2):j>t.page.maxw&&(j=t.page.maxw+Math.round((j-t.page.maxw)/2)):(0>j&&(g=j=0),j>t.page.maxw&&(j=t.page.maxw,g=0))}if(d=!1,t.rail.drag.dl)d=!0,"v"==t.rail.drag.dl?j=t.rail.drag.sl:"h"==t.rail.drag.dl&&(i=t.rail.drag.st);else{var e=Math.abs(e),h=Math.abs(h),k=t.opt.directionlockdeadzone;if("v"==t.rail.drag.ck){if(e>k&&h<=.3*e)return t.rail.drag=!1,!0;h>k&&(t.rail.drag.dl="f",b("body").scrollTop(b("body").scrollTop()))}else if("h"==t.rail.drag.ck){if(h>k&&e<=.3*az)return t.rail.drag=!1,!0;e>k&&(t.rail.drag.dl="f",b("body").scrollLeft(b("body").scrollLeft()))}}if(t.synched("touchmove",function(){t.rail.drag&&2==t.rail.drag.pt&&(t.prepareTransition&&t.prepareTransition(0),t.rail.scrollable&&t.setScrollTop(i),t.scrollmom.update(g,f),t.railh&&t.railh.scrollable?(t.setScrollLeft(j),t.showCursor(i,j)):t.showCursor(i),v.isie10&&document.selection.clear())}),v.ischrome&&t.istouchcapable&&(d=!1),d)return t.cancelEvent(a)}}}if(t.onmousedown=function(a,b){if(!t.rail.drag||1==t.rail.drag.pt){if(t.locked)return t.cancelEvent(a);t.cancelScroll(),t.rail.drag={x:a.clientX,y:a.clientY,sx:t.scroll.x,sy:t.scroll.y,pt:1,hr:!!b};var c=t.getTarget(a);return!t.ispage&&v.hasmousecapture&&c.setCapture(),t.isiframe&&!v.hasmousecapture&&(t.saved.csspointerevents=t.doc.
1css("pointer-events"),t.css(t.doc,{"pointer-events":"none"})),t.cancelEvent(a)}},t.onmouseup=function(a){if(t.rail.drag&&(v.hasmousecapture&&document.releaseCapture(),t.isiframe&&!v.hasmousecapture&&t.doc.css("pointer-events",t.saved.csspointerevents),1==t.rail.drag.pt))return t.rail.drag=!1,t.cancelEvent(a)},t.onmousemove=function(a){if(t.rail.drag&&1==t.rail.drag.pt){if(v.ischrome&&0==a.which)return t.onmouseup(a);if(t.cursorfreezed=!0,t.rail.drag.hr){t.scroll.x=t.rail.drag.sx+(a.clientX-t.rail.drag.x),0>t.scroll.x&&(t.scroll.x=0);var b=t.scrollvaluemaxw;t.scroll.x>b&&(t.scroll.x=b)}else t.scroll.y=t.rail.drag.sy+(a.clientY-t.rail.drag.y),0>t.scroll.y&&(t.scroll.y=0),b=t.scrollvaluemax,t.scroll.y>b&&(t.scroll.y=b);return t.synched("mousemove",function(){t.rail.drag&&1==t.rail.drag.pt&&(t.showCursor(),t.rail.drag.hr?t.doScrollLeft(Math.round(t.scroll.x*t.scrollratio.x),t.opt.cursordragspeed):t.doScrollTop(Math.round(t.scroll.y*t.scrollratio.y),t.opt.cursordragspeed))}),t.cancelEvent(a)}},v.cantouch||t.opt.touchbehavior)t.onpreventclick=function(a){if(t.preventclick)return t.preventclick.tg.onclick=t.preventclick.click,t.preventclick=!1,t.cancelEvent(a)},t.bind(t.win,"mousedown",t.ontouchstart),t.onclick=!v.isios&&function(a){return!t.lastmouseup||(t.lastmouseup=!1,t.cancelEvent(a))},t.opt.grabcursorenabled&&v.cursorgrabvalue&&(t.css(t.ispage?t.doc:t.win,{cursor:v.cursorgrabvalue}),t.css(t.rail,{cursor:v.cursorgrabvalue}));else{var s=function(a){if(t.selectiondrag){if(a){var b=t.win.outerHeight();a=a.pageY-t.selectiondrag.top,0<a&&a<b&&(a=0),a>=b&&(a-=b),t.selectiondrag.df=a}0!=t.selectiondrag.df&&(t.doScrollBy(2*-Math.floor(t.selectiondrag.df/6)),t.debounced("doselectionscroll",function(){s()},50))}};t.hasTextSelected="getSelection"in document?function(){return 0<document.getSelection().rangeCount}:"selection"in document?function(){return"None"!=document.selection.type}:function(){return!1},t.onselectionstart=function(a){t.ispage||(t.selectiondrag=t.win.offset())},t.onselectionend=function(a){t.selectiondrag=!1},t.onselectiondrag=function(a){t.selectiondrag&&t.hasTextSelected()&&t.debounced("selectionscroll",function(){s(a)},250)}}v.hasmstouch&&(t.css(t.rail,{"-ms-touch-action":"none"}),t.css(t.cursor,{"-ms-touch-action":"none"}),t.bind(t.win,"MSPointerDown",t.ontouchstart),t.bind(document,"MSPointerUp",t.ontouchend),t.bind(document,"MSPointerMove",t.ontouchmove),t.bind(t.cursor,"MSGestureHold",function(a){a.preventDefault()}),t.bind(t.cursor,"contextmenu",function(a){a.preventDefault()})),this.istouchcapable&&(t.bind(t.win,"touchstart",t.ontouchstart),t.bind(document,"touchend",t.ontouchend),t.bind(document,"touchcancel",t.ontouchend),t.bind(document,"touchmove",t.ontouchmove)),t.bind(t.cursor,"mousedown",t.onmousedown),t.bind(t.cursor,"mouseup",t.onmouseup),t.railh&&(t.bind(t.cursorh,"mousedown",function(a){t.onmousedown(a,!0)}),t.bind(t.cursorh,"mouseup",function(a){if(!t.rail.drag||2!=t.rail.drag.pt)return t.rail.drag=!1,t.hasmoving=!1,t.hideCursor(),v.hasmousecapture&&document.releaseCapture(),t.cancelEvent(a)})),(t.opt.cursordragontouch||!v.cantouch&&!t.opt.touchbehavior)&&(t.rail.css({cursor:"default"}),t.railh&&t.railh.css({cursor:"default"}),t.jqbind(t.rail,"mouseenter",function(){t.canshowonmouseevent&&t.showCursor(),t.rail.active=!0}),t.jqbind(t.rail,"mouseleave",function(){t.rail.active=!1,t.rail.drag||t.hideCursor()}),t.opt.sensitiverail&&(t.bind(t.rail,"click",function(a){t.doRailClick(a,!1,!1)}),t.bind(t.rail,"dblclick",function(a){t.doRailClick(a,!0,!1)}),t.bind(t.cursor,"click",function(a){t.cancelEvent(a)}),t.bind(t.cursor,"dblclick",function(a){t.cancelEvent(a)})),t.railh&&(t.jqbind(t.railh,"mouseenter",function(){t.canshowonmouseevent&&t.showCursor(),t.rail.active=!0}),t.jqbind(t.railh,"mouseleave",function(){t.rail.active=!1,t.rail.drag||t.hideCursor()}),t.opt.sensitiverail&&(t.bind(t.railh,"click",function(a){t.doRailClick(a,!1,!0)}),t.bind(t.railh,"dblclick",function(a){t.doRailClick(a,!0,!0)}),t.bind(t.cursorh,"click",function(a){t.cancelEvent(a)}),t.bind(t.cursorh,"dblclick",function(a){t.cancelEvent(a)}
1)))),v.cantouch||t.opt.touchbehavior?(t.bind(v.hasmousecapture?t.win:document,"mouseup",t.ontouchend),t.bind(document,"mousemove",t.ontouchmove),t.onclick&&t.bind(document,"click",t.onclick),t.opt.cursordragontouch&&(t.bind(t.cursor,"mousedown",t.onmousedown),t.bind(t.cursor,"mousemove",t.onmousemove),t.cursorh&&t.bind(t.cursorh,"mousedown",t.onmousedown),t.cursorh&&t.bind(t.cursorh,"mousemove",t.onmousemove))):(t.bind(v.hasmousecapture?t.win:document,"mouseup",t.onmouseup),t.bind(document,"mousemove",t.onmousemove),t.onclick&&t.bind(document,"click",t.onclick),!t.ispage&&t.opt.enablescrollonselection&&(t.bind(t.win[0],"mousedown",t.onselectionstart),t.bind(document,"mouseup",t.onselectionend),t.bind(t.cursor,"mouseup",t.onselectionend),t.cursorh&&t.bind(t.cursorh,"mouseup",t.onselectionend),t.bind(document,"mousemove",t.onselectiondrag)),t.zoom&&(t.jqbind(t.zoom,"mouseenter",function(){t.canshowonmouseevent&&t.showCursor(),t.rail.active=!0}),t.jqbind(t.zoom,"mouseleave",function(){t.rail.active=!1,t.rail.drag||t.hideCursor()}))),t.opt.enablemousewheel&&(t.isiframe||t.bind(v.isie&&t.ispage?document:t.docscroll,"mousewheel",t.onmousewheel),t.bind(t.rail,"mousewheel",t.onmousewheel),t.railh&&t.bind(t.railh,"mousewheel",t.onmousewheelhr)),!t.ispage&&!v.cantouch&&!/HTML|BODY/.test(t.win[0].nodeName)&&(t.win.attr("tabindex")||t.win.attr({tabindex:e++}),t.jqbind(t.win,"focus",function(a){c=t.getTarget(a).id||!0,t.hasfocus=!0,t.canshowonmouseevent&&t.noticeCursor()}),t.jqbind(t.win,"blur",function(a){c=!1,t.hasfocus=!1}),t.jqbind(t.win,"mouseenter",function(a){d=t.getTarget(a).id||!0,t.hasmousefocus=!0,t.canshowonmouseevent&&t.noticeCursor()}),t.jqbind(t.win,"mouseleave",function(){d=!1,t.hasmousefocus=!1}))}if(t.onkeypress=function(a){if(t.locked&&0==t.page.maxh)return!0;a=a||window.e;var b=t.getTarget(a);if(b&&/INPUT|TEXTAREA|SELECT|OPTION/.test(b.nodeName)&&(!b.getAttribute("type")&&!b.type||!/submit|button|cancel/i.tp))return!0;if(t.hasfocus||t.hasmousefocus&&!c||t.ispage&&!c&&!d){if(b=a.keyCode,t.locked&&27!=b)return t.cancelEvent(a);var e=a.ctrlKey||!1,f=a.shiftKey||!1,g=!1;switch(b){case 38:case 63233:t.doScrollBy(72),g=!0;break;case 40:case 63235:t.doScrollBy(-72),g=!0;break;case 37:case 63232:t.railh&&(e?t.doScrollLeft(0):t.doScrollLeftBy(72),g=!0);break;case 39:case 63234:t.railh&&(e?t.doScrollLeft(t.page.maxw):t.doScrollLeftBy(-72),g=!0);break;case 33:case 63276:t.doScrollBy(t.view.h),g=!0;break;case 34:case 63277:t.doScrollBy(-t.view.h),g=!0;break;case 36:case 63273:t.railh&&e?t.doScrollPos(0,0):t.doScrollTo(0),g=!0;break;case 35:case 63275:t.railh&&e?t.doScrollPos(t.page.maxw,t.page.maxh):t.doScrollTo(t.page.maxh),g=!0;break;case 32:t.opt.spacebarenabled&&(f?t.doScrollBy(t.view.h):t.doScrollBy(-t.view.h),g=!0);break;case 27:t.zoomactive&&(t.doZoom(),g=!0)}if(g)return t.cancelEvent(a)}},t.opt.enablekeyboard&&t.bind(document,v.isopera&&!v.isopera12?"keypress":"keydown",t.onkeypress),t.bind(window,"resize",t.lazyResize),t.bind(window,"orientationchange",t.lazyResize),t.bind(window,"load",t.lazyResize),v.ischrome&&!t.ispage&&!t.haswrapper){var u=t.win.attr("style"),i=parseFloat(t.win.css("width"))+1;t.win.css("width",i),t.synched("chromefix",function(){t.win.attr("style",u)})}t.onAttributeChange=function(a){t.lazyResize(250)},!t.ispage&&!t.haswrapper&&(!1!==k?(t.observer=new k(function(a){a.forEach(t.onAttributeChange)}),t.observer.observe(t.win[0],{childList:!0,characterData:!1,attributes:!0,subtree:!1}),t.observerremover=new k(function(a){a.forEach(function(a){if(0<a.removedNodes.length)for(var b in a.removedNodes)if(a.removedNodes[b]==t.win[0])return t.remove()})}),t.observerremover.observe(t.win[0].parentNode,{childList:!0,characterData:!1,attributes:!1,subtree:!1})):(t.bind(t.win,v.isie&&!v.isie9?"propertychange":"DOMAttrModified",t.onAttributeChange),v.isie9&&t.win[0].attachEvent("onpropertychange",t.onAttributeChange),t.bind(t.win,"DOMNodeRemoved",function(a){a.target==t.win[0]&&t.remove()}))),!t.ispage&&t.opt.boxzoom&&t.bind(window,"resize",t.resizeZoom),t.istextarea&&t.bind(t.win,"mouseup",t.lazyResize),t.checkrtlmode=!0,t.lazyResize(30)}if("IFRAME"==this.doc[0].nodeName){var w=function(a){t.iframexd=!1;try{var c="contentDocument"in this?this.contentDocument:this.contentWindow.document}catch(a){t.iframexd=!0,c=!1}if(t.iframexd)return"console"in window&&console.log("NiceScroll error: policy restriced iframe"),!0;t.forcescreen=!0,t.isiframe&&(t.iframe={doc:b(c),html:t.doc.contents().find("html")[0],body:t.doc.contents().find("body")[0]},t.getContentSize=function(){return{w:Math.max(t.iframe.html.scrollWidth,t.iframe.body.scrollWidth),h:Math.max(t.iframe.html.scrollHeight,t.iframe.body.scrollHeight)}},t.docscroll=b(t.iframe.body)),!v.isios&&t.opt.iframeautoresize&&!t.isiframe&&(t.win.scrollTop(0),t.doc.height(""),a=Math.max(c.getElementsByTagName("html")[0].scrollHeight,c.body.scrollHeight),t.doc.height(a)),t.lazyResize(30),v.isie7&&t.css(b(t.iframe.html),{"overflow-y":"hidden"}),t.css(b(t.iframe.body),{"overflow-y":"hidden"}),"contentWindow"in this?t.bind(this.contentWindow,"scroll",t.onscroll):t.bind(c,"scroll",t.onscroll),t.opt.enablemousewheel&&t.bind(c,"mousewheel",t.onmousewheel),t.opt.enablekeyboard&&t.bind(c,v.isopera?"keypress":"keydown",t.onkeypress),(v.cantouch||t.opt.touchbehavior)&&(t.bind(c,"mousedown",t.onmousedown),t.bind(c,"mousemove",function(a){t.onmousemove(a,!0)}),t.opt.grabcursorenabled&&v.cursorgrabvalue&&t.css(b(c.body),{cursor:v.cursorgrabvalue})),t.bind(c,"mouseup",t.onmouseup),t.zoom&&(t.opt.dblclickzoom&&t.bind(c,"dblclick",t.doZoom),t.ongesturezoom&&t.bind(c,"gestureend",t.ongesturezoom))};this.doc[0].readyState&&"complete"==this.doc[0].readyState&&setTimeout(function(){w.call(t.doc[0],!1)},500),t.bind(this.doc,"load",w)}}
1,this.showCursor=function(a,b){t.cursortimeout&&(clearTimeout(t.cursortimeout),t.cursortimeout=0),t.rail&&(t.autohidedom&&(t.autohidedom.stop().css({opacity:t.opt.cursoropacitymax}),t.cursoractive=!0),t.rail.drag&&1==t.rail.drag.pt||(void 0!==a&&!1!==a&&(t.scroll.y=Math.round(1*a/t.scrollratio.y)),void 0!==b&&(t.scroll.x=Math.round(1*b/t.scrollratio.x))),t.cursor.css({height:t.cursorheight,top:t.scroll.y}),t.cursorh&&(!t.rail.align&&t.rail.visibility?t.cursorh.css({width:t.cursorwidth,left:t.scroll.x+t.rail.width}):t.cursorh.css({width:t.cursorwidth,left:t.scroll.x}),t.cursoractive=!0),t.zoom&&t.zoom.stop().css({opacity:t.opt.cursoropacitymax}))},this.hideCursor=function(a){!t.cursortimeout&&t.rail&&t.autohidedom&&(t.cursortimeout=setTimeout(function(){t.rail.active&&t.showonmouseevent||(t.autohidedom.stop().animate({opacity:t.opt.cursoropacitymin}),t.zoom&&t.zoom.stop().animate({opacity:t.opt.cursoropacitymin}),t.cursoractive=!1),t.cursortimeout=0},a||t.opt.hidecursordelay))},this.noticeCursor=function(a,b,c){t.showCursor(b,c),t.rail.active||t.hideCursor(a)},this.getContentSize=t.ispage?function(){return{w:Math.max(document.body.scrollWidth,document.documentElement.scrollWidth),h:Math.max(document.body.scrollHeight,document.documentElement.scrollHeight)}}:t.haswrapper?function(){return{w:t.doc.outerWidth()+parseInt(t.win.css("paddingLeft"))+parseInt(t.win.css("paddingRight")),h:t.doc.outerHeight()+parseInt(t.win.css("paddingTop"))+parseInt(t.win.css("paddingBottom"))}}:function(){return{w:t.docscroll[0].scrollWidth,h:t.docscroll[0].scrollHeight}},this.onResize=function(a,b){if(!t.win)return!1;if(!t.haswrapper&&!t.ispage){if("none"==t.win.css("display"))return t.visibility&&t.hideRail().hideRailHr(),!1;!t.hidden&&!t.visibility&&t.showRail().showRailHr()}var c=t.page.maxh,d=t.page.maxw,e=t.view.w;if(t.view={w:t.ispage?t.win.width():parseInt(t.win[0].clientWidth),h:t.ispage?t.win.height():parseInt(t.win[0].clientHeight)},t.page=b||t.getContentSize(),t.page.maxh=Math.max(0,t.page.h-t.view.h),t.page.maxw=Math.max(0,t.page.w-t.view.w),t.page.maxh==c&&t.page.maxw==d&&t.view.w==e){if(t.ispage)return t;if(c=t.win.offset(),t.lastposition&&(d=t.lastposition,d.top==c.top&&d.left==c.left))return t;t.lastposition=c}return 0==t.page.maxh?(t.hideRail(),t.scrollvaluemax=0,t.scroll.y=0,t.scrollratio.y=0,t.cursorheight=0,t.setScrollTop(0),t.rail.scrollable=!1):t.rail.scrollable=!0,0==t.page.maxw?(t.hideRailHr(),t.scrollvaluemaxw=0,t.scroll.x=0,t.scrollratio.x=0,t.cursorwidth=0,t.setScrollLeft(0),t.railh.scrollable=!1):t.railh.scrollable=!0,t.locked=0==t.page.maxh&&0==t.page.maxw,t.locked?(t.ispage||t.updateScrollBar(t.view),!1):(t.hidden||t.visibility?!t.hidden&&!t.railh.visibility&&t.showRailHr():t.showRail().showRailHr(),t.istextarea&&t.win.css("resize")&&"none"!=t.win.css("resize")&&(t.view.h-=20),t.cursorheight=Math.min(t.view.h,Math.round(t.view.h*(t.view.h/t.page.h))),t.cursorheight=t.opt.cursorfixedheight?t.opt.cursorfixedheight:Math.max(t.opt.cursorminheight,t.cursorheight),t.cursorwidth=Math.min(t.view.w,Math.round(t.view.w*(t.view.w/t.page.w))),t.cursorwidth=t.opt.cursorfixedheight?t.opt.cursorfixedheight:Math.max(t.opt.cursorminheight,t.cursorwidth),t.scrollvaluemax=t.view.h-t.cursorheight-t.cursor.hborder,t.railh&&(t.railh.width=0<t.page.maxh?t.view.w-t.rail.width:t.view.w,t.scrollvaluemaxw=t.railh.width-t.cursorwidth-t.cursorh.wborder),t.checkrtlmode&&t.railh&&(t.checkrtlmode=!1,t.opt.rtlmode&&0==t.scroll.x&&t.setScrollLeft(t.page.maxw)),t.ispage||t.updateScrollBar(t.view),t.scrollratio={x:t.page.maxw/t.scrollvaluemaxw,y:t.page.maxh/t.scrollvaluemax},t.getScrollTop()>t.page.maxh?t.doScrollTop(t.page.maxh):(t.scroll.y=Math.round(t.getScrollTop()*(1/t.scrollratio.y)),t.scroll.x=Math.round(t.getScrollLeft()*(1/t.scrollratio.x)),t.cursoractive&&t.noticeCursor()),t.scroll.y&&0==t.getScrollTop()&&t.doScrollTo(Math.floor(t.scroll.y*t.scrollratio.y)),t)},this.resize=t.onResize,this.lazyResize=function(a){return a=isNaN(a)?30:a,t.delayed("resize",t.resize,a),t},this._bind=function(a,b,c,d){t.events.push({e:a,n:b,f:c,b:d,q:!1}),a.addEventListener?a.addEventListener(b,c,d||!1):a.attachEvent?a.attachEvent("on"+b,c):a["on"+b]=c},this.jqbind=function(a,c,d){t.events.push({e:a,n:c,f:d,q:!0}),b(a).bind(c,d)},this.bind=function(a,b,c,d){var e="jquery"in a?a[0]:a;"mousewheel"==b?"onwheel"in t.win?t._bind(e,"wheel",c,d||!1):(a=void 0!==document.onmousewheel?"mousewheel":"DOMMouseScroll",r(e,a,c,d||!1),"DOMMouseScroll"==a&&r(e,"MozMousePixelScroll",c,d||!1)):e.addEventListener?(v.cantouch&&/mouseup|mousedown|mousemove/.test(b)&&t._bind(e,"mousedown"==b?"touchstart":"mouseup"==b?"touchend":"touchmove",function(a){if
1(a.touches){if(2>a.touches.length){var b=a.touches.length?a.touches[0]:a;b.original=a,c.call(this,b)}}else a.changedTouches&&(b=a.changedTouches[0],b.original=a,c.call(this,b))},d||!1),t._bind(e,b,c,d||!1),v.cantouch&&"mouseup"==b&&t._bind(e,"touchcancel",c,d||!1)):t._bind(e,b,function(a){return(a=a||window.event||!1)&&a.srcElement&&(a.target=a.srcElement),"pageY"in a||(a.pageX=a.clientX+document.documentElement.scrollLeft,a.pageY=a.clientY+document.documentElement.scrollTop),!1!==c.call(e,a)&&!1!==d||t.cancelEvent(a)})},this._unbind=function(a,b,c,d){a.removeEventListener?a.removeEventListener(b,c,d):a.detachEvent?a.detachEvent("on"+b,c):a["on"+b]=!1},this.unbindAll=function(){for(var a=0;a<t.events.length;a++){var b=t.events[a];b.q?b.e.unbind(b.n,b.f):t._unbind(b.e,b.n,b.f,b.b)}},this.cancelEvent=function(a){return!!(a=a.original?a.original:a||(window.event||!1))&&(a.preventDefault&&a.preventDefault(),a.stopPropagation&&a.stopPropagation(),a.preventManipulation&&a.preventManipulation(),a.cancelBubble=!0,a.cancel=!0,a.returnValue=!1)},this.stopPropagation=function(a){return!!(a=a.original?a.original:a||(window.event||!1))&&(a.stopPropagation?a.stopPropagation():(a.cancelBubble&&(a.cancelBubble=!0),!1))},this.showRail=function(){return 0==t.page.maxh||!t.ispage&&"none"==t.win.css("display")||(t.visibility=!0,t.rail.visibility=!0,t.rail.css("display","block")),t},this.showRailHr=function(){return t.railh?(0==t.page.maxw||!t.ispage&&"none"==t.win.css("display")||(t.railh.visibility=!0,t.railh.css("display","block")),t):t},this.hideRail=function(){return t.visibility=!1,t.rail.visibility=!1,t.rail.css("display","none"),t},this.hideRailHr=function(){return t.railh?(t.railh.visibility=!1,t.railh.css("display","none"),t):t},this.show=function(){return t.hidden=!1,t.locked=!1,t.showRail().showRailHr()},this.hide=function(){return t.hidden=!0,t.locked=!0,t.hideRail().hideRailHr()},this.toggle=function(){return t.hidden?t.show():t.hide()},this.remove=function(){t.stop(),t.cursortimeout&&clearTimeout(t.cursortimeout),t.doZoomOut(),t.unbindAll(),!1!==t.observer&&t.observer.disconnect(),!1!==t.observerremover&&t.observerremover.disconnect(),t.events=[],t.cursor&&(t.cursor.remove(),t.cursor=null),t.cursorh&&(t.cursorh.remove(),t.cursorh=null),t.rail&&(t.rail.remove(),t.rail=null),t.railh&&(t.railh.remove(),t.railh=null),t.zoom&&(t.zoom.remove(),t.zoom=null);for(var a=0;a<t.saved.css.length;a++){var b=t.saved.css[a];b[0].css(b[1],void 0===b[2]?"":b[2])}return t.saved=!1,t.me.data("__nicescroll",""),t.me=null,t.doc=null,t.docscroll=null,t.win=null,t},this.scrollstart=function(a){return this.onscrollstart=a,t},this.scrollend=function(a){return this.onscrollend=a,t},this.scrollcancel=function(a){return this.onscrollcancel=a,t},this.zoomin=function(a){return this.onzoomin=a,t},this.zoomout=function(a){return this.onzoomout=a,t},this.isScrollable=function(a){if(a=a.target?a.target:a,"OPTION"==a.nodeName)return!0;for(;a&&1==a.nodeType&&!/BODY|HTML/.test(a.nodeName);){var c=b(a),c=c.css("overflowY")||c.css("overflowX")||c.css("overflow")||"";if(/scroll|auto/.test(c))return a.clientHeight!=a.scrollHeight;a=!!a.parentNode&&a.parentNode}return!1},this.getViewport=function(a){for(a=!(!a||!a.parentNode)&&a.parentNode;a&&1==a.nodeType&&!/BODY|HTML/.test(a.nodeName);){var c=b(a);if(/scroll|auto/.test(c.css("overflowY")||c.css("overflowX")||c.css("overflow")||"")&&a.clientHeight!=a.scrollHeight||0<c.getNiceScroll().length)return c;a=!!a.parentNode&&a.parentNode}return!1},this.onmousewheel=function(a){if(t.locked)return!0;if(t.rail.drag)return t.cancelEvent(a);if(!t.rail.scrollable)return!t.railh||!t.railh.scrollable||t.onmousewheelhr(a);var b=+new Date,c=!1;return t.opt.preservenativescrolling&&t.checkarea+600<b&&(t.nativescrollingarea=t.isScrollable(a),c=!0),t.checkarea=b,!!t.nativescrollingarea||((a=s(a,!1,c))&&(t.checkarea=0),a)},this.onmousewheelhr=function(a){if(t.locked||!t.railh.scrollable)return!0;if(t.rail.drag)return t.cancelEvent(a);var b=+new Date,c=!1;return t.opt.preservenativescrolling&&t.checkarea+600<b&&(t.nativescrollingarea=t.isScrollable(a),c=!0),t.checkarea=b,!!t.nativescrollingarea||(t.locked?t.cancelEvent(a):s(a,!0,c))},this.stop=function(){return t.cancelScroll(),t.scrollmon&&t.scrollmon.stop(),t.cursorfreezed=!1,t.scroll.y=Math.round(t.getScrollTop()*(1/t.
1scrollratio.y)),t.noticeCursor(),t},this.getTransitionSpeed=function(a){var b=Math.round(10*t.opt.scrollspeed);return a=Math.min(b,Math.round(a/20*t.opt.scrollspeed)),20<a?a:0},t.opt.smoothscroll?t.ishwscroll&&v.hastransition&&t.opt.usetransition?(this.prepareTransition=function(a,b){var c=b?20<a?a:0:t.getTransitionSpeed(a),d=c?v.prefixstyle+"transform "+c+"ms ease-out":"";return t.lasttransitionstyle&&t.lasttransitionstyle==d||(t.lasttransitionstyle=d,t.doc.css(v.transitionstyle,d)),c},this.doScrollLeft=function(a,b){var c=t.scrollrunning?t.newscrolly:t.getScrollTop();t.doScrollPos(a,c,b)},this.doScrollTop=function(a,b){var c=t.scrollrunning?t.newscrollx:t.getScrollLeft();t.doScrollPos(c,a,b)},this.doScrollPos=function(a,b,c){var d=t.getScrollTop(),e=t.getScrollLeft();return(0>(t.newscrolly-d)*(b-d)||0>(t.newscrollx-e)*(a-e))&&t.cancelScroll(),0==t.opt.bouncescroll&&(0>b?b=0:b>t.page.maxh&&(b=t.page.maxh),0>a?a=0:a>t.page.maxw&&(a=t.page.maxw)),(!t.scrollrunning||a!=t.newscrollx||b!=t.newscrolly)&&(t.newscrolly=b,t.newscrollx=a,t.newscrollspeed=c||!1,!t.timer&&void(t.timer=setTimeout(function(){var e,f,c=t.getScrollTop(),d=t.getScrollLeft();e=a-d,f=b-c,e=Math.round(Math.sqrt(Math.pow(e,2)+Math.pow(f,2))),e=t.newscrollspeed&&1<t.newscrollspeed?t.newscrollspeed:t.getTransitionSpeed(e),t.newscrollspeed&&1>=t.newscrollspeed&&(e*=t.newscrollspeed),t.prepareTransition(e,!0),t.timerscroll&&t.timerscroll.tm&&clearInterval(t.timerscroll.tm),0<e&&(!t.scrollrunning&&t.onscrollstart&&t.onscrollstart.call(t,{type:"scrollstart",current:{x:d,y:c},request:{x:a,y:b},end:{x:t.newscrollx,y:t.newscrolly},speed:e}),v.transitionend?t.scrollendtrapped||(t.scrollendtrapped=!0,t.bind(t.doc,v.transitionend,t.onScrollEnd,!1)):(t.scrollendtrapped&&clearTimeout(t.scrollendtrapped),t.scrollendtrapped=setTimeout(t.onScrollEnd,e)),t.timerscroll={bz:new BezierClass(c,t.newscrolly,e,0,0,.58,1),bh:new BezierClass(d,t.newscrollx,e,0,0,.58,1)},t.cursorfreezed||(t.timerscroll.tm=setInterval(function(){t.showCursor(t.getScrollTop(),t.getScrollLeft())},60))),t.synched("doScroll-set",function(){t.timer=0,t.scrollendtrapped&&(t.scrollrunning=!0),t.setScrollTop(t.newscrolly),t.setScrollLeft(t.newscrollx),t.scrollendtrapped||t.onScrollEnd()})},50)))},this.cancelScroll=function(){if(!t.scrollendtrapped)return!0;var a=t.getScrollTop(),b=t.getScrollLeft();return t.scrollrunning=!1,v.transitionend||clearTimeout(v.transitionend),t.scrollendtrapped=!1,t._unbind(t.doc,v.transitionend,t.onScrollEnd),t.prepareTransition(0),t.setScrollTop(a),t.railh&&t.setScrollLeft(b),t.timerscroll&&t.timerscroll.tm&&clearInterval(t.timerscroll.tm),t.timerscroll=!1,t.cursorfreezed=!1,t.showCursor(a,b),t},this.onScrollEnd=function(){t.scrollendtrapped&&t._unbind(t.doc,v.transitionend,t.onScrollEnd),t.scrollendtrapped=!1,t.prepareTransition(0),t.timerscroll&&t.timerscroll.tm&&clearInterval(t.timerscroll.tm),t.timerscroll=!1;var a=t.getScrollTop(),b=t.getScrollLeft();if(t.setScrollTop(a),t.railh&&t.setScrollLeft(b),t.noticeCursor(!1,a,b),t.cursorfreezed=!1,0>a?a=0:a>t.page.maxh&&(a=t.page.maxh),0>b?b=0:b>t.page.maxw&&(b=t.page.maxw),a!=t.newscrolly||b!=t.newscrollx)return t.doScrollPos(b,a,t.opt.snapbackspeed);t.onscrollend&&t.scrollrunning&&t.onscrollend.call(t,{type:"scrollend",current:{x:b,y:a},end:{x:t.newscrollx,y:t.newscrolly}}),t.scrollrunning=!1}):(this.doScrollLeft=function(a,b){var c=t.scrollrunning?t.newscrolly:t.getScrollTop();t.doScrollPos(a,c,b)},this.doScrollTop=function(a,b){var c=t.scrollrunning?t.newscrollx:t.getScrollLeft();t.doScrollPos(c,a,b)},this.doScrollPos=function(a,b,c){function d(){if(t.cancelAnimationFrame)return!0;if(t.scrollrunning=!0,l=1-l)return t.timer=i(d)||1;var a=0,b=sy=t.getScrollTop();if(t.dst.ay){var b=t.bzscroll?t.dst.py+t.bzscroll.getNow()*t.dst.ay:t.newscrolly,c=b-sy;(0>c&&b<t.newscrolly||0<c&&b>t.newscrolly)&&(b=t.newscrolly),t.setScrollTop(b),b==t.newscrolly&&(a=1)}else a=1;var e=sx=t.getScrollLeft();t.dst.ax?(e=t.bzscroll?t.dst.px+t.bzscroll.getNow()*t.dst.ax:t.newscrollx,c=e-sx,(0>c&&e<t.newscrollx||0<c&&e>t.newscrollx)&&(e=t.newscrollx),t.setScrollLeft(e),e==t.newscrollx&&(a+=1)):a+=1,2==a?(t.timer=0,t.cursorfreezed=!1,t.bzscroll=!1,t.scrollrunning=!1,0>b?b=0:b>t.page.maxh&&(b=t.page.maxh),0>e?e=0:e>t.page.maxw&&(e=t.page.maxw),e!=t.newscrollx||b!=t.newscrolly?t.doScrollPos(e,b):t.onscrollend&&t.onscrollend.call(t,{type:"scrollend",current:{x:sx,y:sy},end:{x:t.newscrollx,y:t.newscrolly}})):t.timer=i(d)||1}if(b=void 0===b||!1===b?t.getScrollTop(!0):b,t.timer&&t.newscrolly==b&&t.newscrollx==a)return!0;t.timer&&j(t.timer),t.timer=0;var e=t.getScrollTop(),f=t.getScrollLeft();(0>(t.newscrolly-e)*(b-e)||0>(t.newscrollx-f)*(a-f))&&t.cancelScroll(),t.newscrolly=b,t.newscrollx=a,t.bouncescroll&&t.rail.visibility||(0>t.newscrolly?t.newscrolly=0:t.newscrolly>t.page.maxh&&(t.newscrolly=t.page.maxh)),t.bouncescroll&&t.railh.visibility||(0>t.newscrollx?t.newscrollx=0:t.newscrollx>t.page.maxw&&(t.newscrollx=t.page.maxw)),t.dst={},t.dst.x=a-f,t.dst.y=b-e,t.dst.px=f,t.dst.py=e;var g=Math.round(Math.sqrt(Math.pow(t.dst.x,2)+Math.pow(t.dst.y,2)));t.dst.ax=t.dst.x/g,t.dst.ay=t.dst.y/g;var h=0,k=g;if(0==t.dst.x?(h=e,k=b,t.dst.ay=1,t.dst.py=0):0==t.dst.y&&(h=f,k=a,t.dst.ax=1,t.dst.px=0),g=t.getTransitionSpeed(g),c&&1>=c&&(g*=c),t.bzscroll=0<g&&(t.bzscroll?t.bzscroll.update(k,g):new BezierClass(h,k,g,0,1,0,1)),!t.timer){(e==t.page.maxh&&b>=t.page.maxh||f==t.page.maxw&&a>=t.page.maxw)&&t.checkContentSize();var l=1;t.cancelAnimationFrame=!1,t.timer=1,t.onscrollstart&&!t.scrollrunning&&t.onscrollstart.call(t,{type:"scrollstart",current:{x:f,y:e},request:{x:a,y:b},end:{x:t.newscrollx,y:t.newscrolly},speed:g}),d(),(e==t.page.maxh&&b>=e||f==t.page.maxw&&a>=f)&&t.checkContentSize(),t.noticeCursor()}},this.cancelScroll=function(){return t.timer&&j(t.timer),t.timer=0,t.bzscroll=!1,t.scrollrunning=!1,t}):(this.doScrollLeft=function(a,b){var c=t.getScrollTop();t.doScrollPos(a,c,b)},this.doScrollTop=function(a,b){var c=t.getScrollLeft();t.doScrollPos(c,a,b)},this.doScrollPos=function(a,b,c){var d=a>t.page.maxw?t.page.maxw:a;0>d&&(d=0);var e=b>t.page.maxh?t.page.maxh:b;0>e&&(e=0),t.synched("scroll",function(){t.setScrollTop(e),t.setScrollLeft(d)})},this.cancelScroll=function(){}),this.doScrollBy=function(a,b){var c=0,c=b?Math.floor((t.scroll.y-a)*t.scrollratio.y):(t.timer?t.newscrolly:t.getScrollTop(!0))-a;if(t.bouncescroll){var d=Math.round(t.view.h/2);c<-d?c=-d:c>t.page.maxh+d&&(c=t.page.maxh+d)}
1return t.cursorfreezed=!1,py=t.getScrollTop(!0),0>c&&0>=py?t.noticeCursor():c>t.page.maxh&&py>=t.page.maxh?(t.checkContentSize(),t.noticeCursor()):void t.doScrollTop(c)},this.doScrollLeftBy=function(a,b){var c=0,c=b?Math.floor((t.scroll.x-a)*t.scrollratio.x):(t.timer?t.newscrollx:t.getScrollLeft(!0))-a;if(t.bouncescroll){var d=Math.round(t.view.w/2);c<-d?c=-d:c>t.page.maxw+d&&(c=t.page.maxw+d)}if(t.cursorfreezed=!1,px=t.getScrollLeft(!0),0>c&&0>=px||c>t.page.maxw&&px>=t.page.maxw)return t.noticeCursor();t.doScrollLeft(c)},this.doScrollTo=function(a,b){b&&Math.round(a*t.scrollratio.y),t.cursorfreezed=!1,t.doScrollTop(a)},this.checkContentSize=function(){var a=t.getContentSize();(a.h!=t.page.h||a.w!=t.page.w)&&t.resize(!1,a)},t.onscroll=function(a){t.rail.drag||t.cursorfreezed||t.synched("scroll",function(){t.scroll.y=Math.round(t.getScrollTop()*(1/t.scrollratio.y)),t.railh&&(t.scroll.x=Math.round(t.getScrollLeft()*(1/t.scrollratio.x))),t.noticeCursor()})},t.bind(t.docscroll,"scroll",t.onscroll),this.doZoomIn=function(a){if(!t.zoomactive){t.zoomactive=!0,t.zoomrestore={style:{}};var e,c="position top left zIndex backgroundColor marginTop marginBottom marginLeft marginRight".split(" "),d=t.win[0].style;for(e in c){var f=c[e];t.zoomrestore.style[f]=void 0!==d[f]?d[f]:""}return t.zoomrestore.style.width=t.win.css("width"),t.zoomrestore.style.height=t.win.css("height"),t.zoomrestore.padding={w:t.win.outerWidth()-t.win.width(),h:t.win.outerHeight()-t.win.height()},v.isios4&&(t.zoomrestore.scrollTop=b(window).scrollTop(),b(window).scrollTop(0)),t.win.css({position:v.isios4?"absolute":"fixed",top:0,left:0,"z-index":g+100,margin:"0px"}),c=t.win.css("backgroundColor"),(""==c||/transparent|rgba\(0, 0, 0, 0\)|rgba\(0,0,0,0\)/.test(c))&&t.win.css("backgroundColor","#fff"),t.rail.css({"z-index":g+101}),t.zoom.css({"z-index":g+102}),t.zoom.css("backgroundPosition","0px -18px"),t.resizeZoom(),t.onzoomin&&t.onzoomin.call(t),t.cancelEvent(a)}},this.doZoomOut=function(a){if(t.zoomactive)return t.zoomactive=!1,t.win.css("margin",""),t.win.css(t.zoomrestore.style),v.isios4&&b(window).scrollTop(t.zoomrestore.scrollTop),t.rail.css({"z-index":t.zindex}),t.zoom.css({"z-index":t.zindex}),t.zoomrestore=!1,t.zoom.css("backgroundPosition","0px 0px"),t.onResize(),t.onzoomout&&t.onzoomout.call(t),t.cancelEvent(a)},this.doZoom=function(a){return t.zoomactive?t.doZoomOut(a):t.doZoomIn(a)},this.resizeZoom=function(){if(t.zoomactive){var a=t.getScrollTop();t.win.css({width:b(window).width()-t.zoomrestore.padding.w+"px",height:b(window).height()-t.zoomrestore.padding.h+"px"}),t.onResize(),t.setScrollTop(Math.min(t.page.maxh,a))}},this.init(),b.nicescroll.push(this)},p=function(a){var b=this;this.nc=a,this.steptime=this.lasttime=this.speedy=this.speedx=this.lasty=this.lastx=0,this.snapy=this.snapx=!1,this.demuly=this.demulx=0,this.lastscrolly=this.lastscrollx=-1,this.timer=this.chky=this.chkx=0,this.time=function(){return+new Date},this.reset=function(a,c){b.stop();var d=b.time();b.steptime=0,b.lasttime=d,b.speedx=0,b.speedy=0,b.lastx=a,b.lasty=c,b.lastscrollx=-1,b.lastscrolly=-1},this.update=function(a,c){var d=b.time();b.steptime=d-b.lasttime,b.lasttime=d;var d=c-b.lasty,e=a-b.lastx,f=b.nc.getScrollTop(),g=b.nc.getScrollLeft(),f=f+d,g=g+e;b.snapx=0>g||g>b.nc.page.maxw,b.snapy=0>f||f>b.nc.page.maxh,b.speedx=e,b.speedy=d,b.lastx=a,b.lasty=c},this.stop=function(){b.nc.unsynched("domomentum2d"),b.timer&&clearTimeout(b.timer),b.timer=0,b.lastscrollx=-1,b.lastscrolly=-1},this.doSnapy=function(a,c){var d=!1;0>c?(c=0,d=!0):c>b.nc.page.maxh&&(c=b.nc.page.maxh,d=!0),0>a?(a=0,d=!0):a>b.nc.page.maxw&&(a=b.nc.page.maxw,d=!0),d&&b.nc.doScrollPos(a,c,b.nc.opt.snapbackspeed)},this.doMomentum=function(a){var c=b.time(),d=a?c+a:b.lasttime;a=b.nc.getScrollLeft();var e=b.nc.getScrollTop(),f=b.nc.page.maxh,g=b.nc.page.maxw;if(b.speedx=0<g?Math.min(60,b.speedx):0,b.speedy=0<f?Math.min(60,b.speedy):0,d=d&&50>=c-d,(0>e||e>f||0>a||a>g)&&(d=!1),a=!(!b.speedx||!d)&&b.speedx,b.speedy&&d&&b.speedy||a){var h=Math.max(16,b.steptime);50<h&&(a=h/50,b.speedx*=a,b.speedy*=a,h=50),b.demulxy=0,b.lastscrollx=b.nc.get
1ScrollLeft(),b.chkx=b.lastscrollx,b.lastscrolly=b.nc.getScrollTop(),b.chky=b.lastscrolly;var i=b.lastscrollx,j=b.lastscrolly,k=function(){var a=600<b.time()-c?.04:.02;b.speedx&&(i=Math.floor(b.lastscrollx-b.speedx*(1-b.demulxy)),b.lastscrollx=i,0>i||i>g)&&(a=.1),b.speedy&&(j=Math.floor(b.lastscrolly-b.speedy*(1-b.demulxy)),b.lastscrolly=j,0>j||j>f)&&(a=.1),b.demulxy=Math.min(1,b.demulxy+a),b.nc.synched("domomentum2d",function(){b.speedx&&(b.nc.getScrollLeft()!=b.chkx&&b.stop(),b.chkx=i,b.nc.setScrollLeft(i)),b.speedy&&(b.nc.getScrollTop()!=b.chky&&b.stop(),b.chky=j,b.nc.setScrollTop(j)),b.timer||(b.nc.hideCursor(),b.doSnapy(i,j))}),1>b.demulxy?b.timer=setTimeout(k,h):(b.stop(),b.nc.hideCursor(),b.doSnapy(i,j))};k()}else b.doSnapy(b.nc.getScrollLeft(),b.nc.getScrollTop())}},q=b.fn.scrollTop;b.cssHooks.pageYOffset={get:function(a,c,d){return(c=b.data(a,"__nicescroll")||!1)&&c.ishwscroll?c.getScrollTop():q.call(a)},set:function(a,c){var d=b.data(a,"__nicescroll")||!1;return d&&d.ishwscroll?d.setScrollTop(parseInt(c)):q.call(a,c),this}},b.fn.scrollTop=function(a){if(void 0===a){var c=!!this[0]&&(b.data(this[0],"__nicescroll")||!1);return c&&c.ishwscroll?c.getScrollTop():q.call(this)}return this.each(function(){var c=b.data(this,"__nicescroll")||!1;c&&c.ishwscroll?c.setScrollTop(parseInt(a)):q.call(b(this),a)})};var r=b.fn.scrollLeft;b.cssHooks.pageXOffset={get:function(a,c,d){return(c=b.data(a,"__nicescroll")||!1)&&c.ishwscroll?c.getScrollLeft():r.call(a)},set:function(a,c){var d=b.data(a,"__nicescroll")||!1;return d&&d.ishwscroll?d.setScrollLeft(parseInt(c)):r.call(a,c),this}},b.fn.scrollLeft=function(a){if(void 0===a){var c=!!this[0]&&(b.data(this[0],"__nicescroll")||!1);return c&&c.ishwscroll?c.getScrollLeft():r.call(this)}return this.each(function(){var c=b.data(this,"__nicescroll")||!1;c&&c.ishwscroll?c.setScrollLeft(parseInt(a)):r.call(b(this),a)})};var s=function(c){var d=this;if(this.length=0,this.name="nicescrollarray",this.each=function(a){for(var b=0;b<d.length;b++)a.call(d[b]);return d},this.push=function(a){d[d.length]=a,d.length++},this.eq=function(a){return d[a]},c)for(a=0;a<c.length;a++){var e=b.data(c[a],"__nicescroll")||!1;e&&(this[this.length]=e,this.length++)}return this};!function(a,b,c){for(var d=0;d<b.length;d++)c(a,b[d])}(s.prototype,"show hide toggle onResize resize remove stop doScrollPos".split(" "),function(a,b){a[b]=function(){var a=arguments;return this.each(function(){this[b].apply(this,a)})}}),b.fn.getNiceScroll=function(a){return void 0===a?new s(this):b.data(this[a],"__nicescroll")||!1},b.extend(b.expr[":"],{nicescroll:function(a){return!!b.data(a,"__nicescroll")}}),b.fn.niceScroll=function(a,c){void 0===c&&"object"==typeof a&&!("jquery"in a)&&(c=a,a=!1);var d=new s;void 0===c&&(c={}),a&&(c.doc=b(a),c.win=b(this));var e=!("doc"in c);return!e&&!("win"in c)&&(c.win=b(this)),this.each(function(){var a=b(this).data("__nicescroll")||!1;a||(c.doc=e?b(this):c.doc,a=new o(c,b(this)),b(this).data("__nicescroll",a)),d.push(a)}),1==d.length?d[0]:d},window.NiceScroll={getjQuery:function(){return b}},b.nicescroll||(b.nicescroll=new s,b.nicescroll.options=l)}(jQuery);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.