1/*! 2 * jQuery UI Effects 1.8.21 3 * 4 * Copyright 2012, AUTHORS.txt (http://jqueryui.com/about) 5 * Dual licensed under the MIT or GPL Version 2 licenses. 6 * http://jquery.org/license 7 * 8 * http://docs.jquery.com/UI/Effects/ 9 */ 10;jQuery.effects || (function($, undefined) { 11 12$.effects = {}; 13 14 15 16/******************************************************************************/ 17/****************************** COLOR ANIMATIONS ******************************/ 18/******************************************************************************/ 19 20// override the animation for color styles 21$.each(['backgroundColor', 'borderBottomColor', 'borderLeftColor', 22 'borderRightColor', 'borderTopColor', 'borderColor', 'color', 'outlineColor'], 23function(i, attr) { 24 $.fx.step[attr] = function(fx) { 25 if (!fx.colorInit) { 26 fx.start = getColor(fx.elem, attr); 27 fx.end = getRGB(fx.end); 28 fx.colorInit = true; 29 } 30 31 fx.elem.style[attr] = 'rgb(' + 32 Math.max(Math.min(parseInt((fx.pos * (fx.end[0] - fx.start[0])) + fx.start[0], 10), 255), 0) + ',' + 33 Math.max(Math.min(parseInt((fx.pos * (fx.end[1] - fx.start[1])) + fx.start[1], 10), 255), 0) + ',' + 34 Math.max(Math.min(parseInt((fx.pos * (fx.end[2] - fx.start[2])) + fx.start[2], 10), 255), 0) + ')'; 35 }; 36}); 37 38// Color Conversion functions from highlightFade 39// By Blair Mitchelmore 40// http://jquery.offput.ca/highlightFade/ 41 42// Parse strings looking for color tuples [255,255,255] 43function getRGB(color) { 44 var result; 45 46 // Check if we're already dealing with an array of colors 47 if ( color && color.constructor == Array && color.length == 3 ) 48 return color; 49 50 // Look for rgb(num,num,num) 51 if (result = /rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(color)) 52 return [parseInt(result[1],10), parseInt(result[2],10), parseInt(result[3],10)]; 53 54 // Look for rgb(num%,num%,num%) 55 if (result = /rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(color)) 56 return [parseFloat(result[1])*2.55, parseFloat(result[2])*2.55, parseFloat(result[3])*2.55]; 57 58 // Look for #a0b1c2 59 if (result = /#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(color)) 60 return [parseInt(result[1],16), parseInt(result[2],16), parseInt(result[3],16)]; 61 62 // Look for #fff 63 if (result = /#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(color)) 64 return [parseInt(result[1]+result[1],16), parseInt(result[2]+result[2],16), parseInt(result[3]+result[3],16)]; 65 66 // Look for rgba(0, 0, 0, 0) == transparent in Safari 3 67 if (result = /rgba\(0, 0, 0, 0\)/.exec(color)) 68 return colors['transparent']; 69 70 // Otherwise, we're most likely dealing with a named color 71 return colors[$.trim(color).toLowerCase()]; 72} 73 74function getColor(elem, attr) { 75 var color; 76 77 do { 78 color = $.curCSS(elem, attr); 79 80 // Keep going until we find an element that has color, or we hit the body 81 if ( color != '' && color != 'transparent' || $.nodeName(elem, "body") ) 82 break; 83 84 attr = "backgroundColor"; 85 } while ( elem = elem.parentNode ); 86 87 return getRGB(color); 88}; 89 90// Some named colors to work with 91// From Interface by Stefan Petre 92// http://interface.eyecon.ro/ 93 94var colors = { 95 aqua:[0,255,255], 96 azure:[240,255,255], 97 beige:[245,245,220], 98 black:[0,0,0], 99 blue:[0,0,255], 100 brown:[165,42,42], 101 cyan:[0,255,255], 102 darkblue:[0,0,139], 103 darkcyan:[0,139,139], 104 darkgrey:[169,169,169], 105 darkgreen:[0,100,0], 106 darkkhaki:[189,183,107], 107 darkmagenta:[139,0,139], 108 darkolivegreen:[85,107,47], 109 darkorange:[255,140,0], 110 darkorchid:[153,50,204], 111 darkred:[139,0,0], 112 darksalmon:[233,150,122], 113 darkviolet:[148,0,211], 114 fuchsia:[255,0,255], 115 gold:[255,215,0], 116 green:[0,128,0], 117 indigo:[75,0,130], 118 khaki:[240,230,140], 119 lightblue:[173,216,230], 120 lightcyan:[224,255,255], 121 lightgreen:[144,238,144], 122 lightgrey:[211,211,211], 123 lightpink:[255,182,193], 124 lightyellow:[255,255,224], 125 lime:[0,255,0], 126 magenta:[255,0,255], 127 maroon:[128,0,0], 128 navy:[0,0,128], 129 olive:[128,128,0], 130 orange:[255,165,0], 131 pink:[255,192,203], 132 purple:[128,0,128], 133 violet:[128,0,128], 134 red:[255,0,0], 135 silver:[192,192,192], 136 white:[255,255,255], 137 yellow:[255,255,0],
138 transparent: [255,255,255] 139}; 140 141 142 143/******************************************************************************/ 144/****************************** CLASS ANIMATIONS ******************************/ 145/******************************************************************************/ 146 147var classAnimationActions = ['add', 'remove', 'toggle'], 148 shorthandStyles = { 149 border: 1, 150 borderBottom: 1, 151 borderColor: 1, 152 borderLeft: 1, 153 borderRight: 1, 154 borderTop: 1, 155 borderWidth: 1, 156 margin: 1, 157 padding: 1 158 }; 159 160function getElementStyles() { 161 var style = document.defaultView 162 ? document.defaultView.getComputedStyle(this, null) 163 : this.currentStyle, 164 newStyle = {}, 165 key, 166 camelCase; 167 168 // webkit enumerates style porperties 169 if (style && style.length && style[0] && style[style[0]]) { 170 var len = style.length; 171 while (len--) { 172 key = style[len]; 173 if (typeof style[key] == 'string') { 174 camelCase = key.replace(/\-(\w)/g, function(all, letter){ 175 return letter.toUpperCase(); 176 }); 177 newStyle[camelCase] = style[key]; 178 } 179 } 180 } else { 181 for (key in style) { 182 if (typeof style[key] === 'string') { 183 newStyle[key] = style[key]; 184 } 185 } 186 } 187 188 return newStyle; 189} 190 191function filterStyles(styles) { 192 var name, value; 193 for (name in styles) { 194 value = styles[name]; 195 if ( 196 // ignore null and undefined values 197 value == null || 198 // ignore functions (when does this occur?) 199 $.isFunction(value) || 200 // shorthand styles that need to be expanded 201 name in shorthandStyles || 202 // ignore scrollbars (break in IE) 203 (/scrollbar/).test(name) || 204 205 // only colors or values that can be converted to numbers 206 (!(/color/i).test(name) && isNaN(parseFloat(value))) 207 ) { 208 delete styles[name]; 209 } 210 } 211 212 return styles; 213} 214 215function styleDifference(oldStyle, newStyle) { 216 var diff = { _: 0 }, // http://dev.jquery.com/ticket/5459 217 name; 218 219 for (name in newStyle) { 220 if (oldStyle[name] != newStyle[name]) { 221 diff[name] = newStyle[name]; 222 } 223 } 224 225 return diff; 226} 227 228$.effects.animateClass = function(value, duration, easing, callback) { 229 if ($.isFunction(easing)) { 230 callback = easing; 231 easing = null; 232 } 233 234 return this.queue(function() { 235 var that = $(this), 236 originalStyleAttr = that.attr('style') || ' ', 237 originalStyle = filterStyles(getElementStyles.call(this)), 238 newStyle, 239 className = that.attr('class') || ""; 240 241 $.each(classAnimationActions, function(i, action) { 242 if (value[action]) { 243 that[action + 'Class'](value[action]); 244 } 245 }); 246 newStyle = filterStyles(getElementStyles.call(this)); 247 that.attr('class', className); 248 249 that.animate(styleDifference(originalStyle, newStyle), { 250 queue: false, 251 duration: duration, 252 easing: easing, 253 complete: function() { 254 $.each(classAnimationActions, function(i, action) { 255 if (value[action]) { that[action + 'Class'](value[action]); } 256 }); 257 // work around bug in IE by clearing the cssText before setting it 258 if (typeof that.attr('style') == 'object') { 259 that.attr('style').cssText = ''; 260 that.attr('style').cssText = originalStyleAttr; 261 } else { 262 that.attr('style', originalStyleAttr); 263 } 264 if (callback) { callback.apply(this, arguments); } 265 $.dequeue( this ); 266 } 267 }); 268 }); 269}; 270 271$.fn.extend({ 272 _addClass: $.fn.addClass, 273 addClass: function(classNames, speed, easing, callback) { 274 return speed ? $.effects.animateClass.apply(this, [{ add: classNames },speed,easing,callback]) : this._addClass(classNames); 275 }, 276 277 _removeClass: $.fn.removeClass, 278 removeClass: function(classNames,speed,easing,callback) { 279 return speed ? $.effects.animateClass.apply(this, [{ remove: classNames },speed,easing,callback]) : this._removeClass(classNames); 280 }, 281 282 _toggleClass: $.fn.toggleClass, 283 toggleClass: function(classNames, force, speed, easing, callback) { 284 if ( typeof force == "boolean" || force === undefined ) { 285 if ( !speed ) { 286 // without speed parameter; 287 return this._toggleClass(classNames, force); 288 } else { 289 return $.effects.animateClass.apply(this, [(force?{add:classNames}:{remove:classNames}),speed,easing,callback]); 290 } 291 } else { 292 // without switch parameter; 293 return $.effects.animateClass.apply(this, [{ toggle: classNames },force,speed,easing]); 294 } 295 }, 296 297 switchClass: function(remove,add,speed,easing,callback) { 298 return $.effects.animateClass.apply(this, [{ add: add, remove: remove },speed,easing,callback]); 299 } 300}); 301/******************************************************************************/ 302/*********************************** EFFECTS **********************************/ 303/******************************************************************************/ 304 305$.extend($.effects, { 306 version: "1.8.21", 307 308 // Saves a set of properties in a data storage 309 save: function(element, set) { 310 for(var i=0; i < set.length; i++) { 311 if(set[i] !== null) element.data("ec.storage."+set[i], element[0].style[set[i]]); 312 } 313 }, 314 315 // Restores a set of previously saved properties from a data storage 316 restore: function(element, set) { 317 for(var i=0; i < set.length; i++) { 318 if(set[i] !== null) element.css(set[i], element.data("ec.storage."+set[i])); 319 } 320 }, 321 322 setMode: function(el, mode) { 323 if (mode == 'toggle') mode = el.is(':hidden') ? 'show' : 'hide'; // Set for toggle 324 return mode; 325 }, 326 327 getBaseline: function(origin, original) { // Translates a [top,left] array into a baseline value 328 // this should be a little more flexible in the future to handle a string & hash 329 var y, x; 330 switch (origin[0]) { 331 case 'top': y = 0; break; 332 case 'middle': y = 0.5; break; 333 case 'bottom': y = 1; break; 334 default: y = origin[0] / original.height; 335 }; 336 switch (origin[1]) { 337 case 'left': x = 0; break; 338 case 'center': x = 0.5; break; 339 case 'right': x = 1; break; 340 default: x = origin[1] / original.width; 341 }; 342 return {x: x, y: y}; 343 }, 344
345 // Wraps the element around a wrapper that copies position properties 346 createWrapper: function(element) { 347 348 // if the element is already wrapped, return it 349 if (element.parent().is('.ui-effects-wrapper')) { 350 return element.parent(); 351 } 352 353 // wrap the element 354 var props = { 355 width: element.outerWidth(true), 356 height: element.outerHeight(true), 357 'float': element.css('float') 358 }, 359 wrapper = $('<div></div>') 360 .addClass('ui-effects-wrapper') 361 .css({ 362 fontSize: '100%', 363 background: 'transparent', 364 border: 'none', 365 margin: 0, 366 padding: 0 367 }), 368 active = document.activeElement; 369 370 // support: Firefox 371 // Firefox incorrectly exposes anonymous content 372 // https://bugzilla.mozilla.org/show_bug.cgi?id=561664 373 try { 374 active.id; 375 } catch( e ) { 376 active = document.body; 377 } 378 379 element.wrap( wrapper ); 380 381 // Fixes #7595 - Elements lose focus when wrapped. 382 if ( element[ 0 ] === active || $.contains( element[ 0 ], active ) ) { 383 $( active ).focus(); 384 } 385 386 wrapper = element.parent(); //Hotfix for jQuery 1.4 since some change in wrap() seems to actually loose the reference to the wrapped element 387 388 // transfer positioning properties to the wrapper 389 if (element.css('position') == 'static') { 390 wrapper.css({ position: 'relative' }); 391 element.css({ position: 'relative' }); 392 } else { 393 $.extend(props, { 394 position: element.css('position'), 395 zIndex: element.css('z-index') 396 }); 397 $.each(['top', 'left', 'bottom', 'right'], function(i, pos) { 398 props[pos] = element.css(pos); 399 if (isNaN(parseInt(props[pos], 10))) { 400 props[pos] = 'auto'; 401 } 402 }); 403 element.css({position: 'relative', top: 0, left: 0, right: 'auto', bottom: 'auto' }); 404 } 405 406 return wrapper.css(props).show(); 407 }, 408 409 removeWrapper: function(element) { 410 var parent, 411 active = document.activeElement; 412 413 if (element.parent().is('.ui-effects-wrapper')) { 414 parent = element.parent().replaceWith(element); 415 // Fixes #7595 - Elements lose focus when wrapped. 416 if ( element[ 0 ] === active || $.contains( element[ 0 ], active ) ) { 417 $( active ).focus(); 418 } 419 return parent; 420 } 421 422 return element; 423 }, 424 425 setTransition: function(element, list, factor, value) { 426 value = value || {}; 427 $.each(list, function(i, x){ 428 var unit = element.cssUnit(x); 429 if (unit[0] > 0) value[x] = unit[0] * factor + unit[1]; 430 }); 431 return value; 432 } 433}); 434 435 436function _normalizeArguments(effect, options, speed, callback) { 437 // shift params for method overloading 438 if (typeof effect == 'object') { 439 callback = options; 440 speed = null; 441 options = effect; 442 effect = options.effect; 443 } 444 if ($.isFunction(options)) { 445 callback = options; 446 speed = null; 447 options = {}; 448 } 449 if (typeof options == 'number' || $.fx.speeds[options]) { 450 callback = speed; 451 speed = options; 452 options = {}; 453 } 454 if ($.isFunction(speed)) { 455 callback = speed; 456 speed = null; 457 } 458 459 options = options || {}; 460 461 speed = speed || options.duration; 462 speed = $.fx.off ? 0 : typeof speed == 'number' 463 ? speed : speed in $.fx.speeds ? $.fx.speeds[speed] : $.fx.speeds._default; 464 465 callback = callback || options.complete; 466 467 return [effect, options, speed, callback]; 468} 469 470function standardSpeed( speed ) { 471 // valid standard speeds 472 if ( !speed || typeof speed === "number" || $.fx.speeds[ speed ] ) { 473 return true; 474 } 475 476 // invalid strings - treat as "normal" speed 477 if ( typeof speed === "string" && !$.effects[ speed ] ) { 478 return true; 479 } 480 481 return false; 482} 483 484$.fn.extend({ 485 effect: function(effect, options, speed, callback) { 486 var args = _normalizeArguments.apply(this, arguments), 487 // TODO: make effects take actual parameters instead of a hash 488 args2 = { 489 options: args[1], 490 duration: args[2], 491 callback: args[3] 492 }, 493 mode = args2.options.mode, 494 effectMethod = $.effects[effect]; 495 496 if ( $.fx.off || !effectMethod ) { 497 // delegate to the original method (e.g., .show()) if possible 498 if ( mode ) { 499 return this[ mode ]( args2.duration, args2.callback ); 500 } else { 501 return this.each(function() { 502 if ( args2.callback ) { 503 args2.callback.call( this ); 504 } 505 }); 506 } 507 } 508 509 return effectMethod.call(this, args2); 510 }, 511 512 _show: $.fn.show, 513 show: function(speed) { 514 if ( standardSpeed( speed ) ) { 515 return this._show.apply(this, arguments); 516 } else { 517 var args = _normalizeArguments.apply(this, arguments); 518 args[1].mode = 'show'; 519 return this.effect.apply(this, args); 520 } 521 }, 522 523 _hide: $.fn.hide, 524 hide: function(speed) { 525 if ( standardSpeed( speed ) ) { 526 return this._hide.apply(this, arguments); 527 } else { 528 var args = _normalizeArguments.apply(this, arguments); 529 args[1].mode = 'hide'; 530 return this.effect.apply(this, args); 531 } 532 }, 533 534 // jQuery core overloads toggle and creates _toggle 535 __toggle: $.fn.toggle, 536 toggle: function(speed) { 537 if ( standardSpeed( speed ) || typeof speed === "boolean" || $.isFunction( speed ) ) { 538 return this.__toggle.apply(this, arguments); 539 } else { 540 var args = _normalizeArguments.apply(this, arguments); 541 args[1].mode = 'toggle'; 542 return this.effect.apply(this, args); 543 } 544 }, 545 546 // helper functions 547 cssUnit: function(key) { 548 var style = this.css(key), val = []; 549 $.each( ['em','px','%','pt'], function(i, unit){ 550 if(style.indexOf(unit) > 0) 551 val = [parseFloat(style), unit]; 552 }); 553 return val; 554 } 555}); 556 557 558 559/******************************************************************************/ 560/*********************************** EASING ***********************************/ 561/******************************************************************************/ 562 563/* 564 * jQuery Easing v1.3 - http://gsgd.co.uk/sandbox/jquery/easing/ 565 * 566 * Uses the built in easing capabilities added In jQuery 1.1 567 * to offer multiple easing options 568 * 569 * TERMS OF USE - jQuery Easing 570 * 571 * Open source under the BSD License. 572 * 573 * Copyright 2008 George McGinley Smith 574 * All rights reserved. 575 * 576 * Redistribution and use in source and binary forms, with or without modification, 577 * are permitted provided that the following conditions are met: 578 * 579 * Redistributions of source code must retain the above copyright notice, this list of 580 * conditions and the following disclaimer. 581 * Redistributions in binary form must reproduce the above copyright notice, this list 582 * of conditions and the following disclaimer in the documentation and/or other materials 583 * provided with the distribution. 584 * 585 * Neither the name of the author nor the names of contributors may be used to endorse 586 * or promote products derived from this software without specific prior written permission. 587 * 588 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY 589 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 590 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 591 * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
vendor: 5,027 bytes, lines 592-737
592 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE 593 * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 594 * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING 595 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 596 * OF THE POSSIBILITY OF SUCH DAMAGE. 597 * 598*/ 599 600// t: current time, b: begInnIng value, c: change In value, d: duration 601$.easing.jswing = $.easing.swing; 602 603$.extend($.easing, 604{ 605 def: 'easeOutQuad', 606 swing: function (x, t, b, c, d) { 607 //alert($.easing.default); 608 return $.easing[$.easing.def](x, t, b, c, d); 609 }, 610 easeInQuad: function (x, t, b, c, d) { 611 return c*(t/=d)*t + b; 612 }, 613 easeOutQuad: function (x, t, b, c, d) { 614 return -c *(t/=d)*(t-2) + b; 615 }, 616 easeInOutQuad: function (x, t, b, c, d) { 617 if ((t/=d/2) < 1) return c/2*t*t + b; 618 return -c/2 * ((--t)*(t-2) - 1) + b; 619 }, 620 easeInCubic: function (x, t, b, c, d) { 621 return c*(t/=d)*t*t + b; 622 }, 623 easeOutCubic: function (x, t, b, c, d) { 624 return c*((t=t/d-1)*t*t + 1) + b; 625 }, 626 easeInOutCubic: function (x, t, b, c, d) { 627 if ((t/=d/2) < 1) return c/2*t*t*t + b; 628 return c/2*((t-=2)*t*t + 2) + b; 629 }, 630 easeInQuart: function (x, t, b, c, d) { 631 return c*(t/=d)*t*t*t + b; 632 }, 633 easeOutQuart: function (x, t, b, c, d) { 634 return -c * ((t=t/d-1)*t*t*t - 1) + b; 635 }, 636 easeInOutQuart: function (x, t, b, c, d) { 637 if ((t/=d/2) < 1) return c/2*t*t*t*t + b; 638 return -c/2 * ((t-=2)*t*t*t - 2) + b; 639 }, 640 easeInQuint: function (x, t, b, c, d) { 641 return c*(t/=d)*t*t*t*t + b; 642 }, 643 easeOutQuint: function (x, t, b, c, d) { 644 return c*((t=t/d-1)*t*t*t*t + 1) + b; 645 }, 646 easeInOutQuint: function (x, t, b, c, d) { 647 if ((t/=d/2) < 1) return c/2*t*t*t*t*t + b; 648 return c/2*((t-=2)*t*t*t*t + 2) + b; 649 }, 650 easeInSine: function (x, t, b, c, d) { 651 return -c * Math.cos(t/d * (Math.PI/2)) + c + b; 652 }, 653 easeOutSine: function (x, t, b, c, d) { 654 return c * Math.sin(t/d * (Math.PI/2)) + b; 655 }, 656 easeInOutSine: function (x, t, b, c, d) { 657 return -c/2 * (Math.cos(Math.PI*t/d) - 1) + b; 658 }, 659 easeInExpo: function (x, t, b, c, d) { 660 return (t==0) ? b : c * Math.pow(2, 10 * (t/d - 1)) + b; 661 }, 662 easeOutExpo: function (x, t, b, c, d) { 663 return (t==d) ? b+c : c * (-Math.pow(2, -10 * t/d) + 1) + b; 664 }, 665 easeInOutExpo: function (x, t, b, c, d) { 666 if (t==0) return b; 667 if (t==d) return b+c; 668 if ((t/=d/2) < 1) return c/2 * Math.pow(2, 10 * (t - 1)) + b; 669 return c/2 * (-Math.pow(2, -10 * --t) + 2) + b; 670 }, 671 easeInCirc: function (x, t, b, c, d) { 672 return -c * (Math.sqrt(1 - (t/=d)*t) - 1) + b; 673 }, 674 easeOutCirc: function (x, t, b, c, d) { 675 return c * Math.sqrt(1 - (t=t/d-1)*t) + b; 676 }, 677 easeInOutCirc: function (x, t, b, c, d) { 678 if ((t/=d/2) < 1) return -c/2 * (Math.sqrt(1 - t*t) - 1) + b; 679 return c/2 * (Math.sqrt(1 - (t-=2)*t) + 1) + b; 680 }, 681 easeInElastic: function (x, t, b, c, d) { 682 var s=1.70158;var p=0;var a=c; 683 if (t==0) return b; if ((t/=d)==1) return b+c; if (!p) p=d*.3; 684 if (a < Math.abs(c)) { a=c; var s=p/4; } 685 else var s = p/(2*Math.PI) * Math.asin (c/a); 686 return -(a*Math.pow(2,10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )) + b; 687 }, 688 easeOutElastic: function (x, t, b, c, d) { 689 var s=1.70158;var p=0;var a=c; 690 if (t==0) return b; if ((t/=d)==1) return b+c; if (!p) p=d*.3; 691 if (a < Math.abs(c)) { a=c; var s=p/4; } 692 else var s = p/(2*Math.PI) * Math.asin (c/a); 693 return a*Math.pow(2,-10*t) * Math.sin( (t*d-s)*(2*Math.PI)/p ) + c + b; 694 }, 695 easeInOutElastic: function (x, t, b, c, d) { 696 var s=1.70158;var p=0;var a=c; 697 if (t==0) return b; if ((t/=d/2)==2) return b+c; if (!p) p=d*(.3*1.5); 698 if (a < Math.abs(c)) { a=c; var s=p/4; } 699 else var s = p/(2*Math.PI) * Math.asin (c/a); 700 if (t < 1) return -.5*(a*Math.pow(2,10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )) + b; 701 return a*Math.pow(2,-10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )*.5 + c + b; 702 }, 703 easeInBack: function (x, t, b, c, d, s) { 704 if (s == undefined) s = 1.70158; 705 return c*(t/=d)*t*((s+1)*t - s) + b; 706 }, 707 easeOutBack: function (x, t, b, c, d, s) { 708 if (s == undefined) s = 1.70158; 709 return c*((t=t/d-1)*t*((s+1)*t + s) + 1) + b; 710 }, 711 easeInOutBack: function (x, t, b, c, d, s) { 712 if (s == undefined) s = 1.70158; 713 if ((t/=d/2) < 1) return c/2*(t*t*(((s*=(1.525))+1)*t - s)) + b; 714 return c/2*((t-=2)*t*(((s*=(1.525))+1)*t + s) + 2) + b; 715 }, 716 easeInBounce: function (x, t, b, c, d) { 717 return c - $.easing.easeOutBounce (x, d-t, 0, c, d) + b; 718 }, 719 easeOutBounce: function (x, t, b, c, d) { 720 if ((t/=d) < (1/2.75)) { 721 return c*(7.5625*t*t) + b; 722 } else if (t < (2/2.75)) { 723 return c*(7.5625*(t-=(1.5/2.75))*t + .75) + b; 724 } else if (t < (2.5/2.75)) { 725 return c*(7.5625*(t-=(2.25/2.75))*t + .9375) + b; 726 } else { 727 return c*(7.5625*(t-=(2.625/2.75))*t + .984375) + b; 728 } 729 }, 730 easeInOutBounce: function (x, t, b, c, d) { 731 if (t < d/2) return $.easing.easeInBounce (x, t*2, 0, c, d) * .5 + b; 732 return $.easing.easeOutBounce (x, t*2-d, 0, c, d) * .5 + c*.5 + b; 733 } 734}); 735 736/* 737 *
738 * TERMS OF USE - EASING EQUATIONS 739 * 740 * Open source under the BSD License. 741 * 742 * Copyright 2001 Robert Penner 743 * All rights reserved. 744 * 745 * Redistribution and use in source and binary forms, with or without modification, 746 * are permitted provided that the following conditions are met: 747 * 748 * Redistributions of source code must retain the above copyright notice, this list of 749 * conditions and the following disclaimer. 750 * Redistributions in binary form must reproduce the above copyright notice, this list 751 * of conditions and the following disclaimer in the documentation and/or other materials 752 * provided with the distribution. 753 * 754 * Neither the name of the author nor the names of contributors may be used to endorse 755 * or promote products derived from this software without specific prior written permission. 756 * 757 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY 758 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 759 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 760 * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 761 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE 762 * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 763 * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING 764 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 765 * OF THE POSSIBILITY OF SUCH DAMAGE. 766 * 767 */ 768 769})(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.