PageSourceSearch

https://situ.pro/template/rtj1009_010/static/js/jq_scroll.js

js situ.pro collected 2026-10-04 01:33:56 UTC 3,142 bytes, 60 lines download raw bytes

1/*
2jQ鍚戜笂婊氩姩甯︿笂涓嬬炕椤垫寜阍?
3*/
4(function($){
5$.fn.extend({
6        Scroll:function(opt,callback){
7                //鍙傛暟鍒濆鍖?
8                if(!opt) var opt={};
9                var _btnUp = $("#"+ opt.up);//Shawphy:鍚戜笂鎸夐挳
10                var _btnDown = $("#"+ opt.down);//Shawphy:鍚戜笅鎸夐挳
11                var timerID;
12                var _this=this.eq(0).find("ul:first");
13                var     lineH=_this.find("li:first").height(), //銮峰彇琛岄佩
14                        line=opt.line?parseInt(opt.line,10):parseInt(this.height()/lineH,10), //姣忔婊氩姩镄勮鏁帮紝榛樿涓轰竴灞忥紝鍗崇埗瀹瑰櫒楂桦害
15                        speed=opt.speed?parseInt(opt.speed,10):1000; //鍗峰姩阃熷害锛屾暟链艰秺澶э紝阃熷害瓒婃参锛堟绉掞级
16                        timer=opt.timer //?parseInt(opt.timer,10):3000; //婊氩姩镄勬椂闂撮棿闅旓纸姣锛?
17                if(line==0) line=1;
18                var upHeight=0-line*lineH;
19                //婊氩姩鍑芥暟
20                var scrollUp=function(){
21                        _btnUp.unbind("click",scrollUp); //Shawphy:鍙栨秷鍚戜笂鎸夐挳镄勫嚱鏁扮粦瀹?
22                        _this.animate({
23                                marginTop:upHeight
24                        },speed,function(){
25                                for(i=1;i<=line;i++){
26                                        _this.find("li:first").appendTo(_this);
27                                }
28                                _this.css({marginTop:0});
29                                _btnUp.bind("click",scrollUp); //Shawphy:缁戝畾鍚戜笂鎸夐挳镄勭偣鍑讳簨浠?
30                        });
31
32                }
33                //Shawphy:鍚戜笅缈婚〉鍑芥暟
34                var scrollDown=function(){
35                        _btnDown.unbind("click",scrollDown);
36                        for(i=1;i<=line;i++){
37                                _this.find("li:last").show().prependTo(_this);
38                        }
39                        _this.css({marginTop:upHeight});
40                        _this.animate({
41                                marginTop:0
42                        },speed,function(){
43                                _btnDown.bind("click",scrollDown);
44                        });
45                }
46               //Shawphy:镊姩鎾斁
47                var autoPlay = function(){
48                        if(timer)timerID = window.setInterval(scrollUp,timer);
49                };
50                var autoStop = function(){
51                        if(timer)window.clearInterval(timerID);
52                };
53                 //榧犳爣浜嬩欢缁戝畾
54                _this.hover(autoStop,autoPlay).mouseout();
55                _btnUp.css("cursor","pointer").click( scrollUp ).hover(autoStop,autoPlay);//Shawphy:鍚戜笂鍚戜笅榧犳爣浜嬩欢缁戝畾
56                _btnDown.css("cursor","pointer").click( scrollDown ).hover(autoStop,autoPlay);
57
58        }       
59})
60})(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.