PageSourceSearch

https://www.welbontc.com/template/js/jquery.SuperSlide.js

js welbontc.com collected 2026-10-08 12:16:51 UTC 27,652 bytes, 562 lines download raw bytes

1/*!
2 * SuperSlide v2.0 
3 * 轻松解决网站大部分特效展示问题
4 *
5 * 请尊重原创,保留头部版权
6 * 在保留版权的前提下可应用于个人或商业用途
7 */
8
9(function($){
10	var defaults={
11		effect:"fade", 
12		autoPlay:true, 
13		delayTime:500, 
14		interTime:5000,
15		triggerTime:150,
16		defaultIndex:0,
17		titCell:".hd li",
18		mainCell:".bd",
19		targetCell:null,
20		trigger:"mouseover",
21		scroll:1,
22		vis:1,
23		titOnClassName:"on",
24		autoPage:false,
25		prevCell:".prev",
26		nextCell:".next",
27		pageStateCell:".pageState",
28		opp: false, 
29		pnLoop:true, 
30		easing:"linear",
31		startFun:null,
32		endFun:null,
33		switchLoad:null,
34		imgfull:false
35		};
36	$.fn.slideNew=function(options){
37		if (this.length == 0)
38            return this;
39
40        // support mutltiple elements
41        if (this.length > 1) {
42            this.each(function () {
43                $(this).slideNew(options)
44            });
45            return this;
46        }
47		var el = this;
48		
49		return this.each(function() {	
50			var opts = $.extend({},defaults,options);
51			var effect = opts.effect;
52			var prevBtn = $(opts.prevCell, $(this));
53			var nextBtn = $(opts.nextCell, $(this));
54			var pageState = $(opts.pageStateCell, $(this));
55			var navObj = $(opts.titCell, $(this));//导航子元素结合
56			var navObjSize = navObj.length;
57			var conBox = $(opts.mainCell , $(this));//内容元素父层对象
58			var conBoxSize=conBox.children().length;
59			var sLoad=opts.switchLoad;
60			if(opts.targetCell!=null){ var tarObj = $(opts.targetCell, $(this)) };
61
62			/*字符串转换为数字*/
63			var index=parseInt(opts.defaultIndex);
64			var delayTime=parseInt(opts.delayTime);
65			var interTime=parseInt(opts.interTime);
66			var triggerTime=parseInt(opts.triggerTime);
67			var scroll=parseInt(opts.scroll);
68			var vis=parseInt(opts.vis);
69			var autoPlay = (opts.autoPlay=="false"||opts.autoPlay==false)?false:true;
70			var opp = (opts.opp=="false"||opts.opp==false)?false:true;
71			var autoPage = (opts.autoPage=="false"||opts.autoPage==false)?false:true;
72			var loop = (opts.pnLoop=="false"||opts.pnLoop==false)?false:true;
73			var imgfull = (opts.imgfull=="false"||opts.imgfull==false)?false:true;
74
75			var slideH=0;
76			var slideW=0;
77			var selfW=0;
78			var selfH=2000;
79			var easing=opts.easing;
80			var inter=null;//setInterval名称 
81			var oldIndex = index;
82			var working=false;
83			var isScrolling;
84			
85			//处理分页
86			if( navObjSize==0 )navObjSize=conBoxSize;
87			if( autoPage ){
88				var tempS = conBoxSize-vis;
89				navObjSize=1+parseInt(tempS%scroll!=0?(tempS/scroll+1):(tempS/scroll)); 
90				if(navObjSize<=0)navObjSize=1;
91				navObj.html(""); 
92				for( var i=0; i<navObjSize; i++ ){ navObj.append("<li>"+(i+1)+"</li>") }
93				var navObj = $("li", navObj);//重置导航子元素对象
94			}
95
96
97            if(imgfull){
98				switch(effect)
99				{
100				    case "top":
101					case "topLoop":
102					case "topMarquee":
103					case "bottomLoop":
104					case "bottomMarquee":conBox.children().find('img').css({'width':'100%'}); break;
105				}
106			}
107			conBox.children().each(function(){ //取最大值
108				if( $(this).width()>selfW ){ selfW=$(this).outerWidth(); slideW=$(this).outerWidth(true);if(navigator.appName == "Microsoft Internet Explorer" && navigator.appVersion .split(";")[1].replace(/[ ]/g,"")=="MSIE7.0"){selfW=$(this).width();};  }
109				if( $(this).height()<selfH ){ selfH=$(this).height(); slideH=$(this).outerHeight(true);  }
110			});
111            if(imgfull){
112				oneImgW=conBox.find('img').eq(0).width();
113				oneImgH=conBox.find('img').eq(0).height();
114				imgHN = (oneImgH * selfW) / oneImgW;
115				switch(effect)
116				{
117					case "fold":
118					case "left":
119					case "leftLoop":
120					case "leftMarquee":
121					case "rightLoop":
122					case "rightMarquee":conBox.children().find('img').css({'width':'100%','height':imgHN}); break;
123				}
124			}
125			if(conBoxSize>=vis){ //当内容个数少于可视个数,不执行效果。
126				switch(effect)
127				{
128					case "fold": conBox.css({"position":"relative","width":slideW,"height":slideH}).children().css( {"position":"absolute","width":selfW,"left":0,"top":0,"display":"none"} ); break;
129					case "top": conBox.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; height:'+vis*slideH+'px"></div>').css( { "position":"relative","padding":"0","margin":"0"}).children().css( {"height":selfH} ); break;
130					case "left": conBox.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; width:'+vis*slideW+'px"></div>').css( { "width":conBoxSize*slideW,"position":"relative","overflow":"hidden","padding":"0","margin":"0"}).children().css( {"float":"left","width":selfW} ); break;
131					case "leftLoop":
132					case "leftMarquee":
133						conBox.children().clone().appendTo(conBox).clone().prependTo(conBox); 
134						conBox.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; width:'+vis*slideW+'px"></div>').css( { "width":conBoxSize*slideW*3,"position":"relative","overflow":"hidden","padding":"0","margin":"0","left":-conBoxSize*slideW}).children().css( {"float":"left","width":selfW}  ); break;
135					case "rightLoop":
136					case "rightMarquee":
137						conBox.children().clone().appendTo(conBox).clone().prependTo(conBox); 
138						conBox.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; width:'+vis*slideW+'px"></div>').css( { "width":conBoxSize*slideW*3,"position":"relative","overflow":"hidden","padding":"0","margin":"0","left":-conBoxSize*slideW}).children().css( {"float":"left","width":selfW}  ); break;
139					case "topLoop":
140					case "topMarquee":
141						conBox.children().clone().appendTo(conBox).clone().prependTo(conBox); 
142						conBox.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; height:'+vis*slideH+'px"></div>').css( { "height":conBoxSize*slideH*3,"position":"relative","padding":"0","margin":"0","top":-conBoxSize*slideH}).children().css( {"height":selfH} ); break;
143					case "bottomLoop":
144					case "bottomMarquee":
145						conBox.children().clone().appendTo(conBox).clone().prependTo(conBox); 
146						conBox.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; height:'+vis*slideH+'px"></div>').css( { "height":conBoxSize*slideH*3,"position":"relative","padding":"0","margin":"0","top":-conBoxSize*slideH}).children().css( {"height":selfH} ); break;
147				}
148			}
149			$(window).bind('resize', function(){
150				resizeWindow();
151			});
152            var resizeWindow = function (e) {
153				if(effect!=='fade'){
154					conBox.removeAttr('style');
155					conBox.children().removeAttr('style');
156					conBox.parent().removeAttr('style');
157				}
158				slideH=0;
159			    slideW=0;
160			    selfW=0;
161			    selfH=2000;
162				conBox.children().each(function(){ //取最大值
163					if( $(this).width()>selfW ){ selfW=$(this).outerWidth(); slideW=$(this).outerWidth(true);if(navigator.appName == "Microsoft Internet Explorer" && navigator.appVersion .split(";")[1].replace(/[ ]/g,"")=="MSIE7.0"){selfW=$(this).width();};  }
164					if( $(this).height()<selfH ){ selfH=$(this).height(); slideH=$(this).outerHeight(true);  }
165			    });
166				if(imgfull){
167					imgHN=(oneImgH * selfW)/oneImgW;
168					switch(effect)
169					{
170						case "fold":
171						case "left":
172						case "leftLoop":
173						case "leftMarquee":
174						case "rightLoop":
175						case "rightMarquee":conBox.children().find('img').css({'width':'100%','height':imgHN});break;
176					}
177				}
178				if(conBoxSize>=vis){ //当内容个数少于可视个数,不执行效果。
179					switch(effect)
180					{
181						case "fold": conBox.css({"position":"relative","width":slideW,"height":slideH}).children().css( {"position":"absolute","width":selfW,"left":0,"top":0,"display":"none"} ); break;
182						case "top": conBox.parent().css({'overflow':'hidden', 'position':'relative', 'height': vis*slideH});
183						            conBox.css( { "position":"relative","padding":"0","margin":"0"}).children().css( {"height":selfH} ); break;
184						case "left": conBox.parent().css({'overflow':'hidden', 'position':'relative', 'width': vis*slideW});
185						             conBox.css( { "width":conBoxSize*slideW,"position":"relative","overflow":"hidden","padding":"0","margin":"0"}).children().css( {"float":"left","width":selfW} ); break;
186						case "leftLoop":
187						case "leftMarquee":
188							conBox.parent().css({'overflow':'hidden', 'position':'relative', 'width': vis*slideW});
189							conBox.css( { "width":conBoxSize*slideW*3,"position":"relative","overflow":"hidden","padding":"0","margin":"0","left":-conBoxSize*slideW}).children().css( {"float":"left","width":selfW}  ); break;
190						case "rightLoop":
191						case "rightMarquee":
192							conBox.parent().css({'overflow':'hidden', 'position':'relative', 'width': vis*slideW});
193							conBox.css( { "width":conBoxSize*slideW*3,"position":"relative","overflow":"hidden","padding":"0","margin":"0","left":-conBoxSize*slideW}).children().css( {"float":"left","width":selfW}  ); break;
194						case "topLoop":
195						case "topMarquee":
196							conBox.parent().css({'overflow':'hidden', 'position':'relative', 'height': vis*slideH});
197							conBox.css( { "height":conBoxSize*slideH*3,"position":"relative","padding":"0","margin":"0","top":-conBoxSize*slideH}).children().css( {"height":selfH} ); break;
198						case "bottomLoop":
199						case "bottomMarquee":
200							conBox.parent().css({'overflow':'hidden', 'position':'relative', 'height': vis*slideH});
201							conBox.css( { "height":conBoxSize*slideH*3,"position":"relative","padding":"0","margin":"0","top":-conBoxSize*slideH}).children().css( {"height":selfH} ); break;
202					}
203				}
204				doPlay();
205			}
206			
207			var doStartFun=function(){ if ( $.isFunction( opts.startFun) ){ opts.startFun( index,navObjSize ); } };
208			var doEndFun=function(){ if ( $.isFunction( opts.endFun ) ){ opts.endFun( index,navObjSize ); } };
209			var doSwitchLoad=function(objs){ 
210						objs.eq(index).find("img").each(function(){ 
211						if ( typeof($(this).attr(sLoad))!="undefined"){ $(this).attr("src",$(this).attr(sLoad)).removeAttr(sLoad) }
212					})
213				}
214
215			//效果函数
216			var doPlay=function(isFirst){
217				if( oldIndex==index && !isFirst && effect!="leftMarquee" && effect!="topMarquee" && effect!="rightMarquee" && effect!="bottomMarquee"  ) return; // 当前页状态不触发效果
218				switch(effect)
219				{
220					case "fade": case "fold": case "top": case "left": if ( index >= navObjSize) { index = 0; } else if( index < 0) { index = navObjSize-1; } break;
221					case "leftMarquee":case "topMarquee": if ( index>= 1) { index=1; } else if( index<=0) { index = 0; } break;
222					case "rightMarquee":case "bottomMarquee": if ( index>= 1) { index=1; } else if( index<=0) { index = 0; } break;
223					case "leftLoop": case "topLoop":
224						var tempNum = index - oldIndex; 
225						if( navObjSize>2 && tempNum==-(navObjSize-1) ) tempNum=1;
226						if( navObjSize>2 && tempNum==(navObjSize-1) ) tempNum=-1;
227						var scrollNum = Math.abs( tempNum*scroll );
228						if ( index >= navObjSize) { index = 0; } else if( index < 0) { index = navObjSize-1; }
229					case "rightLoop": case "bottomLoop":
230						var tempNum = index - oldIndex; 
231						if( navObjSize>2 && tempNum==-(navObjSize-1) ) tempNum=1;
232						if( navObjSize>2 && tempNum==(navObjSize-1) ) tempNum=-1;
233						var scrollNum = Math.abs( tempNum*scroll );
234						if ( index >= navObjSize) { index = 0; } else if( index < 0) { index = navObjSize-1; }
235					break;
236				}
237
238				doStartFun();
239
240				//处理切换加载
241				if( sLoad!=null ){ doSwitchLoad( conBox.children() ) }
242
243				//处理targetCell
244				if(tarObj){ 
245					if( sLoad!=null ){ doSwitchLoad( tarObj ) }
246					tarObj.hide().eq(index).animate({opacity:"show"},delayTime,function(){ if(!conBox[0])doEndFun() }); 
247				}
248				
249				if(conBoxSize>=vis){ //当内容个数少于可视个数,不执行效果。
250					switch (effect)
251					{
252						case "fade":conBox.children().stop(true,true).eq(index).animate({opacity:"show"},delayTime,easing,function(){doEndFun()}).siblings().hide(); break;
253						case "fold":conBox.children().stop(true,true).eq(index).animate({opacity:"show"},delayTime,easing,function(){doEndFun()}).siblings().animate({opacity:"hide"},delayTime,easing);break;
254						case "top":conBox.stop(true,false).animate({"top":-index*scroll*slideH},delayTime,easing,function(){doEndFun()});break;
255						case "left":conBox.stop(true,false).animate({"left":-index*scroll*slideW},delayTime,easing,function(){doEndFun()});break;
256						case "leftLoop":
257							if(tempNum<0 ){
258									conBox.stop(true,true).animate({"left":-(conBoxSize-scrollNum )*slideW},delayTime,easing,function(){
259									for(var i=0;i<scrollNum;i++){ conBox.children().last().prependTo(conBox); }
260									conBox.css("left",-conBoxSize*slideW);
261									doEndFun();
262								});	
263							}
264							else{
265								conBox.stop(true,true).animate({"left":-( conBoxSize + scrollNum)*slideW},delayTime,easing,function(){
266									for(var i=0;i<scrollNum;i++){ conBox.children().eq(0).appendTo(conBox); }
267									conBox.css("left",-conBoxSize*slideW);
268									doEndFun();
269								});
270							}break;// leftLoop end
271                        case "rightLoop":
272							if(tempNum<0 ){
273									conBox.stop(true,true).animate({"left":-(conBoxSize+scrollNum )*slideW},delayTime,easing,function(){
274									for(var i=0;i<scrollNum;i++){ conBox.children().eq(0).appendTo(conBox); }
275									conBox.css("left",-conBoxSize*slideW);
276									doEndFun();
277								});
278							}
279							else{
280								conBox.stop(true,true).animate({"left":-( conBoxSize - scrollNum)*slideW},delayTime,easing,function(){
281									for(var i=0;i<scrollNum;i++){ conBox.children().last().prependTo(conBox); }
282									conBox.css("left",-conBoxSize*slideW);
283									doEndFun();
284								});
285							}break;// rightLoop end
286						case "topLoop":
287							if(tempNum<0 ){
288									conBox.stop(true,true).animate({"top":-(conBoxSize-scrollNum )*slideH},delayTime,easing,function(){
289									for(var i=0;i<scrollNum;i++){ conBox.children().last().prependTo(conBox); }
290									conBox.css("top",-conBoxSize*slideH);
291									doEndFun();
292								});
293							}
294							else{
295								conBox.stop(true,true).animate({"top":-( conBoxSize + scrollNum)*slideH},delayTime,easing,function(){
296									for(var i=0;i<scrollNum;i++){ conBox.children().first().appendTo(conBox); }
297									conBox.css("top",-conBoxSize*slideH);
298									doEndFun();
299								});
300							}break;//topLoop end
301						case "bottomLoop":
302							if(tempNum<0 ){
303									conBox.stop(true,true).animate({"top":-(conBoxSize+scrollNum )*slideH},delayTime,easing,function(){
304									for(var i=0;i<scrollNum;i++){ conBox.children().first().appendTo(conBox); }
305									conBox.css("top",-conBoxSize*slideH);
306									doEndFun();
307								});
308							}
309							else{
310								conBox.stop(true,true).animate({"top":-( conBoxSize - scrollNum)*slideH},delayTime,easing,function(){
311									for(var i=0;i<scrollNum;i++){ conBox.children().last().prependTo(conBox); }
312									conBox.css("top",-conBoxSize*slideH);
313									doEndFun();
314								});
315							}break;//bottomLoop end	
316
317						case "leftMarquee":
318							var tempLeft = conBox.css("left").replace("px",""); 
319
320							if(index==0 ){
321									conBox.animate({"left":++tempLeft},0,function(){
322										
323										if( conBox.css("left").replace("px","")>= 0){ for(var i=0;i<conBoxSize;i++){ conBox.children().last().prependTo(conBox); }conBox.css("left",-conBoxSize*slideW);}
324									});
325							}
326							else{
327									conBox.animate({"left":--tempLeft},0,function(){
328										if(  conBox.css("left").replace("px","")<= -conBoxSize*slideW*2){ for(var i=0;i<conBoxSize;i++){ conBox.children().first().appendTo(conBox); }conBox.css("left",-conBoxSize*slideW);}
329									});
330							}break;// leftMarquee end
331						case "rightMarquee":
332							var tempLeft = conBox.css("left").replace("px",""); 
333                                if(index==0 ){
334									conBox.animate({"left":--tempLeft},0,function(){
335										if(  conBox.css("left").replace("px","")<= -conBoxSize*slideW*2){for(var i=0;i<conBoxSize;i++){conBox.children().first().appendTo(conBox); }conBox.css("left",-conBoxSize*slideW); }
336									});
337							}
338							else{
339									conBox.animate({"left":++tempLeft},0,function(){
340										if( conBox.css("left").replace("px","")>= 0){ for(var i=0;i<conBoxSize;i++){  conBox.children().last().prependTo(conBox); }conBox.css("left",-conBoxSize*slideW);}
341									});
342							}break;// rightMarquee end
343
344						case "topMarquee":
345							var tempTop = conBox.css("top").replace("px",""); 
346								if(index==0 ){
347										conBox.animate({"top":++tempTop},0,function(){
348											if( conBox.css("top").replace("px","") >= 0){ for(var i=0;i<conBoxSize;i++){ conBox.children().last().prependTo(conBox); }conBox.css("top",-conBoxSize*slideH);}
349										});
350								}
351								else{
352										conBox.animate({"top":--tempTop},0,function(){
353											if( conBox.css("top").replace("px","")<= -conBoxSize*slideH*2){ for(var i=0;i<conBoxSize;i++){ conBox.children().first().appendTo(conBox); }conBox.css("top",-conBoxSize*slideH);}
354										});
355								}break;// topMarquee end
356						case "bottomMarquee":
357							var tempTop = conBox.css("top").replace("px",""); 
358								if(index==0 ){
359										conBox.animate({"top":--tempTop},0,function(){
360											if( conBox.css("top").replace("px","")<= -conBoxSize*slideH*2){ for(var i=0;i<conBoxSize;i++){ conBox.children().last().prependTo(conBox); }conBox.css("top",-conBoxSize*slideH);}
361										});
362								}
363								else{
364										conBox.animate({"top":++tempTop},0,function(){
365											if( conBox.css("top").replace("px","") >= 0){ for(var i=0;i<conBoxSize;i++){ conBox.children().first().appendTo(conBox); }conBox.css("top",-conBoxSize*slideH);}
366										});
367								}break;// bottomMarquee end
368
369
370					}//switch end	
371				}
372				navObj.removeClass(opts.titOnClassName).eq(index).addClass(opts.titOnClassName);
373				oldIndex=index;
374				if( loop==false ){ //loop控制是否继续循环
375					nextBtn.removeClass("nextStop"); prevBtn.removeClass("prevStop");
376					if (index==0 ){ prevBtn.addClass("prevStop"); }
377					else if (index==navObjSize-1 ){ nextBtn.addClass("nextStop");  }
378				}
379			};
380			var add_point=function(){
381				var pages='';
382					for(var i=0; i<navObjSize; i++){
383						if(i===index){
384							pages +='<span class="active" ></span>';
385						}else{
386						pages += '<span></span>';
387						}
388					}
389					pageState.html(pages);
390			}
391			//初始化执行
392			doPlay(true);
393			//添加按钮
394            add_point(true);
395			var add_active=function(){
396				var pagest=pageState.children('span');
397				pagest.eq(index).siblings('span').removeClass('active');
398				pagest.eq(index).addClass('active');
399				
400			}
401			//自动播放
402			if (autoPlay) {
403					if( effect=="leftMarquee" || effect=="topMarquee" || effect=="rightMarquee" || effect=="bottomMarquee" ){
404						if(opp){ index-- }else{ index++ } inter = setInterval(function(){doPlay(),add_active()}, interTime);
405						conBox.hover(function(){if(autoPlay){clearInterval(inter); }},function(){if(autoPlay){clearInterval(inter);inter = setInterval(function(){doPlay(),add_active()}, interTime);}});
406					}else{
407						 inter=setInterval(function(){  if(opp){ index-- }else{ index++ } ; doPlay(),add_active() }, interTime); 
408						$(this).hover(function(){if(autoPlay){clearInterval(inter); }},function(){if(autoPlay){clearInterval(inter); inter=setInterval(function(){if(opp){ index-- }else{ index++ }; doPlay(),add_active() }, interTime); }});
409					}
410			}
411
412			//鼠标事件
413			var mst;
414			if(opts.trigger=="mouseover"){
415				navObj.hover(function(){ index=navObj.index(this); mst = window.setTimeout(doPlay,opts.triggerTime); }, function(){ clearTimeout(mst); });
416			   }else{ navObj.click(function(){index=navObj.index(this);  doPlay();add_active(); })  }
417			 var goToNextSlide=function()  { if ( loop==true || index!=navObjSize-1 ){ index++; doPlay();add_active();} }
418			 var goToPrevSlide=function()  { if ( loop==true || index!=0 ){ index--; doPlay();add_active(); }}
419			 nextBtn.click(function(){ if ( loop==true || index!=navObjSize-1 ){ index++; doPlay();add_active(); }  });  
420			 prevBtn.click(function(){ if ( loop==true || index!=0 ){ index--; doPlay();add_active(); } });  
421			 var alist=pageState.children('span');
422			 alist.each(function(){
423				$(this).on("click",function(){
424					var i=alist.index($(this));
425					 if ( loop==true || index!=i ){ index=i; doPlay();add_active(); }  
426				});
427			 });
428			 /**
429			 * Initializes touch events
430			 */
431			 var istouch=false;
432			 var xMovement,yMovement;
433			 var isTouchDevice = function() {
434				try {
435					document.createEvent("TouchEvent");
436					istouch=true;
437					
438				} catch (e) {
439					istouch=false;
440				}
441			}
442			var initTouch = function () {
443				// initialize object to contain all touch values
444				el.touch = {
445					start: {x: 0, y: 0},
446					end: {x: 0, y: 0}
447				}
448				el.bind('touchstart', onTouchStart);
449			}
450	        isTouchDevice();
451			/**
452			 * Event handler for "touchstart"
453			 *
454			 * @param e (event)
455			 *  - DOM event object
456			 */
457			var onTouchStart = function (e) {
458					// record the original position when touch starts
459					el.touch.originalPos = el.position();
460					isScrolling = 0;
461					var orig = e.originalEvent;
462					// record the starting touch x, y coordinates
463					el.touch.start.x = orig.changedTouches[0].pageX;
464					el.touch.start.y = orig.changedTouches[0].pageY;
465					// bind a "touchmove" event to the viewport
466					el.bind('touchmove', onTouchMove);
467					// bind a "touchend" event to the viewport
468					el.bind('touchend', onTouchEnd);
469			}
470	
471			/**
472			 * Event handler for "touchmove"
473			 *
474			 * @param e (event)
475			 *  - DOM event object
476			 */
477			var onTouchMove = function (e) {
478				if(event.targetTouches.length > 1 || e.scale && e.scale !== 1) return;
479				var orig = e.originalEvent;
480				el.touch.end.x = orig.changedTouches[0].pageX;
481				el.touch.end.y = orig.changedTouches[0].pageY;
482				// if scrolling on y axis, do not prevent default
483				xMovement = Math.abs(el.touch.end.x - el.touch.start.x);
484				yMovement = Math.abs(el.touch.end.y  - el.touch.start.y);
485				isScrolling = xMovement < yMovement ? 1:0;
486				if(isScrolling === 0){
487                 e.preventDefault(); 
488				}
489			}
490	
491			/**
492			 * Event handler for "touchend"
493			 *
494			 * @param e (event)
495			 *  - DOM event object
496			 */
497			var onTouchEnd = function (e) {
498				if(isScrolling === 0){
499				    if(xMovement >20){
500						switch(effect)
501						{
502							case "fade":
503							case "fold":
504							case "left":
505							case "leftLoop":
506							case "leftMarquee":el.touch.start.x > el.touch.end.x ? goToNextSlide() : goToPrevSlide();break;
507							case "rightLoop":
508							case "rightMarquee":el.touch.start.x > el.touch.end.x ? goToPrevSlide() : goToNextSlide();break;
509						}
510					}
511				}
512				el.unbind('touchmove', onTouchMove);
513				el.unbind('touchend', onTouchEnd);
514			}
515            initTouch();
516    	});//each End
517        
518	};//slide End
519
520})(jQuery);
521
522jQuery.easing['jswing'] = jQuery.easing['swing'];
523jQuery.extend( jQuery.easing,
524{
525	def: 'easeOutQuad',
526	swing: function (x, t, b, c, d) { return jQuery.easing[jQuery.easing.def](x, t, b, c, d); },
527	easeInQuad: function (x, t, b, c, d) {return c*(t/=d)*t + b;},
528	easeOutQuad: function (x, t, b, c, d) {return -c *(t/=d)*(t-2) + b},
529	easeInOutQuad: function (x, t, b, c, d) {if ((t/=d/2) < 1) return c/2*t*t + b;return -c/2 * ((--t)*(t-2) - 1) + b},
530	easeInCubic: function (x, t, b, c, d) {return c*(t/=d)*t*t + b},
531	easeOutCubic: function (x, t, b, c, d) {return c*((t=t/d-1)*t*t + 1) + b},
532	easeInOutCubic: function (x, t, b, c, d) {if ((t/=d/2) < 1) return c/2*t*t*t + b;return c/2*((t-=2)*t*t + 2) + b},
533	easeInQuart: function (x, t, b, c, d) {return c*(t/=d)*t*t*t + b},
534	easeOutQuart: function (x, t, b, c, d) {return -c * ((t=t/d-1)*t*t*t - 1) + b},
535	easeInOutQuart: function (x, t, b, c, d) {if ((t/=d/2) < 1) return c/2*t*t*t*t + b;return -c/2 * ((t-=2)*t*t*t - 2) + b},
536	easeInQuint: function (x, t, b, c, d) {return c*(t/=d)*t*t*t*t + b},
537	easeOutQuint: function (x, t, b, c, d) {return c*((t=t/d-1)*t*t*t*t + 1) + b},
538	easeInOutQuint: function (x, t, b, c, d) {if ((t/=d/2) < 1) return c/2*t*t*t*t*t + b;return c/2*((t-=2)*t*t*t*t + 2) + b},
539	easeInSine: function (x, t, b, c, d) {return -c * Math.cos(t/d * (Math.PI/2)) + c + b},
540	easeOutSine: function (x, t, b, c, d) {return c * Math.sin(t/d * (Math.PI/2)) + b},
vendor: 2,873 bytes, lines 541-562
541	easeInOutSine: function (x, t, b, c, d) {return -c/2 * (Math.cos(Math.PI*t/d) - 1) + b},
542	easeInExpo: function (x, t, b, c, d) {return (t==0) ? b : c * Math.pow(2, 10 * (t/d - 1)) + b},
543	easeOutExpo: function (x, t, b, c, d) {return (t==d) ? b+c : c * (-Math.pow(2, -10 * t/d) + 1) + b},
544	easeInOutExpo: function (x, t, b, c, d) {if (t==0) return b;if (t==d) return b+c;if ((t/=d/2) < 1) return c/2 * Math.pow(2, 10 * (t - 1)) + b;return c/2 * (-Math.pow(2, -10 * --t) + 2) + b},
545	easeInCirc: function (x, t, b, c, d) {return -c * (Math.sqrt(1 - (t/=d)*t) - 1) + b},
546	easeOutCirc: function (x, t, b, c, d) {return c * Math.sqrt(1 - (t=t/d-1)*t) + b},
547	easeInOutCirc: function (x, t, b, c, d) {if ((t/=d/2) < 1) return -c/2 * (Math.sqrt(1 - t*t) - 1) + b;return c/2 * (Math.sqrt(1 - (t-=2)*t) + 1) + b},
548	easeInElastic: function (x, t, b, c, d) {var s=1.70158;var p=0;var a=c;if (t==0) return b;  if ((t/=d)==1) return b+c;  if (!p) p=d*.3;if (a < Math.abs(c)) { a=c; var s=p/4; }
549		else var s = p/(2*Math.PI) * Math.asin (c/a);return -(a*Math.pow(2,10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )) + b},
550	easeOutElastic: function (x, t, b, c, d) {var s=1.70158;var p=0;var a=c;if (t==0) return b;  if ((t/=d)==1) return b+c;  if (!p) p=d*.3;if (a < Math.abs(c)) { a=c; var s=p/4; }
551		else var s = p/(2*Math.PI) * Math.asin (c/a);return a*Math.pow(2,-10*t) * Math.sin( (t*d-s)*(2*Math.PI)/p ) + c + b},
552	easeInOutElastic: function (x, t, b, c, d) {var s=1.70158;var p=0;var a=c;if (t==0) return b;  if ((t/=d/2)==2) return b+c;  if (!p) p=d*(.3*1.5);if (a < Math.abs(c)) { a=c; var s=p/4; }
553		else var s = p/(2*Math.PI) * Math.asin (c/a);if (t < 1) return -.5*(a*Math.pow(2,10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )) + b;return a*Math.pow(2,-10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )*.5 + c + b},
554	easeInBack: function (x, t, b, c, d, s) {if (s == undefined) s = 1.70158;return c*(t/=d)*t*((s+1)*t - s) + b},
555	easeOutBack: function (x, t, b, c, d, s) {if (s == undefined) s = 1.70158;return c*((t=t/d-1)*t*((s+1)*t + s) + 1) + b},
556	easeInOutBack: function (x, t, b, c, d, s) {if (s == undefined) s = 1.70158; 
557		if ((t/=d/2) < 1) return c/2*(t*t*(((s*=(1.525))+1)*t - s)) + b;return c/2*((t-=2)*t*(((s*=(1.525))+1)*t + s) + 2) + b},
558	easeInBounce: function (x, t, b, c, d) {return c - jQuery.easing.easeOutBounce (x, d-t, 0, c, d) + b},
559	easeOutBounce: function (x, t, b, c, d) {if ((t/=d) < (1/2.75)) {	return c*(7.5625*t*t) + b;} else if (t < (2/2.75)) {	return c*(7.5625*(t-=(1.5/2.75))*t + .75) + b;} else if (t < (2.5/2.75)) {	return c*(7.5625*(t-=(2.25/2.75))*t + .9375) + b;} else {	return c*(7.5625*(t-=(2.625/2.75))*t + .984375) + b;}},
560	easeInOutBounce: function (x, t, b, c, d) {if (t < d/2) return jQuery.easing.easeInBounce (x, t*2, 0, c, d) * .5 + b;return jQuery.easing.easeOutBounce (x, t*2-d, 0, c, d) * .5 + c*.5 + b;}
561});
562

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.