1/*! 2 * SuperSlide v2.1.3 3 * è½»æ¾è§£å³ç½ç«å¤§é¨åç¹æå±ç¤ºé®é¢ 4 * 详尽信æ¯è¯·çå®ç½ï¼http://www.SuperSlide2.com/ 5 * 6 * Copyright 2011-è³ä», 大è¯ä¸»å¸ 7 * 8 * 请å°éååï¼ä¿ç头é¨çæ 9 * å¨ä¿ççæçåæä¸å¯åºç¨äºä¸ªäººæåä¸ç¨é 10 11 * v2.1.3ï¼å¤çJqueryå·²ç»å¼ç¨çAPIï¼å ¼å®¹ææ°çæ¬çJqueryï¼ç®åæ¯jquery3.3.1ï¼æ¥å妿åç°æä»¶ä¸å ¼å®¹æ°çæ¬çjqueryï¼è¯·èç³»æ
vendor: 11,473 bytes, lines 11-14
11 12 13 */ 14!function(a){a.fn.slide=function(b){return a.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 t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z,$,_,ab,bb,cb,db,eb,fb,gb,hb,ib,jb,kb,lb,mb,nb,c=a.extend({},a.fn.slide.defaults,b),d=a(this),e=c.effect,f=a(c.prevCell,d),g=a(c.nextCell,d),h=a(c.pageStateCell,d),i=a(c.playStateCell,d),j=a(c.titCell,d),k=j.length,l=a(c.mainCell,d),m=l.children().length,n=c.switchLoad,o=a(c.targetCell,d),p=parseInt(c.defaultIndex),q=parseInt(c.delayTime),r=parseInt(c.interTime);if(parseInt(c.triggerTime),t=parseInt(c.scroll),u="false"==c.autoPlay||0==c.autoPlay?!1:!0,v="false"==c.opp||0==c.opp?!1:!0,w="false"==c.autoPage||0==c.autoPage?!1:!0,x="false"==c.pnLoop||0==c.pnLoop?!1:!0,y="false"==c.mouseOverStop||0==c.mouseOverStop?!1:!0,z="false"==c.defaultPlay||0==c.defaultPlay?!1:!0,A="false"==c.returnDefault||0==c.returnDefault?!1:!0,B=isNaN(c.vis)?1:parseInt(c.vis),C=!-[1]&&!window.XMLHttpRequest,D=0,E=0,F=0,G=0,H=c.easing,I=null,J=null,K=null,L=c.titOnClassName,M=j.index(d.find("."+L)),N=p=-1==M?p:M,O=p,P=p,Q=m>=B?0!=m%t?m%t:t:0,S="leftMarquee"==e||"topMarquee"==e?!0:!1,T=function(){a.isFunction(c.startFun)&&c.startFun(p,k,d,a(c.titCell,d),l,o,f,g)},U=function(){a.isFunction(c.endFun)&&c.endFun(p,k,d,a(c.titCell,d),l,o,f,g)},V=function(){j.removeClass(L),z&&j.eq(O).addClass(L)},"menu"==c.type)return z&&j.removeClass(L).eq(p).addClass(L),j.hover(function(){R=a(this).find(c.targetCell);var b=j.index(a(this));J=setTimeout(function(){switch(p=b,j.removeClass(L).eq(p).addClass(L),T(),e){case"fade":R.stop(!0,!0).animate({opacity:"show"},q,H,U);break;case"slideDown":R.stop(!0,!0).animate({height:"show"},q,H,U)}},c.triggerTime)},function(){switch(clearTimeout(J),e){case"fade":R.animate({opacity:"hide"},q,H);break;case"slideDown":R.animate({height:"hide"},q,H)}}),A&&d.hover(function(){clearTimeout(K)},function(){K=setTimeout(V,q)}),void 0;if(0==k&&(k=m),S&&(k=2),w){if(m>=B?"leftLoop"==e||"topLoop"==e?k=0!=m%t?(0^m/t)+1:m/t:(W=m-B,k=1+parseInt(0!=W%t?W/t+1:W/t),0>=k&&(k=1)):k=1,j.html(""),X="",1==c.autoPage||"true"==c.autoPage)for(Y=0;k>Y;Y++)X+="<li>"+(Y+1)+"</li>";else for(Y=0;k>Y;Y++)X+=c.autoPage.replace("$",Y+1);j.html(X),j=j.children()}if(m>=B)switch(l.children().each(function(){a(this).width()>F&&(F=a(this).width(),E=a(this).outerWidth(!0)),a(this).height()>G&&(G=a(this).height(),D=a(this).outerHeight(!0))}),Z=l.children(),$=function(){var a;for(a=0;B>a;a++)Z.eq(a).clone().addClass("clone").appendTo(l);for(a=0;Q>a;a++)Z.eq(m-a-1).clone().addClass("clone").prependTo(l)},e){case"fold":l.css({position:"relative",width:E,height:D}).children().css({position:"absolute",width:F,left:0,top:0,display:"none"});break;case"top":l.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; height:'+B*D+'px"></div>').css({top:-(p*t)*D,position:"relative",padding:"0",margin:"0"}).children().css({height:G});break;case"left":l.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; width:'+B*E+'px"></div>').css({width:m*E,left:-(p*t)*E,position:"relative",overflow:"hidden",padding:"0",margin:"0"}).children().css({"float":"left",width:F});break;case"leftLoop":case"leftMarquee":$(),l.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; width:'+B*E+'px"></div>').css({width:(m+B+Q)*E,position:"relative",overflow:"hidden",padding:"0",margin:"0",left:-(Q+p*t)*E}).children().css({"float":"left",width:F});break;case"topLoop":case"topMarquee":$(),l.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; height:'+B*D+'px"></div>').css({height:(m+B+Q)*D,position:"relative",padding:"0",margin:"0",top:-(Q+p*t)*D}).children().css({height:G})}_=function(a){var b=a*t;return a==k?b=m:-1==a&&0!=m%t&&(b=-m%t),b},ab=function(b){var d,f,g,h,c=function(c){for(var d=c;B+c>d;d++)b.eq(d).find("img["+n+"]").each(function(){var c,d,b=a(this);if(b.attr("src",b.attr(n)).removeAttr(n),l.find(".clone")[0])for(c=l.children(),d=0;d<c.length;d++)c.eq(d).find("img["+n+"]").each(function(){a(this).attr(n)==b.attr("src")&&a(this).attr("src",a(this).attr(n)).removeAttr(n)})})};switch(e){case"fade":case"fold":case"top":case"left":case"slideDown":c(p*t);break;case"leftLoop":case"topLoop":c(Q+_(P));break;case"leftMarquee":case"topMarquee":d="leftMarquee"==e?l.css("left").replace("px",""):l.css("top").replace("px",""),f="leftMarquee"==e?E:D,g=Q,0!=d%f&&(h=Math.abs(0^d/f),g=1==p?Q+h:Q+h-1),c(g)}},bb=function(a){var b,c,d;if(!z||N!=p||a||S){if(S?p>=1?p=1:0>=p&&(p=0):(P=p,p>=k?p=0:0>p&&(p=k-1)),T(),null!=n&&ab(l.children()),o[0]&&(R=o.eq(p),null!=n&&ab(o),"slideDown"==e?(o.not(R).stop(!0,!0).slideUp(q),R.slideDown(q,H,function(){l[0]||U()})):(o.not(R).stop(!0,!0).hide(),R.animate({opacity:"show"},q,function(){l[0]||U()}))),m>=B)switch(e){case"fade":l.children().stop(!0,!0).eq(p).animate({opacity:"show"},q,H,function(){U()}).siblings().hide();break;case"fold":l.children().stop(!0,!0).eq(p).animate({opacity:"show"},q,H,function(){U()}).siblings().animate({opacity:"hide"},q,H);break;case"top":l.stop(!0,!1).animate({top:-p*t*D},q,H,function(){U()});break;case"left":l.stop(!0,!1).animate({left:-p*t*E},q,H,function(){U()});break;case"leftLoop":b=P,l.stop(!0,!0).animate({left:-(_(P)+Q)*E},q,H,function(){-1>=b?l.css("left",-(Q+(k-1)*t)*E):b>=k&&l.css("left",-Q*E),U()});break;case"topLoop":b=P,l.stop(!0,!0).animate({top:-(_(P)+Q)*D},q,H,function(){-1>=b?l.css("top",-(Q+(k-1)*t)*D):b>=k&&l.css("top",-Q*D),U()});break;case"leftMarquee":c=l.css("left").replace("px",""),0==p?l.animate({left:++c},0,function(){l.css("left").replace("px","")>=0&&l.css("left",-m*E)}):l.animate({left:--c},0,function(){l.css("left").replace("px","")<=-(m+Q)*E&&l.css("left",-Q*E)});break;case"topMarquee":d=l.css("top").replace("px",""),0==p?l.animate({top:++d},0,function(){l.css("top").replace("px","")>=0&&l.css("top",-m*D)}):l.animate({top:--d},0,function(){l.css("top").replace("px","")<=-(m+Q)*D&&l.css("top",-Q*D)})}j.removeClass(L).eq(p).addClass(L),N=p,x||(g.removeClass("nextStop"),f.removeClass("prevStop"),0==p&&f.addClass("prevStop"),p==k-1&&g.addClass("nextStop")),h.html("<span>"+(p+1)+"</span>/"+k)}},z&&bb(!0),A&&d.hover(function(){clearTimeout(K)},function(){K=setTimeout(function(){p=O,z?bb():"slideDown"==e?R.slideUp(q,V):R.animate({opacity:"hide"},q,V),N=p},300)}),cb=function(a){I=setInterval(function(){v?p--:p++,bb()},a?a:r)},db=function(a){I=setInterval(bb,a?a:r)},eb=function(){y||!u||i.hasClass("pauseState")||(clearInterval(I),cb())},fb=function(){(x||p!=k-1)&&(p++,bb(),S||eb())},gb=function(){(x||0!=p)&&(p--,bb(),S||eb())},hb=function(){clearInterval(I),S?db():cb(),i.removeClass("pauseState")},ib=function(){clearInterval(I),i.addClass("pauseState")},u?S?(v?p--:p++,db(),y&&l.hover(ib,hb)):(cb(),y&&d.hover(ib,hb)):(S&&(v?p--:p++),i.addClass("pauseState")),i.click(function(){i.hasClass("pauseState")?hb():ib()}),"mouseover"==c.trigger?j.hover(function(){var a=j.index(this);J=setTimeout(function(){p=a,bb(),eb()},c.triggerTime)},function(){clearTimeout(J)}):j.click(function(){p=j.index(this),bb(),eb()}),S?(g.mousedown(fb),f.mousedown(gb),x&&(kb=function(){jb=setTimeout(function(){clearInterval(I),db(0^r/10)},150)},lb=function(){clearTimeout(jb),clearInterval(I),db()},g.mousedown(kb),g.mouseup(lb),f.mousedown(kb),f.mouseup(lb)),"mouseover"==c.trigger&&(g.hover(fb,function(){}),f.hover(gb,function(){}))):(g.click(fb),f.click(gb)),"auto"!=c.vis||1!=t||"left"!=e&&"leftLoop"!=e||(nb=function(){C&&(l.width("auto"),l.children().width("auto")),l.parent().width("auto"),E=l.parent().width(),C&&l.parent().width(E),l.children().width(E),"left"==e?(l.width(E*m),l.stop(!0,!1).animate({left:-p*E},0)):(l.width(E*(m+2)),l.stop(!0,!1).animate({left:-(p+1)*E},0)),C||E==l.parent().width()||nb()},a(window).resize(function(){clearTimeout(mb),mb=setTimeout(nb,100)}),nb())})}}(jQuery),jQuery.easing["jswing"]=jQuery.easing["swing"],jQuery.extend(jQuery.easing,{def:"easeOutQuad",swing:function(a,b,c,d,e){return jQuery.easing[jQuery.easing.def](a,b,c,d,e)},easeInQuad:function(a,b,c,d,e){return d*(b/=e)*b+c},easeOutQuad:function(a,b,c,d,e){return-d*(b/=e)*(b-2)+c},easeInOutQuad:function(a,b,c,d,e){return(b/=e/2)<1?d/2*b*b+c:-d/2*(--b*(b-2)-1)+c},easeInCubic:function(a,b,c,d,e){return d*(b/=e)*b*b+c},easeOutCubic:function(a,b,c,d,e){return d*((b=b/e-1)*b*b+1)+c},easeInOutCubic:function(a,b,c,d,e){return(b/=e/2)<1?d/2*b*b*b+c:d/2*((b-=2)*b*b+2)+c},easeInQuart:function(a,b,c,d,e){return d*(b/=e)*b*b*b+c},easeOutQuart:function(a,b,c,d,e){return-d*((b=b/e-1)*b*b*b-1)+c},easeInOutQuart:function(a,b,c,d,e){return(b/=e/2)<1?d/2*b*b*b*b+c:-d/2*((b-=2)*b*b*b-2)+c},easeInQuint:function(a,b,c,d,e){return d*(b/=e)*b*b*b*b+c},easeOutQuint:function(a,b,c,d,e){return d*((b=b/e-1)*b*b*b*b+1)+c},easeInOutQuint:function(a,b,c,d,e){return(b/=e/2)<1?d/2*b*b*b*b*b+c:d/2*((b-=2)*b*b*b*b+2)+c},easeInSine:function(a,b,c,d,e){return-d*Math.cos(b/e*(Math.PI/2))+d+c},easeOutSine:function(a,b,c,d,e){return d*Math.sin(b/e*(Math.PI/2))+c},easeInOutSine:function(a,b,c,d,e){return-d/2*(Math.cos(Math.PI*b/e)-1)+c},easeInExpo:function(a,b,c,d,e){return 0==b?c:d*Math.pow(2,10*(b/e-1))+c},easeOutExpo:function(a,b,c,d,e){return b==e?c+d:d*(-Math.pow(2,-10*b/e)+1)+c},easeInOutExpo:function(a,b,c,d,e){return 0==b?c:b==e?c+d:(b/=e/2)<1?d/2*Math.pow(2,10*(b-1))+c:d/2*(-Math.pow(2,-10*--b)+2)+c},easeInCirc:function(a,b,c,d,e){return-d*(Math.sqrt(1-(b/=e)*b)-1)+c},easeOutCirc:function(a,b,c,d,e){return d*Math.sqrt(1-(b=b/e-1)*b)+c},easeInOutCirc:function(a,b,c,d,e){return(b/=e/2)<1?-d/2*(Math.sqrt(1-b*b)-1)+c:d/2*(Math.sqrt(1-(b-=2)*b)+1)+c},easeInElastic:function(a,b,c,d,e){var f=1.70158,g=0,h=d;return 0==b?c:1==(b/=e)?c+d:(g||(g=.3*e),h<Math.abs(d)?(h=d,f=g/4):f=g/(2*Math.PI)*Math.asin(d/h),-(h*Math.pow(2,10*(b-=1))*Math.sin((b*e-f)*2*Math.PI/g))+c)},easeOutElastic:function(a,b,c,d,e){var f=1.70158,g=0,h=d;return 0==b?c:1==(b/=e)?c+d:(g||(g=.3*e),h<Math.abs(d)?(h=d,f=g/4):f=g/(2*Math.PI)*Math.asin(d/h),h*Math.pow(2,-10*b)*Math.sin((b*e-f)*2*Math.PI/g)+d+c)},easeInOutElastic:function(a,b,c,d,e){var f=1.70158,g=0,h=d;return 0==b?c:2==(b/=e/2)?c+d:(g||(g=e*.3*1.5),h<Math.abs(d)?(h=d,f=g/4):f=g/(2*Math.PI)*Math.asin(d/h),1>b?-.5*h*Math.pow(2,10*(b-=1))*Math.sin((b*e-f)*2*Math.PI/g)+c:.5*h*Math.pow(2,-10*(b-=1))*Math.sin((b*e-f)*2*Math.PI/g)+d+c)},easeInBack:function(a,b,c,d,e,f){return void 0==f&&(f=1.70158),d*(b/=e)*b*((f+1)*b-f)+c},easeOutBack:function(a,b,c,d,e,f){return void 0==f&&(f=1.70158),d*((b=b/e-1)*b*((f+1)*b+f)+1)+c},easeInOutBack:function(a,b,c,d,e,f){return void 0==f&&(f=1.70158),(b/=e/2)<1?d/2*b*b*(((f*=1.525)+1)*b-f)+c:d/2*((b-=2)*b*(((f*=1.525)+1)*b+f)+2)+c},easeInBounce:function(a,b,c,d,e){return d-jQuery.easing.easeOutBounce(a,e-b,0,d,e)+c},easeOutBounce:function(a,b,c,d,e){return(b/=e)<1/2.75?d*7.5625*b*b+c:2/2.75>b?d*(7.5625*(b-=1.5/2.75)*b+.75)+c:2.5/2.75>b?d*(7.5625*(b-=2.25/2.75)*b+.9375)+c:d*(7.5625*(b-=2.625/2.75)*b+.984375)+c},easeInOutBounce:function(a,b,c,d,e){return e/2>b?.5*jQuery.easing.easeInBounce(a,2*b,0,d,e)+c:.5*jQuery.easing.easeOutBounce(a,2*b-e,0,d,e)+.5*d+c}});
14 15 16//å å ¥æ¶è å ¼å®¹360åIE6 17function shoucang(sTitle, sURL) { 18 try { 19 window.external.addFavorite(sURL, sTitle); 20 } catch(e) { 21 try { 22 window.sidebar.addPanel(sTitle, sURL, ""); 23 } catch(e) { 24 alert("å å ¥æ¶è失败ï¼è¯·ä½¿ç¨Ctrl+Dè¿è¡æ·»å "); 25 } 26 } 27} 28 29//个人éèå表 30$(".ul_nav>li").click(function(){ 31 $(this).children("ol").slideToggle().end().siblings().children("ol").slideUp(); 32 $(this).toggleClass("active").siblings().removeClass("active") 33}) 34 35var nowDate = new Date(); 36var cssLink= document.createElement("link"); 37cssLink.type="text/css"; 38cssLink.rel="stylesheet"; 39cssLink.href="/drcbank_news/template/common/gray/gray.css?timestamp="+nowDate.getTime(); 40document.getElementsByTagName("head")[0].appendChild(cssLink); 41 42$(document).ready(function(){ 43 //头é¨å¯¼èªæ»å¨ç¹æ 44 var prevall, acttwidth, actiwidth; 45 function actmove() { 46 prevall = $(".pub_nav_active").parent().prevAll(); 47 acttwidth = $(".pub_nav_active").parent().innerWidth(); 48 actiwidth = 0; 49 for(var i = 0; i < prevall.length; i++) { 50 actiwidth += prevall.eq(i).innerWidth(); 51 } 52 $(".pub_nav_act").css("width", acttwidth).stop().animate({ 53 left: actiwidth 54 }, 300) 55 } 56 actmove(); 57 $(".pub_nav>div").hover(function() { 58 var prevall = $(this).prevAll(); 59 var acttwidth = $(this).innerWidth(); 60 var actiwidth = 0; 61 for(var i = 0; i < prevall.length; i++) { 62 actiwidth += prevall.eq(i).innerWidth(); 63 } 64 $(".pub_nav_act").css("width", acttwidth).stop().animate({ 65 left: actiwidth 66 }, 500) 67 }, function() { 68 actmove(); 69 }) 70 71if($(".person_ul .tr").length==0){ 72 $(".person_ul").append("<li class='noresult'>ææ æèä¿¡æ¯ï¼</li>"); 73} 74 75 //é¦é¡µå¢å åé¡µå¨ 76 if($("#slideBox").length>0){ 77 $("#slideBox .bd ul li:hidden").remove(); 78 var list = $("#slideBox .bd ul li").length; 79 for($i=0;$i<list;$i++){ 80 $("#slideBox .hd ul").append("<li><div></div></li>"); 81 var child = $("#slideBox .bd ul li").eq($i).find('a'); 82 if(child.attr('title') === 'talentRecruitment'){ 83 var newHref = child.attr('attr-href') 84 child.attr('href',newHref) 85 } 86 } 87 } 88 $(".slideBox").slide({mainCell:".bd ul",effect:"fold",autoPlay:true,interTime:4000,delayTime:2000}); 89 90//è¥ä¸ç½ç¹åå®½å ¼å®¹ie8 91$(".stores tr").each(function(){ 92$(this).find("td").eq(0).addClass("first"); 93$(this).find("td").eq(1).addClass("two"); 94$(this).find("td").eq(2).addClass("three"); 95$(this).find("td").eq(3).addClass("four"); 96$(this).find("td").eq(4).addClass("five"); 97}) 98 99 //å¦æè½®æåªæä¸é¡µæ¶éèæé® 100 if($("#slideBox .bd ul li").length>1){ 101 $("#slideBox .hd").show(); 102 } 103 104 //ä¾§è¾¹æ äºç»´ç å ³éæé® 105 $('.ewm>.del').click(function(){ 106 $(this).parents('.ewm').remove() 107 }) 108 109 //ä¾§è¾¹å¯¼èªæå 110 $(".pub_aside ul > li > em").click(function(){ 111 if($(this).parent().hasClass("active")){ 112 $(this).parent().removeClass("active"); 113 } else { 114 $(this).parent().addClass("active").siblings().removeClass("active"); 115 } 116 }) 117 118 //é¢å å±ä¿®æ¹åç§° 119 if($("#sourcebreadID").length>0){ 120 var ss = document.getElementById('sourcebreadID').getElementsByTagName("a"); 121 for(i=0;i<ss.length;i++){ 122 if(i==0){ 123 ss[i].innerText="ä¸èåæåä¸é¶è¡" 124 } 125 } 126 } 127 128 //é¢éæ¹éæ·»å å ¼å®¹ie8ç±» 129 if($(".list_type3").length>0){ 130 $(".list_type3").each(function(){ 131 $(this).find("li").each(function(){ 132 var num = $(this).index()+1; 133 $(this).addClass("inter"+num); 134 }) 135 }) 136 } 137 138//ç财计ç®å¨ 139if($(".mod-lcgj").length>0){ 140function setCurLoc(obj, extPath){ 141 var $obj = $(obj), $obj_li = $obj.find("li"), extPath = extPath || "/"; 142 var href = window.location.pathname, http_hostname = "http://" + window.location.hostname, http_host = "http://" + window.location.host; 143 if(href == http_hostname || href == http_hostname + extPath || href == http_host || href == http_host + extPath){ 144 $obj_li.each(function(){ 145 var a_href = $(this).children("a").attr("href"); 146 if(a_href == http_hostname || a_href == http_host || a_href == extPath){ 147 $(this).addClass("cur").children("a").addClass("cur"); 148 return false;
149 } 150 }); 151 return true; 152 } 153 if(!$("body").hasClass("pNavNoSub")){ 154 $obj_li.each(function(){ 155 var a_href = $(this).children("a").attr("href").replace(/\?.*/, ""); 156 if(href.indexOf(a_href) == 0 && a_href != "/" && a_href != extPath){ 157 $(this).addClass("cur").children("a").addClass("cur"); 158 //return false; 159 } 160 $(this).find("div.subNav a").each(function(i){ 161 var a_href = $(this).attr("href").replace(/\?.*/, ""); 162 if(href == "/ebank/" && i == 0){ 163 $(this).addClass("cur"); 164 return false; 165 } 166 if(href.indexOf(a_href) == 0 && a_href != "/ebank/" && a_href != "/" && a_href != extPath){ 167 $(this).addClass("cur"); 168 return false; 169 } 170 }); 171 }); 172 } 173} 174 175var FA_shift_opts = { 176 def : { 177 method : "basic", 178 $contWrap : ".cont", 179 $cont : ".cont > a", 180 $navWrap : ".nav", 181 $nav : ".nav > a", 182 $titleWrap : ".title", 183 $title : ".title > h3", 184 curClass: "cur", 185 shiftBy : "hover", 186 pause : 5000, 187 spd : 500, 188 index : 0, 189 auto : true, 190 lazy : true 191 }, 192 tabs : { 193 method : "basic", 194 auto : false 195 }, 196 fadeByArrow : { 197 method : "fadeByArrow", 198 $nav : ".noNav", 199 $prev : ".prev", 200 $next : ".next", 201 spd : 1000 202 } 203 }, 204 FA_shift_methods = { 205 auto : function(o, run){ 206 clearInterval(o.temp.interval); 207 return setInterval(function(){ o.run(o, o.temp.index==(o.temp.len-1) ? 0 : o.temp.index+1); }, o.pause); 208 }, 209 shiftBy : function($nav, o, i){ 210 switch(o.shiftBy){ 211 case "hover": 212 $nav.hover( 213 function(){o.temp.index = o.run(o, i);} 214 ); 215 break; 216 case "click": 217 $nav.click(function(){ 218 var returVal = true; 219 if(!$(this).hasClass(o.curClass)){ 220 returVal = false; 221 } 222 o.temp.index = o.run(o, i); 223 return returVal; 224 }); 225 break; 226 }; 227 }, 228 exMethods : { 229 basic : function(o){ 230 var auto = FA_shift_methods.auto; 231 232 o.$this = $(this), o.$cont = o.$this.find(o.$cont), o.$nav = o.$this.find(o.$nav), o.$contWrap = o.$this.find(o.$contWrap), o.$navWrap = o.$this.find(o.$navWrap), o.$title = o.$this.find(o.$title), o.$titleWrap = o.$this.find(o.$titleWrap), 233 o.temp = { 234 len : o.$cont.length, 235 index : o.index, 236 arr : [] 237 }, 238 o.run = o.run || function(o, i){ 239 if(i != o.temp.index){ 240 o.temp.arr = [o.$cont, o.$nav]; 241 while(o.temp.arr.length){ 242 var t = o.temp.arr.pop(); 243 t.eq(o.temp.index).removeClass(o.curClass); 244 t.eq(i).addClass(o.curClass); 245 } 246 o.temp.index = i; 247 } 248 return o.temp.index; 249 }; 250 251 o.$cont.eq(o.index).addClass(o.curClass); 252 o.$nav.eq(o.index).addClass(o.curClass); 253 if(o.auto){ 254 o.temp.interval = auto(o, o.run); 255 o.temp.arr = [o.$contWrap, o.$navWrap, o.$titleWrap]; 256 while(o.temp.arr.length){ 257 o.temp.arr.pop().hover( 258 function(){ clearInterval(o.temp.interval); }, 259 function(){ o.temp.interval = auto(o, o.run); } 260 ); 261 } 262 } 263 o.$nav.each(function(i){ 264 FA_shift_methods.shiftBy($(this), o ,i); 265 }); 266 }, 267 fadeByArrow : function(o){ 268 o.run = o.run || function(o, i){ 269 if(i != o.temp.index){ 270 var arr = [o.$nav]; 271 o.$cont.hide().eq(o.temp.index).stop().removeAttr("style").show().removeClass(o.curClass).end() 272 .eq(i).fadeIn(o.spd).addClass(o.curClass); 273 274 while(arr.length){ 275 var t = arr.pop(); 276 t.eq(o.temp.index).removeClass(o.curClass); 277 t.eq(i).addClass(o.curClass); 278 } 279 280 o.temp.index = i; 281 } 282 return o.temp.index; 283 }; 284 285 FA_shift_methods.exMethods["basic"].call(this, o); 286 o.$prev = $(this).find(o.$prev), o.$next = $(this).find(o.$next); 287 288 o.$prev.click(function(){ 289 var i; 290 i = o.temp.index - 1 < 0 ? o.temp.len - 1 : o.temp.index - 1; 291 o.run(o, i); 292 }); 293 294 o.$next.click(function(){ 295 var i; 296 i = o.temp.index + 1 > o.temp.len - 1 ? 0 : o.temp.index + 1; 297 o.run(o, i); 298 }); 299 } 300 } 301 }; 302 303 $.fn.FA_shift = function(method, opts){ 304 var o = $.extend({}, FA_shift_opts.def, FA_shift_opts[method], opts); 305 306 return this.each(function(){ 307 FA_shift_methods.exMethods[o.method].call(this, o); 308 }); 309 } 310 311 $.fn.FA_searchBar = function(o){ 312 var o = $.extend({ 313 txt: ".txt", 314 btn: ".btn", 315 val: null 316 }, o); 317 318 o.selector = $(this).selector; 319 320 return this.each(function(){ 321 var $t = $(this), $txt = $(o.txt, $t), $btn = $(o.btn, $t), $txt_val = o.val || $txt.val(); 322 323 $txt.focus(function(){ 324 if(/^[\s]*$/.test($txt.val()) || $txt.val() == $txt_val){ 325 $txt.val(""); 326 } 327 }).blur(function(){ 328 if(/^[\s]*$/.test($txt.val()) || $txt.val() == $txt_val){ 329 $txt.val($txt_val); 330 } 331 }); 332 333 $t.submit(function(){ 334 if(/^[\s]*$/.test($txt.val()) || $txt.val() == $txt_val){ 335 $txt.focus(); 336 return false;
337 } 338 }); 339 }); 340 } 341 342 $.fn.FA_select = function(opts){ 343 var o = $.extend({ 344 valWrap : ".FA_selVal", 345 valTxt : ".FA_selVal .txt", 346 optWrap : ".FA_selOpt", 347 opt : ".FA_selOpt li", 348 hoverClass : "hover", 349 curClass : "cur", 350 defIndex : false 351 }, opts); 352 return this.each(function(i){ 353 var $this = $(this), $valWrap = $(o.valWrap, $this), $valTxt = $(o.valTxt, $this), $optsWrap, $opts, $wrap, 354 className = $this.attr("class"), id, oNum = i; 355 356 id = className.replace(" ", "_") + "_FA_sel_"; 357 while(true){ 358 if(!$("#" + id + oNum).size()){ 359 $wrap = $("<div id='" + id + oNum + "' style='position:absolute;z-index:99999;top:-9999px;left:-9999px;background:url(#);'></div>"); 360 break; 361 } 362 ++oNum; 363 } 364 $optsWrap = $this.find(o.optWrap).appendTo($wrap); 365 $("body").append($wrap); 366 $opts = $wrap.find(o.opt); 367 368 $wrap.click(function(){ 369 $wrap.css({top : "-9999px", left : "-9999px"}); 370 }).hover( 371 function(){}, 372 function(){$wrap.css({top : "-9999px", left : "-9999px"});} 373 ); 374 375 if(o.defIndex != false){ 376 $valTxt.text($opts.eq(o.defIndex).addClass(o.curClass).text()) 377 }; 378 $valWrap.click(function(){ 379 var $win = $(window), scrollTop = $win.scrollTop(), scrollLeft = $win.scrollLeft(), pos = $valWrap.offset(), 380 w = $valWrap.outerWidth() ,h = $valWrap.outerHeight(), $optsWrap_h = $optsWrap.outerHeight(); 381 if($optsWrap_h + h + pos.top - scrollTop > $win.height() && $optsWrap_h < $win.height()){ 382 $wrap.css("padding", "0 0 " + h + "px").css({width : w, top : pos.top - $optsWrap_h, left : pos.left + scrollLeft}); 383 }else{ 384 $wrap.css("padding", h + "px 0 0").css({width : w, top : pos.top , left : pos.left + scrollLeft}); 385 } 386 }); 387 388 $opts.click(function(){ 389 $opts.removeClass(o.curClass); 390 $(this).addClass(o.curClass); 391 $valTxt.text($(this).text()); 392 $wrap.css({top : "-9999px", left : "-9999px"}); 393 }).hover( 394 function(){$(this).addClass(o.hoverClass);}, 395 function(){$(this).removeClass(o.hoverClass);} 396 ); 397 }); 398 } 399 400 $.fn.rollpic = function(o){ 401 var o = $.extend({ 402 pause:5000, 403 nspd:1000, 404 uspd:300, 405 vnum:5, 406 snum:1, 407 start:0, 408 isH:true, 409 auto:true 410 }, o||{}); 411 412 return this.each(function(){ 413 var $cont = $(".sp-cont", this), 414 $prev = $(".next", this), $next = $(".prev", this), 415 $a = $cont.children("a"), len = $a.length, v=o.vnum; 416 if(len<=v){return false;} 417 $cont.prepend($a.slice(len-v-1+1).clone(true)).append($a.slice(0,v).clone(true)); 418 o.start += v; 419 var curr = o.start; 420 421 var interval = null, a_dir = o.isH ? "marginLeft":"marginTop", c_dir = "left", 422 aSize = o.isH ? $a.outerWidth(true) : $a.outerHeight(true), contDS
422= o.isH ? "width" : "height", 423 itemLength = $cont.children("a").size(); 424 $cont.css(contDS, itemLength*aSize).css(a_dir, -(curr*aSize)); 425 426 var isOver = true; 427 428 if(o.auto){ 429 $cont.hover(function(){ 430 clearInterval(interval); 431 }, function(){ 432 if(c_dir == "left"){ 433 interval = setInterval(function(){ roll(curr+o.snum)}, o.pause); 434 }else if(c_dir == "right"){ 435 interval = setInterval(function(){ roll(curr-o.snum)}, o.pause); 436 } 437 }); 438 } 439 if($prev){ 440 $prev.click(function(){ 441 if(o.auto){clearInterval(interval)}; 442 if(isOver==true){roll(curr-o.snum, o.uspd);c_dir = "right";}; 443 if(o.auto){interval = setInterval(function(){ roll(curr-o.snum)}, o.pause)}; 444 }); 445 } 446 if($next){ 447 $next.click(function(){ 448 if(o.auto){clearInterval(interval)}; 449 if(isOver==true){roll(curr+o.snum, o.uspd); c_dir = "left";}; 450 if(o.auto){interval = setInterval(function(){ roll(curr+o.snum)}, o.pause)}; 451 }); 452 } 453 if(o.auto){ interval = setInterval(function(){ roll(curr+o.snum)}, o.pause);} 454 function roll(to, spd){ 455 if(isOver){ 456 var spd = spd || o.nspd 457 isOver = false; 458 if(to<=o.start-v-1){ 459 $cont.css(a_dir, -((v+(len-v)+curr)*aSize)+"px"); 460 curr = (v+(len-v)+curr)-o.snum; 461 }else if(to>=itemLength-v+1) { 462 $cont.css(a_dir, -( (v-(itemLength-v-curr)) * aSize ) + "px" ); 463 curr = (v-(itemLength-v-curr))+o.snum; 464 }else curr = to; 465 466 $cont.animate( 467 a_dir == "marginLeft" ? {"marginLeft": -(curr*aSize) } : {"marginTop": -(curr*aSize) } , spd, function(){isOver = true;} 468 ); 469 } 470 return false; 471 }; 472 473 }); 474 } 475 476 /* rollpic1 */ 477 $.fn.rollpic1 = function(o){ 478 var o = $.extend({ 479 pause:8000, 480 nspd:800, 481 uspd:300, 482 isH:true, 483 auto:true 484 }, o||{}); 485 return this.each(function(){ 486 var $cont = $(".sp-cont", this), 487 $prev = $(".prev", this), $next = $(".next", this), 488 $a = $cont.children("span"), len = $a.length; 489 $cont.append($a.clone(true)); 490 var interval = null, a_dir = o.isH ? (['left', 'right']):(['top', 'bottom']), cdir = a_dir[0], 491 aSize = o.isH ? $a.outerWidth(true) : $a.outerHeight(true), contDS
491= o.isH ? "width" : "height"; 492 $cont.css(contDS, 2*len*aSize); 493 var isOver = true; 494 if(o.auto){ 495 $cont.hover(function(){ 496 clearInterval(interval); 497 }, function(){ 498 interval = setInterval(function(){ roll(cdir)}, o.pause); }); 499 } 500 if($prev){ 501 $prev.click(function(){ 502 if(o.auto){clearInterval(interval)}; 503 if(isOver==true){roll(a_dir[1], o.uspd)}; 504 if(o.auto){interval = setInterval(function(){ roll(cdir)}, o.pause)}; 505 }); 506 } 507 if($next){ 508 $next.click(function(){ 509 if(o.auto){clearInterval(interval)}; 510 if(isOver==true){roll(a_dir[0], o.uspd)}; 511 if(o.auto){interval = setInterval(function(){ roll(cdir)}, o.pause)}; 512 }); 513 } 514 if(o.auto){ interval = setInterval(function(){ roll(cdir)}, o.pause);} 515 function roll(dir, spd){ 516 var spd = spd || o.nspd 517 isOver = false; 518 switch(dir){ 519 case "left": 520 if(parseFloat($cont.css("marginLeft")) == -(len*aSize)){ 521 $cont.css({"marginLeft": 0}); 522 } 523 $cont.animate({"marginLeft": "-="+aSize}, spd, function(){isOver = true;}); 524 break; 525 case "right": 526 if(parseFloat($cont.css("marginLeft")) == 0){ 527 $cont.css({"marginLeft": -(len*aSize)}) 528 } 529 $cont.animate({"marginLeft": "+="+aSize}, spd, function(){isOver = true;}); 530 break; 531 case "top": 532 if(parseFloat($cont.css("marginTop")) == -(len*aSize)){ 533 $cont.css({"marginTop": 0}); 534 } 535 $cont.animate({"marginTop": "-="+aSize}, spd, function(){isOver = true;}); 536 break; 537 case "bottom": 538 if(parseFloat($cont.css("marginTop")) == 0){ 539 $cont.css({"marginTop": -(len*aSize)}) 540 } 541 $cont.animate({"marginTop": "+="+aSize}, spd, function(){isOver = true;}); 542 break; 543 default: 544 return; 545 } 546 }; 547 }); 548 } 549 550 $.fn.pcont = function(o){ 551 var o = $.extend({ 552 snum:5, 553 pause:5000, 554 spd:500, 555 fspd:500, 556 auto:true 557 }, o); 558 559 return this.each(function(){ 560 var $sprev = $(".sprev", this), $snext = $(".snext", this), $bprev = $(".bprev", this), $bnext = $(".bnext", this), 561 $nav = $(".pc-nav .nav-wrap", this), 562 $cont = $(".pc-cont ul>li", this), $info = $(".pc-info ul>li", this), 563 $nava = $nav.children("a"), len = $nava.length, aSize = $nava.outerWidth(true), navbS = o.snum*aSize; 564 565 $nav.css("width", len*aSize*2);//$(".pc-nav .nav-box", this).css("width", navbS) 566 var index = 0, interval = null, cml; 567 if(len*aSize > navbS){ 568 $sprev.click(function(){ 569 if(o.auto) clearInterval(interval); 570 cml = Math.abs(parseFloat($nav.css("marginLeft"))); 571 if(cml < aSize){ 572 $nav.animate({"marginLeft": 0}, o.spd); 573 }else if(cml > 0){ 574 $nav.animate({"marginLeft": "+="+aSize}, o.spd); 575 } 576 if(o.auto){ auto();} 577 return false; 578 }); 579 $snext.click(function(){ 580 if(o.auto) clearInterval(interval); 581 cml = Math.abs(parseFloat($nav.css("marginLeft"))); 582 if((len*aSize-cml-navbS) < aSize){ 583 $nav.animate({"marginLeft": "-"+(len*aSize-navbS)}, o.spd); 584 }else if(cml <= ((len-o.snum)*aSize)){ 585 $nav.animate({"marginLeft": "-="+aSize}, o.spd); 586 } 587 if(o.auto){ auto();} 588 return false; 589 }); 590 } 591 592 $bprev.click(function(){ 593 if(o.auto) clearInterval(interval); 594 if(index>0){roll(index-1);} 595 if(o.auto){ auto();} 596 return false; 597 }); 598 $bnext.click(function(){ 599 if(o.auto) clearInterval(interval); 600 if(index<(len-1)){roll(index+1);} 601 if(o.auto){ auto();} 602 return false; 603 }); 604 $nava.each(function(i){ 605 $(this).click(function(){ 606 if(o.auto) clearInterval(interval); 607 roll(i); 608 if(o.auto){ auto();} 609 return false; 610 }); 611 }); 612 function auto(){ 613 interval = setInterval(function(){ roll(index==(len-1) ? 0 : (index+1))}, o.pause); 614 } 615 function roll(i){ 616 cml = Math.abs(parseFloat($nav.css("marginLeft"))); 617 if((i+1)*aSize <= cml){ 618 $nav.animate({"marginLeft": "-"+(i*aSize)}, o.spd); 619 }else if((i+1)*aSize > (cml+navbS)){ 620 $nav.animate({"marginLeft": "-"+((i+1)*aSize-navbS)}, o.spd); 621 } 622 $nava.removeClass("hover"); 623 $nava.eq(i).addClass("hover"); 624 $cont.hide(); 625 $cont.eq(i).fadeIn(o.fspd); 626 $info.hide(); 627 $info.eq(i).show(); 628 index = i; 629 } 630 /*init*/ 631 if(o.auto){ auto(); } 632 $cont.eq(index).show(); 633 $nava.eq(index).addClass("hover"); 634 $info.eq(index).show(); 635 }); 636 }; 637 638} 639})
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.