Ignore:
Timestamp:
Oct 28, 2011, 3:25:54 PM (12 years ago)
Author:
patdenice
Message:

feature:2487
Update jQuery to 1.6.4 and jQuery UI to 1.8.16

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/themes/default/js/jquery.js

    r12040 r12525  
    11/*!
    2  * jQuery JavaScript Library v1.6.2
     2 * jQuery JavaScript Library v1.6.4
    33 * http://jquery.com/
    44 *
     
    1212 * Released under the MIT, BSD, and GPL Licenses.
    1313 *
    14  * Date: Thu Jun 30 14:16:56 2011 -0400
     14 * Date: Mon Sep 12 18:54:48 2011 -0400
    1515 */
    1616(function( window, undefined ) {
     
    3838
    3939        // A simple way to check for HTML strings or ID strings
    40         // (both of which we optimize for)
    41         quickExpr = /^(?:[^<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,
     40        // Prioritize #id over <tag> to avoid XSS via location.hash (#9521)
     41        quickExpr = /^(?:[^#<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,
    4242
    4343        // Check if a string has a non-whitespace character in it
     
    6767
    6868        // Matches dashed string for camelizing
    69         rdashAlpha = /-([a-z])/ig,
     69        rdashAlpha = /-([a-z]|[0-9])/ig,
     70        rmsPrefix = /^-ms-/,
    7071
    7172        // Used by jQuery.camelCase as callback to replace()
    7273        fcamelCase = function( all, letter ) {
    73                 return letter.toUpperCase();
     74                return ( letter + "" ).toUpperCase();
    7475        },
    7576
     
    213214
    214215        // The current version of jQuery being used
    215         jquery: "1.6.2",
     216        jquery: "1.6.4",
    216217
    217218        // The default length of a jQuery object is 0
     
    522523                }
    523524
    524                 // Not own constructor property must be Object
    525                 if ( obj.constructor &&
    526                         !hasOwn.call(obj, "constructor") &&
    527                         !hasOwn.call(obj.constructor.prototype, "isPrototypeOf") ) {
     525                try {
     526                        // Not own constructor property must be Object
     527                        if ( obj.constructor &&
     528                                !hasOwn.call(obj, "constructor") &&
     529                                !hasOwn.call(obj.constructor.prototype, "isPrototypeOf") ) {
     530                                return false;
     531                        }
     532                } catch ( e ) {
     533                        // IE8,9 Will throw exceptions on certain host objects #9897
    528534                        return false;
    529535                }
     
    575581
    576582        // Cross-browser xml parsing
    577         // (xml & tmp used internally)
    578         parseXML: function( data , xml , tmp ) {
    579 
    580                 if ( window.DOMParser ) { // Standard
    581                         tmp = new DOMParser();
    582                         xml = tmp.parseFromString( data , "text/xml" );
    583                 } else { // IE
    584                         xml = new ActiveXObject( "Microsoft.XMLDOM" );
    585                         xml.async = "false";
    586                         xml.loadXML( data );
    587                 }
    588 
    589                 tmp = xml.documentElement;
    590 
    591                 if ( ! tmp || ! tmp.nodeName || tmp.nodeName === "parsererror" ) {
     583        parseXML: function( data ) {
     584                var xml, tmp;
     585                try {
     586                        if ( window.DOMParser ) { // Standard
     587                                tmp = new DOMParser();
     588                                xml = tmp.parseFromString( data , "text/xml" );
     589                        } else { // IE
     590                                xml = new ActiveXObject( "Microsoft.XMLDOM" );
     591                                xml.async = "false";
     592                                xml.loadXML( data );
     593                        }
     594                } catch( e ) {
     595                        xml = undefined;
     596                }
     597                if ( !xml || !xml.documentElement || xml.getElementsByTagName( "parsererror" ).length ) {
    592598                        jQuery.error( "Invalid XML: " + data );
    593599                }
    594 
    595600                return xml;
    596601        },
     
    612617        },
    613618
    614         // Converts a dashed string to camelCased string;
    615         // Used by both the css and data modules
     619        // Convert dashed to camelCase; used by the css and data modules
     620        // Microsoft forgot to hump their vendor prefix (#9572)
    616621        camelCase: function( string ) {
    617                 return string.replace( rdashAlpha, fcamelCase );
     622                return string.replace( rmsPrefix, "ms-" ).replace( rdashAlpha, fcamelCase );
    618623        },
    619624
     
    700705
    701706        inArray: function( elem, array ) {
     707                if ( !array ) {
     708                        return -1;
     709                }
    702710
    703711                if ( indexOf ) {
     
    10721080                                                                        returned.promise().then( newDefer.resolve, newDefer.reject );
    10731081                                                                } else {
    1074                                                                         newDefer[ action ]( returned );
     1082                                                                        newDefer[ action + "With" ]( this === deferred ? newDefer : this, [ returned ] );
    10751083                                                                }
    10761084                                                        });
     
    11741182        div.innerHTML = "   <link/><table></table><a href='/a' style='top:1px;float:left;opacity:.55;'>a</a><input type='checkbox'/>";
    11751183
     1184
    11761185        all = div.getElementsByTagName( "*" );
    11771186        a = div.getElementsByTagName( "a" )[ 0 ];
     
    12941303                height: 0,
    12951304                border: 0,
    1296                 margin: 0
     1305                margin: 0,
     1306                background: "none"
    12971307        };
    12981308        if ( body ) {
    12991309                jQuery.extend( testElementStyle, {
    13001310                        position: "absolute",
    1301                         left: -1000,
    1302                         top: -1000
     1311                        left: "-1000px",
     1312                        top: "-1000px"
    13031313                });
    13041314        }
     
    14051415
    14061416var rbrace = /^(?:\{.*\}|\[.*\])$/,
    1407         rmultiDash = /([a-z])([A-Z])/g;
     1417        rmultiDash = /([A-Z])/g;
    14081418
    14091419jQuery.extend({
     
    14371447                }
    14381448
    1439                 var internalKey = jQuery.expando, getByName = typeof name === "string", thisCache,
     1449                var thisCache, ret,
     1450                        internalKey = jQuery.expando,
     1451                        getByName = typeof name === "string",
    14401452
    14411453                        // We have to handle DOM nodes and JS objects differently because IE6-7
     
    14531465                // Avoid doing any more work than we need to when trying to get data on an
    14541466                // object that has no data at all
    1455                 if ( (!id || (pvt && id && !cache[ id ][ internalKey ])) && getByName && data === undefined ) {
     1467                if ( (!id || (pvt && id && (cache[ id ] && !cache[ id ][ internalKey ]))) && getByName && data === undefined ) {
    14561468                        return;
    14571469                }
     
    15121524                }
    15131525
    1514                 return getByName ?
    1515                         // Check for both converted-to-camel and non-converted data property names
    1516                         thisCache[ jQuery.camelCase( name ) ] || thisCache[ name ] :
    1517                         thisCache;
     1526                // Check for both converted-to-camel and non-converted data property names
     1527                // If a data property was specified
     1528                if ( getByName ) {
     1529
     1530                        // First Try to find as-is property data
     1531                        ret = thisCache[ name ];
     1532
     1533                        // Test for null|undefined property data
     1534                        if ( ret == null ) {
     1535
     1536                                // Try to find the camelCased property
     1537                                ret = thisCache[ jQuery.camelCase( name ) ];
     1538                        }
     1539                } else {
     1540                        ret = thisCache;
     1541                }
     1542
     1543                return ret;
    15181544        },
    15191545
     
    15231549                }
    15241550
    1525                 var internalKey = jQuery.expando, isNode = elem.nodeType,
     1551                var thisCache,
     1552
     1553                        // Reference to internal data cache key
     1554                        internalKey = jQuery.expando,
     1555
     1556                        isNode = elem.nodeType,
    15261557
    15271558                        // See jQuery.data for more information
     
    15381569
    15391570                if ( name ) {
    1540                         var thisCache = pvt ? cache[ id ][ internalKey ] : cache[ id ];
     1571
     1572                        thisCache = pvt ? cache[ id ][ internalKey ] : cache[ id ];
    15411573
    15421574                        if ( thisCache ) {
     1575
     1576                                // Support interoperable removal of hyphenated or camelcased keys
     1577                                if ( !thisCache[ name ] ) {
     1578                                        name = jQuery.camelCase( name );
     1579                                }
     1580
    15431581                                delete thisCache[ name ];
    15441582
     
    15671605                // the window, but it will allow it on all other JS objects; other browsers
    15681606                // don't care
    1569                 if ( jQuery.support.deleteExpando || cache != window ) {
     1607                // Ensure that `cache` is not a window object #10080
     1608                if ( jQuery.support.deleteExpando || !cache.setInterval ) {
    15701609                        delete cache[ id ];
    15711610                } else {
     
    16911730        // data from the HTML5 data-* attribute
    16921731        if ( data === undefined && elem.nodeType === 1 ) {
    1693                 var name = "data-" + key.replace( rmultiDash, "$1-$2" ).toLowerCase();
     1732
     1733                var name = "data-" + key.replace( rmultiDash, "-$1" ).toLowerCase();
    16941734
    16951735                data = elem.getAttribute( name );
     
    19111951        rclickable = /^a(?:rea)?$/i,
    19121952        rboolean = /^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,
    1913         rinvalidChar = /\:|^on/,
    1914         formHook, boolHook;
     1953        nodeHook, boolHook;
    19151954
    19161955jQuery.fn.extend({
     
    20502089                var className = " " + selector + " ";
    20512090                for ( var i = 0, l = this.length; i < l; i++ ) {
    2052                         if ( (" " + this[i].className + " ").replace(rclass, " ").indexOf( className ) > -1 ) {
     2091                        if ( this[i].nodeType === 1 && (" " + this[i].className + " ").replace(rclass, " ").indexOf( className ) > -1 ) {
    20532092                                return true;
    20542093                        }
     
    22302269                                // Use boolHook for boolean attributes
    22312270                                if ( rboolean.test( name ) ) {
    2232 
    22332271                                        hooks = boolHook;
    22342272
    2235                                 // Use formHook for forms and if the name contains certain characters
    2236                                 } else if ( formHook && name !== "className" &&
    2237                                         (jQuery.nodeName( elem, "form" ) || rinvalidChar.test( name )) ) {
    2238 
    2239                                         hooks = formHook;
     2273                                // Use nodeHook if available( IE6/7 )
     2274                                } else if ( nodeHook ) {
     2275                                        hooks = nodeHook;
    22402276                                }
    22412277                        }
     
    22742310                if ( elem.nodeType === 1 ) {
    22752311                        name = jQuery.attrFix[ name ] || name;
    2276                
    2277                         if ( jQuery.support.getSetAttribute ) {
    2278                                 // Use removeAttribute in browsers that support it
    2279                                 elem.removeAttribute( name );
    2280                         } else {
    2281                                 jQuery.attr( elem, name, "" );
    2282                                 elem.removeAttributeNode( elem.getAttributeNode( name ) );
    2283                         }
     2312
     2313                        jQuery.attr( elem, name, "" );
     2314                        elem.removeAttribute( name );
    22842315
    22852316                        // Set corresponding property to false for boolean attributes
     
    23092340                        }
    23102341                },
    2311                 tabIndex: {
    2312                         get: function( elem ) {
    2313                                 // elem.tabIndex doesn't always return the correct value when it hasn't been explicitly set
    2314                                 // http://fluidproject.org/blog/2008/01/09/getting-setting-and-removing-tabindex-values-with-javascript/
    2315                                 var attributeNode = elem.getAttributeNode("tabIndex");
    2316 
    2317                                 return attributeNode && attributeNode.specified ?
    2318                                         parseInt( attributeNode.value, 10 ) :
    2319                                         rfocusable.test( elem.nodeName ) || rclickable.test( elem.nodeName ) && elem.href ?
    2320                                                 0 :
    2321                                                 undefined;
    2322                         }
    2323                 },
    23242342                // Use the value property for back compat
    2325                 // Use the formHook for button elements in IE6/7 (#1954)
     2343                // Use the nodeHook for button elements in IE6/7 (#1954)
    23262344                value: {
    23272345                        get: function( elem, name ) {
    2328                                 if ( formHook && jQuery.nodeName( elem, "button" ) ) {
    2329                                         return formHook.get( elem, name );
     2346                                if ( nodeHook && jQuery.nodeName( elem, "button" ) ) {
     2347                                        return nodeHook.get( elem, name );
    23302348                                }
    23312349                                return name in elem ?
     
    23342352                        },
    23352353                        set: function( elem, value, name ) {
    2336                                 if ( formHook && jQuery.nodeName( elem, "button" ) ) {
    2337                                         return formHook.set( elem, value, name );
     2354                                if ( nodeHook && jQuery.nodeName( elem, "button" ) ) {
     2355                                        return nodeHook.set( elem, value, name );
    23382356                                }
    23392357                                // Does not return so that setAttribute is also used
     
    23842402
    23852403                } else {
    2386                         if ( hooks && "get" in hooks && (ret = hooks.get( elem, name )) !== undefined ) {
     2404                        if ( hooks && "get" in hooks && (ret = hooks.get( elem, name )) !== null ) {
    23872405                                return ret;
    23882406
     
    23932411        },
    23942412       
    2395         propHooks: {}
     2413        propHooks: {
     2414                tabIndex: {
     2415                        get: function( elem ) {
     2416                                // elem.tabIndex doesn't always return the correct value when it hasn't been explicitly set
     2417                                // http://fluidproject.org/blog/2008/01/09/getting-setting-and-removing-tabindex-values-with-javascript/
     2418                                var attributeNode = elem.getAttributeNode("tabindex");
     2419
     2420                                return attributeNode && attributeNode.specified ?
     2421                                        parseInt( attributeNode.value, 10 ) :
     2422                                        rfocusable.test( elem.nodeName ) || rclickable.test( elem.nodeName ) && elem.href ?
     2423                                                0 :
     2424                                                undefined;
     2425                        }
     2426                }
     2427        }
    23962428});
     2429
     2430// Add the tabindex propHook to attrHooks for back-compat
     2431jQuery.attrHooks.tabIndex = jQuery.propHooks.tabIndex;
    23972432
    23982433// Hook for boolean attributes
     
    24002435        get: function( elem, name ) {
    24012436                // Align boolean attributes with corresponding properties
    2402                 return jQuery.prop( elem, name ) ?
     2437                // Fall back to attribute presence where some booleans are not supported
     2438                var attrNode;
     2439                return jQuery.prop( elem, name ) === true || ( attrNode = elem.getAttributeNode( name ) ) && attrNode.nodeValue !== false ?
    24032440                        name.toLowerCase() :
    24042441                        undefined;
     
    24262463// IE6/7 do not support getting/setting some attributes with get/setAttribute
    24272464if ( !jQuery.support.getSetAttribute ) {
    2428 
    2429         // propFix is more comprehensive and contains all fixes
    2430         jQuery.attrFix = jQuery.propFix;
    24312465       
    2432         // Use this for any attribute on a form in IE6/7
    2433         formHook = jQuery.attrHooks.name = jQuery.attrHooks.title = jQuery.valHooks.button = {
     2466        // Use this for any attribute in IE6/7
     2467        // This fixes almost every IE6/7 issue
     2468        nodeHook = jQuery.valHooks.button = {
    24342469                get: function( elem, name ) {
    24352470                        var ret;
     
    24412476                },
    24422477                set: function( elem, value, name ) {
    2443                         // Check form objects in IE (multiple bugs related)
    2444                         // Only use nodeValue if the attribute node exists on the form
     2478                        // Set the existing or create a new attribute node
    24452479                        var ret = elem.getAttributeNode( name );
    2446                         if ( ret ) {
    2447                                 ret.nodeValue = value;
    2448                                 return value;
    2449                         }
     2480                        if ( !ret ) {
     2481                                ret = document.createAttribute( name );
     2482                                elem.setAttributeNode( ret );
     2483                        }
     2484                        return (ret.nodeValue = value + "");
    24502485                }
    24512486        };
     
    25062541                                }
    25072542                        }
     2543                        return null;
    25082544                }
    25092545        });
     
    32363272                        if ( !jQuery.nodeName( this, "form" ) ) {
    32373273                                jQuery.event.add(this, "click.specialSubmit", function( e ) {
     3274                                        // Avoid triggering error on non-existent type attribute in IE VML (#7071)
    32383275                                        var elem = e.target,
    3239                                                 type = elem.type;
     3276                                                type = jQuery.nodeName( elem, "input" ) || jQuery.nodeName( elem, "button" ) ? elem.type : "";
    32403277
    32413278                                        if ( (type === "submit" || type === "image") && jQuery( elem ).closest("form").length ) {
     
    32463283                                jQuery.event.add(this, "keypress.specialSubmit", function( e ) {
    32473284                                        var elem = e.target,
    3248                                                 type = elem.type;
     3285                                                type = jQuery.nodeName( elem, "input" ) || jQuery.nodeName( elem, "button" ) ? elem.type : "";
    32493286
    32503287                                        if ( (type === "text" || type === "password") && jQuery( elem ).closest("form").length && e.keyCode === 13 ) {
     
    32713308
    32723309        getVal = function( elem ) {
    3273                 var type = elem.type, val = elem.value;
     3310                var type = jQuery.nodeName( elem, "input" ) ? elem.type : "",
     3311                        val = elem.value;
    32743312
    32753313                if ( type === "radio" || type === "checkbox" ) {
     
    52965334        // the matched set of elements
    52975335        index: function( elem ) {
    5298                 if ( !elem || typeof elem === "string" ) {
    5299                         return jQuery.inArray( this[0],
    5300                                 // If it receives a string, the selector is used
    5301                                 // If it receives nothing, the siblings are used
    5302                                 elem ? jQuery( elem ) : this.parent().children() );
    5303                 }
     5336
     5337                // No argument, return index in parent
     5338                if ( !elem ) {
     5339                        return ( this[0] && this[0].parentNode ) ? this.prevAll().length : -1;
     5340                }
     5341
     5342                // index in selector
     5343                if ( typeof elem === "string" ) {
     5344                        return jQuery.inArray( this[0], jQuery( elem ) );
     5345                }
     5346
    53045347                // Locate the position of the desired element
    53055348                return jQuery.inArray(
     
    60496092                        // elements on the page has a name or id of "length"
    60506093                        for ( i = 0; srcElements[i]; ++i ) {
    6051                                 cloneFixAttributes( srcElements[i], destElements[i] );
     6094                                // Ensure that the destination node is not null; Fixes #9587
     6095                                if ( destElements[i] ) {
     6096                                        cloneFixAttributes( srcElements[i], destElements[i] );
     6097                                }
    60526098                        }
    60536099                }
     
    62496295
    62506296
     6297
    62516298var ralpha = /alpha\([^)]*\)/i,
    62526299        ropacity = /opacity=([^)]*)/,
     
    62556302        rnumpx = /^-?\d+(?:px)?$/i,
    62566303        rnum = /^-?\d/,
    6257         rrelNum = /^[+\-]=/,
    6258         rrelNumFilter = /[^+\-\.\de]+/g,
     6304        rrelNum = /^([\-+])=([\-+.\de]+)/,
    62596305
    62606306        cssShow = { position: "absolute", visibility: "hidden", display: "block" },
     
    63336379                        type = typeof value;
    63346380
    6335                         // Make sure that NaN and null values aren't set. See: #7116
    6336                         if ( type === "number" && isNaN( value ) || value == null ) {
    6337                                 return;
    6338                         }
    6339 
    63406381                        // convert relative number strings (+= or -=) to relative numbers. #7345
    6341                         if ( type === "string" && rrelNum.test( value ) ) {
    6342                                 value = +value.replace( rrelNumFilter, "" ) + parseFloat( jQuery.css( elem, name ) );
     6382                        if ( type === "string" && (ret = rrelNum.exec( value )) ) {
     6383                                value = ( +( ret[1] + 1) * +ret[2] ) + parseFloat( jQuery.css( elem, name ) );
    63436384                                // Fixes bug #9237
    63446385                                type = "number";
     6386                        }
     6387
     6388                        // Make sure that NaN and null values aren't set. See: #7116
     6389                        if ( value == null || type === "number" && isNaN( value ) ) {
     6390                                return;
    63456391                        }
    63466392
     
    64606506                set: function( elem, value ) {
    64616507                        var style = elem.style,
    6462                                 currentStyle = elem.currentStyle;
     6508                                currentStyle = elem.currentStyle,
     6509                                opacity = jQuery.isNaN( value ) ? "" : "alpha(opacity=" + value * 100 + ")",
     6510                                filter = currentStyle && currentStyle.filter || style.filter || "";
    64636511
    64646512                        // IE has trouble with opacity if it does not have layout
     
    64666514                        style.zoom = 1;
    64676515
    6468                         // Set the alpha filter to set the opacity
    6469                         var opacity = jQuery.isNaN( value ) ?
    6470                                 "" :
    6471                                 "alpha(opacity=" + value * 100 + ")",
    6472                                 filter = currentStyle && currentStyle.filter || style.filter || "";
    6473 
     6516                        // if setting opacity to 1, and no other filters exist - attempt to remove filter attribute #6652
     6517                        if ( value >= 1 && jQuery.trim( filter.replace( ralpha, "" ) ) === "" ) {
     6518
     6519                                // Setting style.filter to null, "" & " " still leave "filter:" in the cssText
     6520                                // if "filter:" is present at all, clearType is disabled, we want to avoid this
     6521                                // style.removeAttribute is IE Only, but so apparently is this code path...
     6522                                style.removeAttribute( "filter" );
     6523
     6524                                // if there there is no filter style applied in a css rule, we are done
     6525                                if ( currentStyle && !currentStyle.filter ) {
     6526                                        return;
     6527                                }
     6528                        }
     6529
     6530                        // otherwise, set new filter values
    64746531                        style.filter = ralpha.test( filter ) ?
    64756532                                filter.replace( ralpha, opacity ) :
     
    66266683        rhash = /#.*$/,
    66276684        rheaders = /^(.*?):[ \t]*([^\r\n]*)\r?$/mg, // IE leaves an \r character at EOL
    6628         rinput = /^(?:color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,
     6685        rinput = /^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,
    66296686        // #7653, #8125, #8152: local protocol detection
    6630         rlocalProtocol = /^(?:about|app|app\-storage|.+\-extension|file|widget):$/,
     6687        rlocalProtocol = /^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,
    66316688        rnoContent = /^(?:GET|HEAD)$/,
    66326689        rprotocol = /^\/\//,
     
    66636720
    66646721        // Document location segments
    6665         ajaxLocParts;
     6722        ajaxLocParts,
     6723       
     6724        // Avoid comment-prolog char sequence (#10098); must appease lint and evade compression
     6725        allTypes = ["*/"] + ["*"];
    66666726
    66676727// #8138, IE may throw an exception when accessing
     
    67546814        // but it'll be ignored by the caller in that case
    67556815        return selection;
     6816}
     6817
     6818// A special extend for ajax options
     6819// that takes "flat" options (not to be deep extended)
     6820// Fixes #9887
     6821function ajaxExtend( target, src ) {
     6822        var key, deep,
     6823                flatOptions = jQuery.ajaxSettings.flatOptions || {};
     6824        for( key in src ) {
     6825                if ( src[ key ] !== undefined ) {
     6826                        ( flatOptions[ key ] ? target : ( deep || ( deep = {} ) ) )[ key ] = src[ key ];
     6827                }
     6828        }
     6829        if ( deep ) {
     6830                jQuery.extend( true, target, deep );
     6831        }
    67566832}
    67576833
     
    68996975        // with both ajaxSettings and settings fields.
    69006976        // If target is omitted, writes into ajaxSettings.
    6901         ajaxSetup: function ( target, settings ) {
    6902                 if ( !settings ) {
    6903                         // Only one parameter, we extend ajaxSettings
     6977        ajaxSetup: function( target, settings ) {
     6978                if ( settings ) {
     6979                        // Building a settings object
     6980                        ajaxExtend( target, jQuery.ajaxSettings );
     6981                } else {
     6982                        // Extending ajaxSettings
    69046983                        settings = target;
    6905                         target = jQuery.extend( true, jQuery.ajaxSettings, settings );
    6906                 } else {
    6907                         // target was provided, we extend into it
    6908                         jQuery.extend( true, target, jQuery.ajaxSettings, settings );
    6909                 }
    6910                 // Flatten fields we don't want deep extended
    6911                 for( var field in { context: 1, url: 1 } ) {
    6912                         if ( field in settings ) {
    6913                                 target[ field ] = settings[ field ];
    6914                         } else if( field in jQuery.ajaxSettings ) {
    6915                                 target[ field ] = jQuery.ajaxSettings[ field ];
    6916                         }
    6917                 }
     6984                        target = jQuery.ajaxSettings;
     6985                }
     6986                ajaxExtend( target, settings );
    69186987                return target;
    69196988        },
     
    69437012                        text: "text/plain",
    69447013                        json: "application/json, text/javascript",
    6945                         "*": "*/*"
     7014                        "*": allTypes
    69467015                },
    69477016
     
    69737042                        // Parse text as xml
    69747043                        "text xml": jQuery.parseXML
     7044                },
     7045
     7046                // For options that shouldn't be deep extended:
     7047                // you can add your own custom options here if
     7048                // and when you create one that shouldn't be
     7049                // deep extended (see ajaxExtend)
     7050                flatOptions: {
     7051                        context: true,
     7052                        url: true
    69757053                }
    69767054        },
     
    70837161                // It is defined here because jslint complains if it is declared
    70847162                // at the end of the function (which would be more logical and readable)
    7085                 function done( status, statusText, responses, headers ) {
     7163                function done( status, nativeStatusText, responses, headers ) {
    70867164
    70877165                        // Called once
     
    71067184
    71077185                        // Set readyState
    7108                         jqXHR.readyState = status ? 4 : 0;
     7186                        jqXHR.readyState = status > 0 ? 4 : 0;
    71097187
    71107188                        var isSuccess,
    71117189                                success,
    71127190                                error,
     7191                                statusText = nativeStatusText,
    71137192                                response = responses ? ajaxHandleResponses( s, jqXHR, responses ) : undefined,
    71147193                                lastModified,
     
    71627241                        // Set data for the fake xhr object
    71637242                        jqXHR.status = status;
    7164                         jqXHR.statusText = statusText;
     7243                        jqXHR.statusText = "" + ( nativeStatusText || statusText );
    71657244
    71667245                        // Success/Error
     
    71847263
    71857264                        if ( fireGlobals ) {
    7186                                 globalEventContext.trigger( "ajaxComplete", [ jqXHR, s] );
     7265                                globalEventContext.trigger( "ajaxComplete", [ jqXHR, s ] );
    71877266                                // Handle the global AJAX counter
    71887267                                if ( !( --jQuery.active ) ) {
     
    72657344                        if ( s.data ) {
    72667345                                s.url += ( rquery.test( s.url ) ? "&" : "?" ) + s.data;
     7346                                // #9682: remove data so that it's not used in an eventual retry
     7347                                delete s.data;
    72677348                        }
    72687349
     
    73027383                        "Accept",
    73037384                        s.dataTypes[ 0 ] && s.accepts[ s.dataTypes[0] ] ?
    7304                                 s.accepts[ s.dataTypes[0] ] + ( s.dataTypes[ 0 ] !== "*" ? ", */*; q=0.01" : "" ) :
     7385                                s.accepts[ s.dataTypes[0] ] + ( s.dataTypes[ 0 ] !== "*" ? ", " + allTypes + "; q=0.01" : "" ) :
    73057386                                s.accepts[ "*" ]
    73067387                );
     
    73487429                        } catch (e) {
    73497430                                // Propagate exception as error if not done
    7350                                 if ( status < 2 ) {
     7431                                if ( state < 2 ) {
    73517432                                        done( -1, e );
    73527433                                // Simply rethrow otherwise
     
    79968077                [ "opacity" ]
    79978078        ],
    7998         fxNow,
    7999         requestAnimationFrame = window.webkitRequestAnimationFrame ||
    8000                 window.mozRequestAnimationFrame ||
    8001                 window.oRequestAnimationFrame;
     8079        fxNow;
    80028080
    80038081jQuery.fn.extend({
     
    83758453        custom: function( from, to, unit ) {
    83768454                var self = this,
    8377                         fx = jQuery.fx,
    8378                         raf;
     8455                        fx = jQuery.fx;
    83798456
    83808457                this.startTime = fxNow || createFxNow();
     
    83928469
    83938470                if ( t() && jQuery.timers.push(t) && !timerId ) {
    8394                         // Use requestAnimationFrame instead of setInterval if available
    8395                         if ( requestAnimationFrame ) {
    8396                                 timerId = true;
    8397                                 raf = function() {
    8398                                         // When timerId gets set to null at any point, this stops
    8399                                         if ( timerId ) {
    8400                                                 requestAnimationFrame( raf );
    8401                                                 fx.tick();
    8402                                         }
    8403                                 };
    8404                                 requestAnimationFrame( raf );
    8405                         } else {
    8406                                 timerId = setInterval( fx.tick, fx.interval );
    8407                         }
     8471                        timerId = setInterval( fx.tick, fx.interval );
    84088472                }
    84098473        },
     
    89489012                        // Everyone else use document.documentElement or document.body depending on Quirks vs Standards mode
    89499013                        // 3rd condition allows Nokia support, as it supports the docElem prop but not CSS1Compat
    8950                         var docElemProp = elem.document.documentElement[ "client" + name ];
     9014                        var docElemProp = elem.document.documentElement[ "client" + name ],
     9015                                body = elem.document.body;
    89519016                        return elem.document.compatMode === "CSS1Compat" && docElemProp ||
    8952                                 elem.document.body[ "client" + name ] || docElemProp;
     9017                                body && body[ "client" + name ] || docElemProp;
    89539018
    89549019                // Get document width or height
Note: See TracChangeset for help on using the changeset viewer.