!function(e){e.fn.slide=function(t){return e.fn.slide.defaults={type:"slide",effect:"fade",autoplay:!1,delaytime:500,intertime:2500,triggertime:150,defaultindex:0,titcell:".hd li",maincell:".bd",targetcell:null,trigger:"mouseover",scroll:1,vis:1,titonclassname:"on",autopage:!1,prevcell:".prev",nextcell:".next",pagestatecell:".pagestate",opp:!1,pnloop:!0,easing:"swing",startfun:null,endfun:null,switchload:null,playstatecell:".playstate",mouseoverstop:!0,defaultplay:!0,returndefault:!1},this.each(function(){var a=e.extend({},e.fn.slide.defaults,t),n=e(this),i=a.effect,s=e(a.prevcell,n),r=e(a.nextcell,n),o=e(a.pagestatecell,n),u=e(a.playstatecell,n),l=e(a.titcell,n),c=l.size(),f=e(a.maincell,n),p=f.children().size(),d=a.switchload,h=e(a.targetcell,n),v=parseint(a.defaultindex),m=parseint(a.delaytime),g=parseint(a.intertime);parseint(a.triggertime);var w,i=parseint(a.scroll),m=parseint(a.vis),c="false"!=a.autoplay&&0!=a.autoplay,y="false"!=a.opp&&0!=a.opp,x="false"!=a.autopage&&0!=a.autopage,o="false"!=a.pnloop&&0!=a.pnloop,b="false"!=a.mouseoverstop&&0!=a.mouseoverstop,q="false"!=a.defaultplay&&0!=a.defaultplay,k="false"!=a.returndefault&&0!=a.returndefault,p=0,q=0,s=0,t=0,l=a.easing,j=null,b=null,d=null,f=a.titonclassname,e=l.index(n.find("."+f)),w=v=-1==e?v:e,z=v,a=v,n=p>=m?0!=p%i?p%i:i:0,u="leftmarquee"==i||"topmarquee"==i,h=function(){e.isfunction(a.startfun)&&a.startfun(v,c,n,e(a.titcell,n),f,h,s,r)},$=function(){e.isfunction(a.endfun)&&a.endfun(v,c,n,e(a.titcell,n),f,h,s,r)},g=function(){l.removeclass(f),q&&l.eq(z).addclass(f)};if("menu"==a.type)return q&&l.removeclass(f).eq(v).addclass(f),l.hover(function(){w=e(this).find(a.targetcell);var t=l.index(e(this));b=settimeout(function(){switch(v=t,l.removeclass(f).eq(v).addclass(f),h(),i){case"fade":w.stop(!0,!0).animate({opacity:"show"},m,l,$);break;case"slidedown":w.stop(!0,!0).animate({height:"show"},m,l,$)}},a.triggertime)},function(){switch(cleartimeout(b),i){case"fade":w.animate({opacity:"hide"},m,l);break;case"slidedown":w.animate({height:"hide"},m,l)}}),void(k&&n.hover(function(){cleartimeout(d)},function(){d=settimeout(g,m)}));if(0==c&&(c=p),u&&(c=2),x){if(p>=m)if("leftloop"==i||"toploop"==i)c=0!=p%i?(0^p/i)+1:p/i;else{var j=p-m;c=1+parseint(0!=j%i?j/i+1:j/i),0>=c&&(c=1)}else c=1;l.html("");var k="";if(1==a.autopage||"true"==a.autopage)for(var r=0;c>r;r++)k+="
  • "+(r+1)+"
  • ";else for(var r=0;c>r;r++)k+=a.autopage.replace("$",r+1);l.html(k);var l=l.children()}if(p>=m){f.children().each(function(){e(this).width()>s&&(s=e(this).width(),q=e(this).outerwidth(!0)),e(this).height()>t&&(t=e(this).height(),p=e(this).outerheight(!0))});var v=f.children(),x=function(){for(var e=0;m>e;e++)v.eq(e).clone().addclass("clone").appendto(f);for(var e=0;n>e;e++)v.eq(p-e-1).clone().addclass("clone").prependto(f)};switch(i){case"fold":f.css({position:"relative",width:q,height:p}).children().css({position:"absolute",width:s,left:0,top:0,display:"none"});break;case"top":f.wrap('
    ').css({top:-(v*i)*p,position:"relative",padding:"0",margin:"0"}).children().css({height:t});break;case"left":f.wrap('
    ').css({width:p*q,left:-(v*i)*q,position:"relative",overflow:"hidden",padding:"0",margin:"0"}).children().css({"float":"left",width:s});break;case"leftloop":case"leftmarquee":x(),f.wrap('
    ').css({width:(p+m+n)*q,position:"relative",overflow:"hidden",padding:"0",margin:"0",left:-(n+v*i)*q}).children().css({"float":"left",width:s});break;case"toploop":case"topmarquee":x(),f.wrap('
    ').css({height:(p+m+n)*p,position:"relative",padding:"0",margin:"0",top:-(n+v*i)*p}).children().css({height:t})}}var y=function(e){var t=e*i;return e==c?t=p:-1==e&&0!=p%i&&(t=-p%i),t},z=function(t){var a=function(a){for(var n=a;m+a>n;n++)t.eq(n).find("img["+d+"]").each(function(){var t=e(this);if(t.attr("src",t.attr(d)).removeattr(d),f.find(".clone")[0])for(var a=f.children(),n=0;n=1?v=1:0>=v&&(v=0):(a=v,v>=c?v=0:0>v&&(v=c-1)),h(),null!=d&&z(f.children()),h[0]&&(w=h.eq(v),null!=d&&z(h),"slidedown"==i?(h.not(w).stop(!0,!0).slideup(m),w.slidedown(m,l,function(){f[0]||$()})):(h.not(w).stop(!0,!0).hide(),w.animate({opacity:"show"},m,function(){f[0]||$()}))),p>=m)switch(i){case"fade":f.children().stop(!0,!0).eq(v).animate({opacity:"show"},m,l,function(){$()}).siblings().hide();break;case"fold":f.children().stop(!0,!0).eq(v).animate({opacity:"show"},m,l,function(){$()}).siblings().animate({opacity:"hide"},m,l);break;case"top":f.stop(!0,!1).animate({top:-v*i*p},m,l,function(){$()});break;case"left":f.stop(!0,!1).animate({left:-v*i*q},m,l,function(){$()});break;case"leftloop":var t=a;f.stop(!0,!0).animate({left:-(y(a)+n)*q},m,l,function(){-1>=t?f.css("left",-(n+(c-1)*i)*q):t>=c&&f.css("left",-n*q),$()});break;case"toploop":var t=a;f.stop(!0,!0).animate({top:-(y(a)+n)*p},m,l,function(){-1>=t?f.css("top",-(n+(c-1)*i)*p):t>=c&&f.css("top",-n*p),$()});break;case"leftmarquee":var a=f.css("left").replace("px","");0==v?f.animate({left:++a},0,function(){f.css("left").replace("px","")>=0&&f.css("left",-p*q)}):f.animate({left:--a},0,function(){f.css("left").replace("px","")<=-(p+n)*q&&f.css("left",-n*q)});break;case"topmarquee":var n=f.css("top").replace("px","");0==v?f.animate({top:++n},0,function(){f.css("top").replace("px","")>=0&&f.css("top",-p*p)}):f.animate({top:--n},0,function(){f.css("top").replace("px","")<=-(p+n)*p&&f.css("top",-n*p)})}l.removeclass(f).eq(v).addclass(f),w=v,o||(r.removeclass("nextstop"),s.removeclass("prevstop"),0==v&&s.addclass("prevstop"),v==c-1&&r.addclass("nextstop")),o.html(""+(v+1)+"/"+c)}};q&&_(!0),k&&n.hover(function(){cleartimeout(d)},function(){d=settimeout(function(){v=z,q?_():"slidedown"==i?w.slideup(m,g):w.animate({opacity:"hide"},m,g),w=v},300)});var ee=function(e){j=setinterval(function(){y?v--:v++,_()},e?e:g)},te=function(e){j=setinterval(_,e?e:g)},ae=function(){b||(clearinterval(j),ee())},ne=function(){(o||v!=c-1)&&(v++,_(),u||ae())},ie=function(){(o||0!=v)&&(v--,_(),u||ae())},se=function(){clearinterval(j),u?te():ee(),u.removeclass("pausestate")},re=function(){clearinterval(j),u.addclass("pausestate")};if(c?u?(y?v--:v++,te(),b&&f.hover(re,se)):(ee(),b&&n.hover(re,se)):(u&&(y?v--:v++),u.addclass("pausestate")),u.click(function(){u.hasclass("pausestate")?se():re()}),"mouseover"==a.trigger?l.hover(function(){var e=l.index(this);b=settimeout(function(){v=e,_(),ae()},a.triggertime)},function(){cleartimeout(b)}):l.click(function(){v=l.index(this),_(),ae()}),u){if(r.mousedown(ne),s.mousedown(ie),o){var oe,ue=function(){oe=settimeout(function(){clearinterval(j),te(0^g/10)},150)},le=function(){cleartimeout(oe),clearinterval(j),te()};r.mousedown(ue),r.mouseup(le),s.mousedown(ue),s.mouseup(le)}"mouseover"==a.trigger&&(r.hover(ne,function(){}),s.hover(ie,function(){}))}else r.click(ne),s.click(ie)})}}(jquery),jquery.easing.jswing=jquery.easing.swing,jquery.extend(jquery.easing,{def:"easeoutquad",swing:function(e,t,a,n,i){return jquery.easing[jquery.easing.def](e,t,a,n,i)},easeinquad:function(e,t,a,n,i){return n*(t/=i)*t+a},easeoutquad:function(e,t,a,n,i){return-n*(t/=i)*(t-2)+a},easeinoutquad:function(e,t,a,n,i){return(t/=i/2)<1?n/2*t*t+a:-n/2*(--t*(t-2)-1)+a},easeincubic:function(e,t,a,n,i){return n*(t/=i)*t*t+a},easeoutcubic:function(e,t,a,n,i){return n*((t=t/i-1)*t*t+1)+a},easeinoutcubic:function(e,t,a,n,i){return(t/=i/2)<1?n/2*t*t*t+a:n/2*((t-=2)*t*t+2)+a},easeinquart:function(e,t,a,n,i){return n*(t/=i)*t*t*t+a},easeoutquart:function(e,t,a,n,i){return-n*((t=t/i-1)*t*t*t-1)+a},easeinoutquart:function(e,t,a,n,i){return(t/=i/2)<1?n/2*t*t*t*t+a:-n/2*((t-=2)*t*t*t-2)+a},easeinquint:function(e,t,a,n,i){return n*(t/=i)*t*t*t*t+a},easeoutquint:function(e,t,a,n,i){return n*((t=t/i-1)*t*t*t*t+1)+a},easeinoutquint:function(e,t,a,n,i){return(t/=i/2)<1?n/2*t*t*t*t*t+a:n/2*((t-=2)*t*t*t*t+2)+a},easeinsine:function(e,t,a,n,i){return-n*math.cos(t/i*(math.pi/2))+n+a},easeoutsine:function(e,t,a,n,i){return n*math.sin(t/i*(math.pi/2))+a},easeinoutsine:function(e,t,a,n,i){return-n/2*(math.cos(math.pi*t/i)-1)+a},easeinexpo:function(e,t,a,n,i){return 0==t?a:n*math.pow(2,10*(t/i-1))+a},easeoutexpo:function(e,t,a,n,i){return t==i?a+n:n*(-math.pow(2,-10*t/i)+1)+a},easeinoutexpo:function(e,t,a,n,i){return 0==t?a:t==i?a+n:(t/=i/2)<1?n/2*math.pow(2,10*(t-1))+a:n/2*(-math.pow(2,-10*--t)+2)+a},easeincirc:function(e,t,a,n,i){return-n*(math.sqrt(1-(t/=i)*t)-1)+a},easeoutcirc:function(e,t,a,n,i){return n*math.sqrt(1-(t=t/i-1)*t)+a},easeinoutcirc:function(e,t,a,n,i){return(t/=i/2)<1?-n/2*(math.sqrt(1-t*t)-1)+a:n/2*(math.sqrt(1-(t-=2)*t)+1)+a},easeinelastic:function(e,t,a,n,i){var s=1.70158,r=0,o=n;if(0==t)return a;if(1==(t/=i))return a+n;if(r||(r=.3*i),ot?-.5*o*math.pow(2,10*(t-=1))*math.sin(2*(t*i-s)*math.pi/r)+a:.5*o*math.pow(2,-10*(t-=1))*math.sin(2*(t*i-s)*math.pi/r)+n+a},easeinback:function(e,t,a,n,i,s){return void 0==s&&(s=1.70158),n*(t/=i)*t*((s+1)*t-s)+a},easeoutback:function(e,t,a,n,i,s){return void 0==s&&(s=1.70158),n*((t=t/i-1)*t*((s+1)*t+s)+1)+a},easeinoutback:function(e,t,a,n,i,s){return void 0==s&&(s=1.70158),(t/=i/2)<1?n/2*t*t*(((s*=1.525)+1)*t-s)+a:n/2*((t-=2)*t*(((s*=1.525)+1)*t+s)+2)+a},easeinbounce:function(e,t,a,n,i){return n-jquery.easing.easeoutbounce(e,i-t,0,n,i)+a},easeoutbounce:function(e,t,a,n,i){return(t/=i)<1/2.75?7.5625*n*t*t+a:2/2.75>t?n*(7.5625*(t-=1.5/2.75)*t+.75)+a:2.5/2.75>t?n*(7.5625*(t-=2.25/2.75)*t+.9375)+a:n*(7.5625*(t-=2.625/2.75)*t+.984375)+a},easeinoutbounce:function(e,t,a,n,i){return i/2>t?.5*jquery.easing.easeinbounce(e,2*t,0,n,i)+a:.5*jquery.easing.easeoutbounce(e,2*t-i,0,n,i)+.5*n+a}});