PageSourceSearch

https://wisniowa.malopolska.pl/asp/jscore/slides.min.jquery.js

js wisniowa.malopolska.pl collected 2026-10-10 00:32:31 UTC 18,221 bytes, 437 lines download raw bytes

1/*
2* Slides, A Slideshow Plugin for jQuery
3* Intructions: http://slidesjs.com
4* By: Nathan Searles, http://nathansearles.com
5* Version: 1.1.6
6* Updated: March 23th, 2011
7*
8* Licensed under the Apache License, Version 2.0 (the "License");
9* you may not use this file except in compliance with the License.
10* You may obtain a copy of the License at
11*
12* http://www.apache.org/licenses/LICENSE-2.0
13*
14* Unless required by applicable law or agreed to in writing, software
15* distributed under the License is distributed on an "AS IS" BASIS,
16* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17* See the License for the specific language governing permissions and
18* limitations under the License.
19*/
20
21(function($) {
22    $.fn.slides=function(g) {
23        g=$.extend( {
24        }
25        ,$.fn.slides.option,g);
26        return this.each(function() {
27            $('.'+g.flash_main,$(this)).children().wrapAll('<div class="slides_control"/>');
28            var d=$(this),control=$('.slides_control',d),total=control.children().size(),width=control.children().outerWidth(),height=control.children().outerHeight(),start=g.start-1,effect=g.effect.indexOf(',')<0?g.effect:g.effect.replace(' ','').split(',')[0],paginationEffect=g.effect.indexOf(',')<0?effect:g.effect.replace(' ','').split(',')[1],next=0,prev=0,number=0,current=0,loaded,active,clicked,position,direction,imageParent,pauseTimeout,playInterval;
29
30            function animate(a,b,c) {
31                if(!active&&loaded) {
32                    active=true;
33                    g.animationStart(current+1);
34                    switch(a) {
35                        case'next':prev=current;
36                        next=current+1;
37                        next=total===next?0:next;
38                        position=width*2;
39                        a=-width*2;
40                        current=next;
41                        break;
42                        case'prev':prev=current;
43                        next=current-1;
44                        next=next===-1?total-1:next;
45                        position=0;
46                        a=0;
47                        current=next;
48                        break;
49                        case'pagination':next=parseInt(c,10);
50                        prev=$('.'+g.paginationClass+' li.current a',d).attr('href').match('[^#/]+$');
51                        if(next>prev) {
52                            position=width*2;
53                            a=-width*2
54                        } else {
55                            position=0;
56                            a=0
57                        }
58                        current=next;
59                        break
60                    }
61                    if(b==='fade') {
62                        if(g.crossfade) {
63                            control.children(':eq('+next+')',d).css( {
64                                zIndex:10
65                            }
66                            ).fadeIn(g.fadeSpeed,g.fadeEasing,function() {
67                                if(g.autoHeight) {
68                                    control.animate( {
69                                        height:control.children(':eq('+next+')',d).outerHeight()
70                                    }
71                                    ,g.autoHeightSpeed,function() {
72                                        control.children(':eq('+prev+')',d).css( {
73                                            display:'none',zIndex:0
74                                        }
75                                        );
76                                        control.children(':eq('+next+')',d).css( {
77                                            zIndex:0
78                                        }
79                                        );
80                                        g.animationComplete(next+1);
81                                        active=false
82                                    }
83                                    )
84                                } else {
85                                    control.children(':eq('+prev+')',d).css( {
86                                        display:'none',zIndex:0
87                                    }
88                                    );
89                                    control.children(':eq('+next+')',d).css( {
90                                        zIndex:0
91                                    }
92                                    );
93                                    g.animationComplete(next+1);
94                                    active=false
95                                }
96                            }
97                            )
98                        } else {
99                            control.children(':eq('+prev+')',d).fadeOut(g.fadeSpeed,g.fadeEasing,function() {
100                                if(g.autoHeight) {
101                                    control.animate( {
102                                        height:control.children(':eq('+next+')',d).outerHeight()
103                                    }
104                                    ,g.autoHeightSpeed,function() {
105                                        control.children(':eq('+next+')',d).fadeIn(g.fadeSpeed,g.fadeEasing)
106                                    }
107                                    )
108                                } else {
109                                    control.children(':eq('+next+')',d).fadeIn(g.fadeSpeed,g.fadeEasing,function() {
110                                        if($.browser.msie) {
111                                            $(this).get(0).style.removeAttribute('filter')
112                                        }
113                                    }
114                                    )
115                                }
116                                g.animationComplete(next+1);
117                                active=false
118                            }
119                            )
120                        }
121                    } else {
122                        control.children(':eq('+next+')').css( {
123                            left:position,display:'block'
124                        }
125                        );
126                        if(g.autoHeight) {
127                            control.animate( {
128                                left:a,height:control.children(':eq('+next+')').outerHeight()
129                            }
130                            ,g.slideSpeed,g.slideEasing,function() {
131                                control.css( {
132                                    left:-width
133                                }
134                                );
135                                control.children(':eq('+next+')').css( {
136                                    left:width,zIndex:5
137                                }
138                                );
139                                control.children(':eq('+prev+')').css( {
140                                    left:width,display:'none',zIndex:0
141                                }
142                                );
143                                g.animationComplete(next+1);
144                                active=false
145                            }
146                            )
147                        } else {
148                            control.animate( {
149                                left:a
150                            }
151                            ,g.slideSpeed,g.slideEasing,function() {
152                                control.css( {
153                                    left:-width
154                                }
155                                );
156                                control.children(':eq('+next+')').css( {
157                                    left:width,zIndex:5
158                                }
159                                );
160                                control.children(':eq('+prev+')').css( {
161                                    left:width,display:'none',zIndex:0
162                                }
163                                );
164                                g.animationComplete(next+1);
165                                active=false
166                            }
167                            )
168                        }
169                    }
170                    if(g.pagination) {
171                        $('.'+g.paginationClass+' li.current',d).removeClass('current');
172                        $('.'+g.paginationClass+' li:eq('+next+')',d).addClass('current')
173                    }
174                }
175            }
176
177            function stop() {
178                clearInterval(d.data('interval'))
179            }
180
181            function pause() {
182                if(g.pause) {
183                    clearTimeout(d.data('pause'));
184                    clearInterval(d.data('interval'));
185                    pauseTimeout=setTimeout(function() {
186                        clearTimeout(d.data('pause'));
187                        playInterval=setInterval(function() {
188                            animate("next",effect)
189                        }
190                        ,g.play);
191                        d.data('interval',playInterval)
192                    }
193                    ,g.pause);
194                    d.data('pause',pauseTimeout)
195                } else {
196                    stop()
197                }
198            }
199            if(total<1) {
200                return
201            }
202            if(start<0) {
203                start=0
204            }
205            if(start>total) {
206                start=total-1
207            }
208            if(g.start) {
209                current=start
210            }
211            if(g.randomize) {
212                control.randomize()
213            }
214            $('.'+g.flash_main,d).css( {
215                overflow:'hidden',position:'relative'
216            }
217            );
218            control.children().css( {
219                position:'absolute',top:0,left:control.children().outerWidth(),zIndex:0,display:'none'
220            }
221            );
222            control.css( {
223                position:'relative',width:(width*3),height:height,left:-width
224            }
225            );
226            $('.'+g.flash_main,d).css( {
227                display:'block'
228            }
229            );
230            if(g.autoHeight) {
231                control.children().css( {
232                    height:'auto'
233                }
234                );
235                control.animate( {
236                    height:control.children(':eq('+start+')').outerHeight()
237                }
238                ,g.autoHeightSpeed)
239            }
240            if(g.preload&&control.find('img').length) {
241                $('.'+g.flash_main,d).css( {
242                    background:'url('+g.preloadImage+') no-repeat 50% 50%'
243                }
244                );
245                var f=control.find('img:eq('+start+')').attr('src')+'?'+(new Date()).getTime();
246                if($('img',d).parent().attr('class')!='slides_control') {
247                    imageParent=control.children(':eq(0)')[0].tagName.toLowerCase()
248                } else {
249                    imageParent=control.find('img:eq('+start+')')
250                }
251                control.find('img:eq('+start+')').attr('src',f).load(function() {
252                    control.find(imageParent+':eq('+start+')').fadeIn(g.fadeSpeed,g.fadeEasing,function() {
253                        $(this).css( {
254                            zIndex:5
255                        }
256                        );
257                        $('.'+g.flash_main,d).css( {
258                            background:''
259                        }
260                        );
261                        loaded=true;
262                        g.slidesLoaded()
263                    }
264                    )
265                }
266                )
267            } else {
268                control.children(':eq('+start+')').fadeIn(g.fadeSpeed,g.fadeEasing,function() {
269                    loaded=true;
270                    g.slidesLoaded()
271                }
272                )
273            }
274            if(g.bigTarget) {
275                control.children().css( {
276                    cursor:'pointer'
277                }
278                );
279                control.children().click(function() {
280                    animate('next',effect);
281                    return false
282                }
283                )
284            }
285            if(g.hoverPause&&g.play) {
286                control.bind('mouseover',function() {
287                    stop();
288                }
289                );
290                control.bind('mouseleave',function() {
291                    if (jQuery(".flash_main_uruchom").length) {
292                        if (jQuery(".flash_main_uruchom").css("display")=="none") {
293                            pause();
294                        }
295                    } else {
296                        pause();
297                    }
298                }
299                )
300            }
301            if(g.generateNextPrev) {
302                $('.'+g.flash_main,d).after('<a href="#" class="'+g.prev+'">Prev</a>');
303                $('.'+g.prev,d).after('<a href="#" class="'+g.next+'">Next</a>')
304            }
305            $('.'+g.next,d).click(function(e) {
306                e.preventDefault();
307                if(g.play) {
308                    if (jQuery(".flash_main_uruchom").length) {
309                        if (jQuery(".flash_main_uruchom").css("display")=="none") {
310                            pause();
311                        }
312                    } else {
313                        pause();
314                    }
315                }
316                animate('next',effect)
317            }
318            );
319            $('.'+g.prev,d).click(function(e) {
320                e.preventDefault();
321                if(g.play) {
322                    if (jQuery(".flash_main_uruchom").length) {
323                        if (jQuery(".flash_main_uruchom").css("display")=="none") {
324                            pause();
325                        }
326                    } else {
327                        pause();
328                    }
329                }
330                animate('prev',effect)
331            }
332            );
333            if(g.generatePagination) {
334                d.append('<div class="pagination_tlo"><ul class='+g.paginationClass+'></ul></div>');
335                control.children().each(function() {
336                    $('.'+g.paginationClass,d).append('<li><a class=flash_nr_tlo_a href="#'+number+'">'+(number+1)+'</a><br /><div class=flash_nr><a class=flash_nr_a href="#'+number+'">'+(number+1)+'</a></div></li>');
337                    number++
338                }
339                )
340            } else {
341                $('.'+g.paginationClass+' li a',d).each(function() {
342                    $(this).attr('href','#'+number);
343                    number++
344                }
345                )
346            }
347            $('.'+g.paginationClass+' li:eq('+start+')',d).addClass('current');
348            $('.'+g.paginationClass+' li a',d).click(function() {
349                if(g.play) {
350                    pause()
351                }
352                clicked=$(this).attr('href').match('[^#/]+$');
353                if(current!=clicked) {
354                    animate('pagination',paginationEffect,clicked)
355                }
356                return false
357            }
358            );
359            $('a.link',d).click(function() {
360                if(g.play) {
361                    pause()
362                }
363                clicked=$(this).attr('href').match('[^#/]+$')-1;
364                if(current!=clicked) {
365                    animate('pagination',paginationEffect,clicked)
366                }
367                return false
368            }
369            );
370            if(g.play) {
371                playInterval=setInterval(function() {
372                    animate('next',effect)
373                }
374                ,g.play);
375                d.data('interval',playInterval)
376            }
377        }
378        )
379    }
380    ;
381    $.fn.slides.option= {
382        preload:false,preloadImage:'/img/loading.gif',flash_main:'slides_container',generateNextPrev:false,next:'next',prev:'prev',pagination:true,generatePagination:true,paginationClass:'pagination',fadeSpeed:600,fadeE
382asing:'',slideSpeed:600,slideEasing:'',start:1,effect:'slide',crossfade:false,randomize:false,play:0,pause:0,hoverPause:false,autoHeight:false,autoHeightSpeed:600,bigTarget:false,animationStart:function() {
383        }
384        ,animationComplete:function() {
385        }
386        ,slidesLoaded:function() {
387        }
388    }
389    ;
390    $.fn.randomize=function(c) {
391
392        function randomizeOrder() {
393            return(Math.round(Math.random())-0.5)
394        }
395        return($(this).each(function() {
396            var $this=$(this);
397            var $children=$this.children();
398            var a=$children.length;
399            if(a>1) {
400                $children.hide();
401                var b=[];
402                for(i=0;i<a;i++) {
403                    b[b.length]=i
404                }
405                b=b.sort(randomizeOrder);
406                $.each(b,function(j,k) {
407                    var $child=$children.eq(k);
408                    var $clone=$child.clone(true);
409                    $clone.show().appendTo($this);
410                    if(c!==undefined) {
411                        c($child,$clone)
412                    }
413                    $child.remove()
414                }
415                )
416            }
417        }
418        ))
419    }
420}
421)(jQuery);
422
423jQuery(document).ready(function(){
424    jQuery(".flash_main_uruchom").click(function(){
425        jQuery('.slides_control').trigger('mouseleave');
426        jQuery(".flash_main_uruchom").css("display","none");
427        jQuery(".flash_main_pauza").css("display","block");
428    });
429
430    jQuery(".flash_main_pauza").click(function(){
431        jQuery('.slides_control').trigger('mouseover');
432        jQuery(".flash_main_pauza").css("display","none");
433        jQuery(".flash_main_uruchom").css("display","block");
434    });
435
436    jQuery('.pagination a').attr("tabindex", "-1");
437});

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.