1 2// function reurl(){ 3// url = location.href;var times = url.split("?"); 4// if(times[1] != 1){url += "?1"; self.location.replace(url);} 5// } 6// onload=reurl ; 7 8 9$(document).ready(function () { 10 var box0 = $(".one"),v0 = 0.5; //è¿éæ·»å æ»å¨ç对象åå ¶éç 11 var box1 = $(".two"),v1 = 1; 12 Rin(box0,v0); 13 Rin(box1,v1); 14 15 function Rin($Box,v){//$Boxç§»å¨ç对象ï¼v对象移å¨çéç 16 var $Box_ul = $Box.find("ul"), 17 $Box_li = $Box_ul.find("li"), 18 $Box_li_span = $Box_li.find("span"), 19 left = 0, 20 s=0, 21 timer;//宿¶å¨ 22 23 $Box_li.each(function(index){ 24 $($Box_li_span[index]).width($(this).width());//hover 25 s += $(this).outerWidth(true); //å³è¦æ»å¨çé¿åº¦ 26 }) 27 28 window.requestAnimationFrame = window.requestAnimationFrame||function(Tmove){return setTimeout(Tmove,1000/60)}; 29 window.cancelAnimationFrame = window.cancelAnimationFrame||clearTimeout; 30 31 if( s>=$Box.width()){//妿æ»å¨é¿åº¦è¶ åºBoxé¿åº¦å³å¼å§æ»å¨ï¼æ²¡æçè¯å°±ä¸æ§è¡æ»å¨ 32 $Box_li.clone(true).appendTo($Box_ul); 33 Tmove(); 34 function Tmove(){ 35 //è¿å¨æ¯ç§»å¨left ä»0å°-s;ï¼ä¸ªäººä¹ æ¯å¾å·¦æ»ï¼ 36 left -= v; 37 if(left <= -s){left = 0;$Box_ul.css("left",left)}else{ $Box_ul.css("left",left) } 38 timer = requestAnimationFrame(Tmove); 39 } 40 $Box_ul.hover(function(){cancelAnimationFrame(timer)},function(){Tmove()}) 41 } 42 43 } 44})
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.