jquery-rails 2.2.0 → 2.2.1
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of jquery-rails might be problematic. Click here for more details.
- data/CHANGELOG.md +6 -1
- data/README.md +4 -1
- data/jquery-rails.gemspec +1 -0
- data/lib/jquery/rails/version.rb +3 -3
- data/vendor/assets/javascripts/jquery.js +229 -187
- data/vendor/assets/javascripts/jquery.min.js +5 -4
- data/vendor/assets/javascripts/jquery.min.map +1 -1
- data/vendor/assets/javascripts/jquery_ujs.js +16 -45
- metadata +9 -8
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -4,7 +4,7 @@ jQuery! For Rails! So great.
|
|
4
4
|
|
5
5
|
This gem provides:
|
6
6
|
|
7
|
-
* jQuery 1.9.
|
7
|
+
* jQuery 1.9.1
|
8
8
|
* jQuery UI 1.9.2 (javascript only)
|
9
9
|
* the jQuery UJS adapter
|
10
10
|
* assert_select_jquery to test jQuery responses in Ruby tests
|
@@ -20,6 +20,9 @@ minor version bump = minor-level updates to jquery
|
|
20
20
|
major version bump = major-level updates to jquery and updates to rails which may be backwards-incompatible
|
21
21
|
```
|
22
22
|
|
23
|
+
See CHANGELOG.md to see which versions of jquery-rails bundle which
|
24
|
+
versions of jQuery.
|
25
|
+
|
23
26
|
## Installation
|
24
27
|
|
25
28
|
Apps generated with Rails 3.1 or later include jquery-rails in the Gemfile by default. So just make a new app:
|
data/jquery-rails.gemspec
CHANGED
@@ -10,6 +10,7 @@ Gem::Specification.new do |s|
|
|
10
10
|
s.homepage = "http://rubygems.org/gems/jquery-rails"
|
11
11
|
s.summary = "Use jQuery with Rails 3"
|
12
12
|
s.description = "This gem provides jQuery and the jQuery-ujs driver for your Rails 3 application."
|
13
|
+
s.license = "MIT"
|
13
14
|
|
14
15
|
s.required_rubygems_version = ">= 1.3.6"
|
15
16
|
s.rubyforge_project = "jquery-rails"
|
data/lib/jquery/rails/version.rb
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
module Jquery
|
2
2
|
module Rails
|
3
|
-
VERSION = "2.2.
|
4
|
-
JQUERY_VERSION = "1.
|
3
|
+
VERSION = "2.2.1"
|
4
|
+
JQUERY_VERSION = "1.9.1"
|
5
5
|
JQUERY_UI_VERSION = "1.9.2"
|
6
|
-
JQUERY_UJS_VERSION = "
|
6
|
+
JQUERY_UJS_VERSION = "aab2251d90afbdfc808d8031312d063b1ccf8f6f"
|
7
7
|
end
|
8
8
|
end
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/*!
|
2
|
-
* jQuery JavaScript Library v1.9.
|
2
|
+
* jQuery JavaScript Library v1.9.1
|
3
3
|
* http://jquery.com/
|
4
4
|
*
|
5
5
|
* Includes Sizzle.js
|
@@ -9,16 +9,25 @@
|
|
9
9
|
* Released under the MIT license
|
10
10
|
* http://jquery.org/license
|
11
11
|
*
|
12
|
-
* Date: 2013-
|
12
|
+
* Date: 2013-2-4
|
13
13
|
*/
|
14
14
|
(function( window, undefined ) {
|
15
|
-
|
15
|
+
|
16
|
+
// Can't do this because several apps including ASP.NET trace
|
17
|
+
// the stack via arguments.caller.callee and Firefox dies if
|
18
|
+
// you try to trace through "use strict" call chains. (#13335)
|
19
|
+
// Support: Firefox 18+
|
20
|
+
//"use strict";
|
16
21
|
var
|
22
|
+
// The deferred used on DOM ready
|
23
|
+
readyList,
|
24
|
+
|
17
25
|
// A central reference to the root jQuery(document)
|
18
26
|
rootjQuery,
|
19
27
|
|
20
|
-
//
|
21
|
-
|
28
|
+
// Support: IE<9
|
29
|
+
// For `typeof node.method` instead of `node.method !== undefined`
|
30
|
+
core_strundefined = typeof undefined,
|
22
31
|
|
23
32
|
// Use the correct document accordingly with window argument (sandbox)
|
24
33
|
document = window.document,
|
@@ -36,7 +45,7 @@ var
|
|
36
45
|
// List of deleted data cache ids, so we can reuse them
|
37
46
|
core_deletedIds = [],
|
38
47
|
|
39
|
-
core_version = "1.9.
|
48
|
+
core_version = "1.9.1",
|
40
49
|
|
41
50
|
// Save a reference to some core methods
|
42
51
|
core_concat = core_deletedIds.concat,
|
@@ -85,17 +94,25 @@ var
|
|
85
94
|
return letter.toUpperCase();
|
86
95
|
},
|
87
96
|
|
88
|
-
// The ready event handler
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
// we're here because readyState === "complete" in oldIE
|
95
|
-
// which is good enough for us to call the dom ready!
|
96
|
-
document.detachEvent( "onreadystatechange", DOMContentLoaded );
|
97
|
+
// The ready event handler
|
98
|
+
completed = function( event ) {
|
99
|
+
|
100
|
+
// readyState === "complete" is good enough for us to call the dom ready in oldIE
|
101
|
+
if ( document.addEventListener || event.type === "load" || document.readyState === "complete" ) {
|
102
|
+
detach();
|
97
103
|
jQuery.ready();
|
98
104
|
}
|
105
|
+
},
|
106
|
+
// Clean-up method for dom ready events
|
107
|
+
detach = function() {
|
108
|
+
if ( document.addEventListener ) {
|
109
|
+
document.removeEventListener( "DOMContentLoaded", completed, false );
|
110
|
+
window.removeEventListener( "load", completed, false );
|
111
|
+
|
112
|
+
} else {
|
113
|
+
document.detachEvent( "onreadystatechange", completed );
|
114
|
+
window.detachEvent( "onload", completed );
|
115
|
+
}
|
99
116
|
};
|
100
117
|
|
101
118
|
jQuery.fn = jQuery.prototype = {
|
@@ -299,7 +316,7 @@ jQuery.fn = jQuery.prototype = {
|
|
299
316
|
jQuery.fn.init.prototype = jQuery.fn;
|
300
317
|
|
301
318
|
jQuery.extend = jQuery.fn.extend = function() {
|
302
|
-
var
|
319
|
+
var src, copyIsArray, copy, name, options, clone,
|
303
320
|
target = arguments[0] || {},
|
304
321
|
i = 1,
|
305
322
|
length = arguments.length,
|
@@ -781,7 +798,7 @@ jQuery.extend({
|
|
781
798
|
// Bind a function to a context, optionally partially applying any
|
782
799
|
// arguments.
|
783
800
|
proxy: function( fn, context ) {
|
784
|
-
var
|
801
|
+
var args, proxy, tmp;
|
785
802
|
|
786
803
|
if ( typeof context === "string" ) {
|
787
804
|
tmp = fn[ context ];
|
@@ -880,18 +897,18 @@ jQuery.ready.promise = function( obj ) {
|
|
880
897
|
// Standards-based browsers support DOMContentLoaded
|
881
898
|
} else if ( document.addEventListener ) {
|
882
899
|
// Use the handy event callback
|
883
|
-
document.addEventListener( "DOMContentLoaded",
|
900
|
+
document.addEventListener( "DOMContentLoaded", completed, false );
|
884
901
|
|
885
902
|
// A fallback to window.onload, that will always work
|
886
|
-
window.addEventListener( "load",
|
903
|
+
window.addEventListener( "load", completed, false );
|
887
904
|
|
888
905
|
// If IE event model is used
|
889
906
|
} else {
|
890
907
|
// Ensure firing before onload, maybe late but safe also for iframes
|
891
|
-
document.attachEvent( "onreadystatechange",
|
908
|
+
document.attachEvent( "onreadystatechange", completed );
|
892
909
|
|
893
910
|
// A fallback to window.onload, that will always work
|
894
|
-
window.attachEvent( "onload",
|
911
|
+
window.attachEvent( "onload", completed );
|
895
912
|
|
896
913
|
// If IE and not a frame
|
897
914
|
// continually check to see if the document is ready
|
@@ -913,6 +930,9 @@ jQuery.ready.promise = function( obj ) {
|
|
913
930
|
return setTimeout( doScrollCheck, 50 );
|
914
931
|
}
|
915
932
|
|
933
|
+
// detach all dom ready events
|
934
|
+
detach();
|
935
|
+
|
916
936
|
// and execute any waiting functions
|
917
937
|
jQuery.ready();
|
918
938
|
}
|
@@ -989,18 +1009,18 @@ jQuery.Callbacks = function( options ) {
|
|
989
1009
|
( optionsCache[ options ] || createOptions( options ) ) :
|
990
1010
|
jQuery.extend( {}, options );
|
991
1011
|
|
992
|
-
var //
|
1012
|
+
var // Flag to know if list is currently firing
|
1013
|
+
firing,
|
1014
|
+
// Last fire value (for non-forgettable lists)
|
993
1015
|
memory,
|
994
1016
|
// Flag to know if list was already fired
|
995
1017
|
fired,
|
996
|
-
// Flag to know if list is currently firing
|
997
|
-
firing,
|
998
|
-
// First callback to fire (used internally by add and fireWith)
|
999
|
-
firingStart,
|
1000
1018
|
// End of the loop when firing
|
1001
1019
|
firingLength,
|
1002
1020
|
// Index of currently firing callback (modified by remove if needed)
|
1003
1021
|
firingIndex,
|
1022
|
+
// First callback to fire (used internally by add and fireWith)
|
1023
|
+
firingStart,
|
1004
1024
|
// Actual callback list
|
1005
1025
|
list = [],
|
1006
1026
|
// Stack of fire calls for repeatable lists
|
@@ -1086,9 +1106,10 @@ jQuery.Callbacks = function( options ) {
|
|
1086
1106
|
}
|
1087
1107
|
return this;
|
1088
1108
|
},
|
1089
|
-
//
|
1109
|
+
// Check if a given callback is in the list.
|
1110
|
+
// If no argument is given, return whether or not list has callbacks attached.
|
1090
1111
|
has: function( fn ) {
|
1091
|
-
return jQuery.inArray( fn, list ) > -1;
|
1112
|
+
return fn ? jQuery.inArray( fn, list ) > -1 : !!( list && list.length );
|
1092
1113
|
},
|
1093
1114
|
// Remove all callbacks from the list
|
1094
1115
|
empty: function() {
|
@@ -1285,7 +1306,9 @@ jQuery.extend({
|
|
1285
1306
|
});
|
1286
1307
|
jQuery.support = (function() {
|
1287
1308
|
|
1288
|
-
var support, all, a,
|
1309
|
+
var support, all, a,
|
1310
|
+
input, select, fragment,
|
1311
|
+
opt, eventName, isSupported, i,
|
1289
1312
|
div = document.createElement("div");
|
1290
1313
|
|
1291
1314
|
// Setup
|
@@ -1486,7 +1509,7 @@ jQuery.support = (function() {
|
|
1486
1509
|
!parseFloat( ( window.getComputedStyle( marginDiv, null ) || {} ).marginRight );
|
1487
1510
|
}
|
1488
1511
|
|
1489
|
-
if ( typeof div.style.zoom !==
|
1512
|
+
if ( typeof div.style.zoom !== core_strundefined ) {
|
1490
1513
|
// Support: IE<8
|
1491
1514
|
// Check if natively block-level elements act like inline-block
|
1492
1515
|
// elements when setting their display to 'inline' and giving
|
@@ -1502,9 +1525,12 @@ jQuery.support = (function() {
|
|
1502
1525
|
div.firstChild.style.width = "5px";
|
1503
1526
|
support.shrinkWrapBlocks = ( div.offsetWidth !== 3 );
|
1504
1527
|
|
1505
|
-
|
1506
|
-
|
1507
|
-
|
1528
|
+
if ( support.inlineBlockNeedsLayout ) {
|
1529
|
+
// Prevent IE 6 from affecting layout for positioned elements #11048
|
1530
|
+
// Prevent IE from shrinking the body in IE 7 mode #12869
|
1531
|
+
// Support: IE<8
|
1532
|
+
body.style.zoom = 1;
|
1533
|
+
}
|
1508
1534
|
}
|
1509
1535
|
|
1510
1536
|
body.removeChild( container );
|
@@ -1521,7 +1547,7 @@ jQuery.support = (function() {
|
|
1521
1547
|
|
1522
1548
|
var rbrace = /(?:\{[\s\S]*\}|\[[\s\S]*\])$/,
|
1523
1549
|
rmultiDash = /([A-Z])/g;
|
1524
|
-
|
1550
|
+
|
1525
1551
|
function internalData( elem, name, data, pvt /* Internal Use Only */ ){
|
1526
1552
|
if ( !jQuery.acceptData( elem ) ) {
|
1527
1553
|
return;
|
@@ -1616,13 +1642,12 @@ function internalData( elem, name, data, pvt /* Internal Use Only */ ){
|
|
1616
1642
|
return ret;
|
1617
1643
|
}
|
1618
1644
|
|
1619
|
-
function internalRemoveData( elem, name, pvt
|
1645
|
+
function internalRemoveData( elem, name, pvt ) {
|
1620
1646
|
if ( !jQuery.acceptData( elem ) ) {
|
1621
1647
|
return;
|
1622
1648
|
}
|
1623
1649
|
|
1624
|
-
var
|
1625
|
-
|
1650
|
+
var i, l, thisCache,
|
1626
1651
|
isNode = elem.nodeType,
|
1627
1652
|
|
1628
1653
|
// See jQuery.data for more information
|
@@ -1726,24 +1751,29 @@ jQuery.extend({
|
|
1726
1751
|
},
|
1727
1752
|
|
1728
1753
|
data: function( elem, name, data ) {
|
1729
|
-
return internalData( elem, name, data
|
1754
|
+
return internalData( elem, name, data );
|
1730
1755
|
},
|
1731
1756
|
|
1732
1757
|
removeData: function( elem, name ) {
|
1733
|
-
return internalRemoveData( elem, name
|
1758
|
+
return internalRemoveData( elem, name );
|
1734
1759
|
},
|
1735
1760
|
|
1736
1761
|
// For internal use only.
|
1737
1762
|
_data: function( elem, name, data ) {
|
1738
1763
|
return internalData( elem, name, data, true );
|
1739
1764
|
},
|
1740
|
-
|
1765
|
+
|
1741
1766
|
_removeData: function( elem, name ) {
|
1742
1767
|
return internalRemoveData( elem, name, true );
|
1743
1768
|
},
|
1744
1769
|
|
1745
1770
|
// A method for determining if a DOM node can handle the data expando
|
1746
1771
|
acceptData: function( elem ) {
|
1772
|
+
// Do not set data on non-element because it will not be cleared (#8335).
|
1773
|
+
if ( elem.nodeType && elem.nodeType !== 1 && elem.nodeType !== 9 ) {
|
1774
|
+
return false;
|
1775
|
+
}
|
1776
|
+
|
1747
1777
|
var noData = elem.nodeName && jQuery.noData[ elem.nodeName.toLowerCase() ];
|
1748
1778
|
|
1749
1779
|
// nodes accept data unless otherwise specified; rejection can be conditional
|
@@ -1769,7 +1799,7 @@ jQuery.fn.extend({
|
|
1769
1799
|
name = attrs[i].name;
|
1770
1800
|
|
1771
1801
|
if ( !name.indexOf( "data-" ) ) {
|
1772
|
-
name = jQuery.camelCase( name.
|
1802
|
+
name = jQuery.camelCase( name.slice(5) );
|
1773
1803
|
|
1774
1804
|
dataAttr( elem, name, data[ name ] );
|
1775
1805
|
}
|
@@ -1820,12 +1850,12 @@ function dataAttr( elem, key, data ) {
|
|
1820
1850
|
if ( typeof data === "string" ) {
|
1821
1851
|
try {
|
1822
1852
|
data = data === "true" ? true :
|
1823
|
-
|
1824
|
-
|
1825
|
-
|
1826
|
-
|
1827
|
-
|
1828
|
-
|
1853
|
+
data === "false" ? false :
|
1854
|
+
data === "null" ? null :
|
1855
|
+
// Only convert to a number if it doesn't change the string
|
1856
|
+
+data + "" === data ? +data :
|
1857
|
+
rbrace.test( data ) ? jQuery.parseJSON( data ) :
|
1858
|
+
data;
|
1829
1859
|
} catch( e ) {}
|
1830
1860
|
|
1831
1861
|
// Make sure we set the data so it isn't changed later
|
@@ -2141,7 +2171,7 @@ jQuery.fn.extend({
|
|
2141
2171
|
}
|
2142
2172
|
|
2143
2173
|
// Toggle whole class name
|
2144
|
-
} else if ( type ===
|
2174
|
+
} else if ( type === core_strundefined || type === "boolean" ) {
|
2145
2175
|
if ( this.className ) {
|
2146
2176
|
// store className if set
|
2147
2177
|
jQuery._data( this, "__className__", this.className );
|
@@ -2170,7 +2200,7 @@ jQuery.fn.extend({
|
|
2170
2200
|
},
|
2171
2201
|
|
2172
2202
|
val: function( value ) {
|
2173
|
-
var
|
2203
|
+
var ret, hooks, isFunction,
|
2174
2204
|
elem = this[0];
|
2175
2205
|
|
2176
2206
|
if ( !arguments.length ) {
|
@@ -2294,7 +2324,7 @@ jQuery.extend({
|
|
2294
2324
|
},
|
2295
2325
|
|
2296
2326
|
attr: function( elem, name, value ) {
|
2297
|
-
var
|
2327
|
+
var hooks, notxml, ret,
|
2298
2328
|
nType = elem.nodeType;
|
2299
2329
|
|
2300
2330
|
// don't get/set attributes on text, comment and attribute nodes
|
@@ -2303,7 +2333,7 @@ jQuery.extend({
|
|
2303
2333
|
}
|
2304
2334
|
|
2305
2335
|
// Fallback to prop when attributes are not supported
|
2306
|
-
if ( typeof elem.getAttribute ===
|
2336
|
+
if ( typeof elem.getAttribute === core_strundefined ) {
|
2307
2337
|
return jQuery.prop( elem, name, value );
|
2308
2338
|
}
|
2309
2339
|
|
@@ -2336,7 +2366,7 @@ jQuery.extend({
|
|
2336
2366
|
|
2337
2367
|
// In IE9+, Flash objects don't have .getAttribute (#12945)
|
2338
2368
|
// Support: IE9+
|
2339
|
-
if ( typeof elem.getAttribute !==
|
2369
|
+
if ( typeof elem.getAttribute !== core_strundefined ) {
|
2340
2370
|
ret = elem.getAttribute( name );
|
2341
2371
|
}
|
2342
2372
|
|
@@ -2686,13 +2716,12 @@ jQuery.event = {
|
|
2686
2716
|
global: {},
|
2687
2717
|
|
2688
2718
|
add: function( elem, types, handler, data, selector ) {
|
2719
|
+
var tmp, events, t, handleObjIn,
|
2720
|
+
special, eventHandle, handleObj,
|
2721
|
+
handlers, type, namespaces, origType,
|
2722
|
+
elemData = jQuery._data( elem );
|
2689
2723
|
|
2690
|
-
|
2691
|
-
events, t, handleObj,
|
2692
|
-
special, handlers, type, namespaces, origType,
|
2693
|
-
// Don't attach events to noData or text/comment nodes (but allow plain objects)
|
2694
|
-
elemData = elem.nodeType !== 3 && elem.nodeType !== 8 && jQuery._data( elem );
|
2695
|
-
|
2724
|
+
// Don't attach events to noData or text/comment nodes (but allow plain objects)
|
2696
2725
|
if ( !elemData ) {
|
2697
2726
|
return;
|
2698
2727
|
}
|
@@ -2717,7 +2746,7 @@ jQuery.event = {
|
|
2717
2746
|
eventHandle = elemData.handle = function( e ) {
|
2718
2747
|
// Discard the second event of a jQuery.event.trigger() and
|
2719
2748
|
// when an event is called after a page has unloaded
|
2720
|
-
return typeof jQuery !==
|
2749
|
+
return typeof jQuery !== core_strundefined && (!e || jQuery.event.triggered !== e.type) ?
|
2721
2750
|
jQuery.event.dispatch.apply( eventHandle.elem, arguments ) :
|
2722
2751
|
undefined;
|
2723
2752
|
};
|
@@ -2797,10 +2826,10 @@ jQuery.event = {
|
|
2797
2826
|
|
2798
2827
|
// Detach an event or set of events from an element
|
2799
2828
|
remove: function( elem, types, handler, selector, mappedTypes ) {
|
2800
|
-
|
2801
|
-
|
2802
|
-
|
2803
|
-
|
2829
|
+
var j, handleObj, tmp,
|
2830
|
+
origCount, t, events,
|
2831
|
+
special, handlers, type,
|
2832
|
+
namespaces, origType,
|
2804
2833
|
elemData = jQuery.hasData( elem ) && jQuery._data( elem );
|
2805
2834
|
|
2806
2835
|
if ( !elemData || !(events = elemData.events) ) {
|
@@ -2870,11 +2899,11 @@ jQuery.event = {
|
|
2870
2899
|
},
|
2871
2900
|
|
2872
2901
|
trigger: function( event, data, elem, onlyHandlers ) {
|
2873
|
-
|
2874
|
-
|
2902
|
+
var handle, ontype, cur,
|
2903
|
+
bubbleType, special, tmp, i,
|
2875
2904
|
eventPath = [ elem || document ],
|
2876
|
-
type = event.type
|
2877
|
-
namespaces = event
|
2905
|
+
type = core_hasOwn.call( event, "type" ) ? event.type : event,
|
2906
|
+
namespaces = core_hasOwn.call( event, "namespace" ) ? event.namespace.split(".") : [];
|
2878
2907
|
|
2879
2908
|
cur = tmp = elem = elem || document;
|
2880
2909
|
|
@@ -3008,7 +3037,7 @@ jQuery.event = {
|
|
3008
3037
|
// Make a writable jQuery.Event from the native event object
|
3009
3038
|
event = jQuery.event.fix( event );
|
3010
3039
|
|
3011
|
-
var i,
|
3040
|
+
var i, ret, handleObj, matched, j,
|
3012
3041
|
handlerQueue = [],
|
3013
3042
|
args = core_slice.call( arguments ),
|
3014
3043
|
handlers = ( jQuery._data( this, "events" ) || {} )[ event.type ] || [],
|
@@ -3063,7 +3092,7 @@ jQuery.event = {
|
|
3063
3092
|
},
|
3064
3093
|
|
3065
3094
|
handlers: function( event, handlers ) {
|
3066
|
-
var
|
3095
|
+
var sel, handleObj, matches, i,
|
3067
3096
|
handlerQueue = [],
|
3068
3097
|
delegateCount = handlers.delegateCount,
|
3069
3098
|
cur = event.target;
|
@@ -3075,8 +3104,9 @@ jQuery.event = {
|
|
3075
3104
|
|
3076
3105
|
for ( ; cur != this; cur = cur.parentNode || this ) {
|
3077
3106
|
|
3107
|
+
// Don't check non-elements (#13208)
|
3078
3108
|
// Don't process clicks on disabled elements (#6911, #8165, #11382, #11764)
|
3079
|
-
if ( cur.disabled !== true || event.type !== "click" ) {
|
3109
|
+
if ( cur.nodeType === 1 && (cur.disabled !== true || event.type !== "click") ) {
|
3080
3110
|
matches = [];
|
3081
3111
|
for ( i = 0; i < delegateCount; i++ ) {
|
3082
3112
|
handleObj = handlers[ i ];
|
@@ -3114,10 +3144,18 @@ jQuery.event = {
|
|
3114
3144
|
}
|
3115
3145
|
|
3116
3146
|
// Create a writable copy of the event object and normalize some properties
|
3117
|
-
var i, prop,
|
3147
|
+
var i, prop, copy,
|
3148
|
+
type = event.type,
|
3118
3149
|
originalEvent = event,
|
3119
|
-
fixHook =
|
3120
|
-
|
3150
|
+
fixHook = this.fixHooks[ type ];
|
3151
|
+
|
3152
|
+
if ( !fixHook ) {
|
3153
|
+
this.fixHooks[ type ] = fixHook =
|
3154
|
+
rmouseEvent.test( type ) ? this.mouseHooks :
|
3155
|
+
rkeyEvent.test( type ) ? this.keyHooks :
|
3156
|
+
{};
|
3157
|
+
}
|
3158
|
+
copy = fixHook.props ? this.props.concat( fixHook.props ) : this.props;
|
3121
3159
|
|
3122
3160
|
event = new jQuery.Event( originalEvent );
|
3123
3161
|
|
@@ -3167,7 +3205,7 @@ jQuery.event = {
|
|
3167
3205
|
mouseHooks: {
|
3168
3206
|
props: "button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),
|
3169
3207
|
filter: function( event, original ) {
|
3170
|
-
var eventDoc, doc,
|
3208
|
+
var body, eventDoc, doc,
|
3171
3209
|
button = original.button,
|
3172
3210
|
fromElement = original.fromElement;
|
3173
3211
|
|
@@ -3283,7 +3321,7 @@ jQuery.removeEvent = document.removeEventListener ?
|
|
3283
3321
|
|
3284
3322
|
// #8545, #7054, preventing memory leaks for custom events in IE6-8
|
3285
3323
|
// detachEvent needed property on element, by name of that event, to properly expose it to GC
|
3286
|
-
if ( typeof elem[ name ] ===
|
3324
|
+
if ( typeof elem[ name ] === core_strundefined ) {
|
3287
3325
|
elem[ name ] = null;
|
3288
3326
|
}
|
3289
3327
|
|
@@ -3532,7 +3570,7 @@ if ( !jQuery.support.focusinBubbles ) {
|
|
3532
3570
|
jQuery.fn.extend({
|
3533
3571
|
|
3534
3572
|
on: function( types, selector, data, fn, /*INTERNAL*/ one ) {
|
3535
|
-
var
|
3573
|
+
var type, origFn;
|
3536
3574
|
|
3537
3575
|
// Types can be a map of types/handlers
|
3538
3576
|
if ( typeof types === "object" ) {
|
@@ -3644,30 +3682,6 @@ jQuery.fn.extend({
|
|
3644
3682
|
if ( elem ) {
|
3645
3683
|
return jQuery.event.trigger( type, data, elem, true );
|
3646
3684
|
}
|
3647
|
-
},
|
3648
|
-
|
3649
|
-
hover: function( fnOver, fnOut ) {
|
3650
|
-
return this.mouseenter( fnOver ).mouseleave( fnOut || fnOver );
|
3651
|
-
}
|
3652
|
-
});
|
3653
|
-
|
3654
|
-
jQuery.each( ("blur focus focusin focusout load resize scroll unload click dblclick " +
|
3655
|
-
"mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave " +
|
3656
|
-
"change select submit keydown keypress keyup error contextmenu").split(" "), function( i, name ) {
|
3657
|
-
|
3658
|
-
// Handle event binding
|
3659
|
-
jQuery.fn[ name ] = function( data, fn ) {
|
3660
|
-
return arguments.length > 0 ?
|
3661
|
-
this.on( name, null, data, fn ) :
|
3662
|
-
this.trigger( name );
|
3663
|
-
};
|
3664
|
-
|
3665
|
-
if ( rkeyEvent.test( name ) ) {
|
3666
|
-
jQuery.event.fixHooks[ name ] = jQuery.event.keyHooks;
|
3667
|
-
}
|
3668
|
-
|
3669
|
-
if ( rmouseEvent.test( name ) ) {
|
3670
|
-
jQuery.event.fixHooks[ name ] = jQuery.event.mouseHooks;
|
3671
3685
|
}
|
3672
3686
|
});
|
3673
3687
|
/*!
|
@@ -3781,7 +3795,7 @@ var i,
|
|
3781
3795
|
|
3782
3796
|
rsibling = /[\x20\t\r\n\f]*[+~]/,
|
3783
3797
|
|
3784
|
-
rnative =
|
3798
|
+
rnative = /^[^{]+\{\s*\[native code/,
|
3785
3799
|
|
3786
3800
|
// Easily-parseable/retrievable ID or TAG or CLASS selectors
|
3787
3801
|
rquickExpr = /^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,
|
@@ -3808,12 +3822,12 @@ var i,
|
|
3808
3822
|
|
3809
3823
|
// Use a stripped-down slice if we can't use a native one
|
3810
3824
|
try {
|
3811
|
-
slice.call(
|
3825
|
+
slice.call( preferredDoc.documentElement.childNodes, 0 )[0].nodeType;
|
3812
3826
|
} catch ( e ) {
|
3813
3827
|
slice = function( i ) {
|
3814
3828
|
var elem,
|
3815
3829
|
results = [];
|
3816
|
-
|
3830
|
+
while ( (elem = this[i++]) ) {
|
3817
3831
|
results.push( elem );
|
3818
3832
|
}
|
3819
3833
|
return results;
|
@@ -4132,7 +4146,7 @@ setDocument = Sizzle.setDocument = function( node ) {
|
|
4132
4146
|
|
4133
4147
|
// Filter out possible comments
|
4134
4148
|
if ( tag === "*" ) {
|
4135
|
-
|
4149
|
+
while ( (elem = results[i++]) ) {
|
4136
4150
|
if ( elem.nodeType === 1 ) {
|
4137
4151
|
tmp.push( elem );
|
4138
4152
|
}
|
@@ -4290,15 +4304,11 @@ setDocument = Sizzle.setDocument = function( node ) {
|
|
4290
4304
|
ap = [ a ],
|
4291
4305
|
bp = [ b ];
|
4292
4306
|
|
4293
|
-
//
|
4307
|
+
// Exit early if the nodes are identical
|
4294
4308
|
if ( a === b ) {
|
4295
4309
|
hasDuplicate = true;
|
4296
4310
|
return 0;
|
4297
4311
|
|
4298
|
-
// Fallback to using sourceIndex (in IE) if it's available on both nodes
|
4299
|
-
} else if ( a.sourceIndex && b.sourceIndex ) {
|
4300
|
-
return ( ~b.sourceIndex || MAX_NEGATIVE ) - ( contains( preferredDoc, a ) && ~a.sourceIndex || MAX_NEGATIVE );
|
4301
|
-
|
4302
4312
|
// Parentless nodes are either documents or disconnected
|
4303
4313
|
} else if ( !aup || !bup ) {
|
4304
4314
|
return a === doc ? -1 :
|
@@ -4437,11 +4447,20 @@ Sizzle.uniqueSort = function( results ) {
|
|
4437
4447
|
};
|
4438
4448
|
|
4439
4449
|
function siblingCheck( a, b ) {
|
4440
|
-
var cur =
|
4450
|
+
var cur = b && a,
|
4451
|
+
diff = cur && ( ~b.sourceIndex || MAX_NEGATIVE ) - ( ~a.sourceIndex || MAX_NEGATIVE );
|
4441
4452
|
|
4442
|
-
|
4443
|
-
|
4444
|
-
|
4453
|
+
// Use IE sourceIndex if available on both nodes
|
4454
|
+
if ( diff ) {
|
4455
|
+
return diff;
|
4456
|
+
}
|
4457
|
+
|
4458
|
+
// Check if b follows a
|
4459
|
+
if ( cur ) {
|
4460
|
+
while ( (cur = cur.nextSibling) ) {
|
4461
|
+
if ( cur === b ) {
|
4462
|
+
return -1;
|
4463
|
+
}
|
4445
4464
|
}
|
4446
4465
|
}
|
4447
4466
|
|
@@ -4651,9 +4670,9 @@ Expr = Sizzle.selectors = {
|
|
4651
4670
|
operator === "!=" ? result !== check :
|
4652
4671
|
operator === "^=" ? check && result.indexOf( check ) === 0 :
|
4653
4672
|
operator === "*=" ? check && result.indexOf( check ) > -1 :
|
4654
|
-
operator === "$=" ? check && result.
|
4673
|
+
operator === "$=" ? check && result.slice( -check.length ) === check :
|
4655
4674
|
operator === "~=" ? ( " " + result + " " ).indexOf( check ) > -1 :
|
4656
|
-
operator === "|=" ? result === check || result.
|
4675
|
+
operator === "|=" ? result === check || result.slice( 0, check.length + 1 ) === check + "-" :
|
4657
4676
|
false;
|
4658
4677
|
};
|
4659
4678
|
},
|
@@ -5071,7 +5090,7 @@ function toSelector( tokens ) {
|
|
5071
5090
|
|
5072
5091
|
function addCombinator( matcher, combinator, base ) {
|
5073
5092
|
var dir = combinator.dir,
|
5074
|
-
checkNonElements = base &&
|
5093
|
+
checkNonElements = base && dir === "parentNode",
|
5075
5094
|
doneName = done++;
|
5076
5095
|
|
5077
5096
|
return combinator.first ?
|
@@ -5314,8 +5333,8 @@ function matcherFromGroupMatchers( elementMatchers, setMatchers ) {
|
|
5314
5333
|
contextBackup = outermostContext,
|
5315
5334
|
// We must always have either seed elements or context
|
5316
5335
|
elems = seed || byElement && Expr.find["TAG"]( "*", expandContext && context.parentNode || context ),
|
5317
|
-
//
|
5318
|
-
dirrunsUnique = (dirruns += contextBackup == null ? 1 : Math.
|
5336
|
+
// Use integer dirruns iff this is the outermost matcher
|
5337
|
+
dirrunsUnique = (dirruns += contextBackup == null ? 1 : Math.random() || 0.1);
|
5319
5338
|
|
5320
5339
|
if ( outermost ) {
|
5321
5340
|
outermostContext = context !== document && context;
|
@@ -5323,9 +5342,11 @@ function matcherFromGroupMatchers( elementMatchers, setMatchers ) {
|
|
5323
5342
|
}
|
5324
5343
|
|
5325
5344
|
// Add elements passing elementMatchers directly to results
|
5345
|
+
// Keep `i` a string if there are no elements so `matchedCount` will be "00" below
|
5326
5346
|
for ( ; (elem = elems[i]) != null; i++ ) {
|
5327
5347
|
if ( byElement && elem ) {
|
5328
|
-
|
5348
|
+
j = 0;
|
5349
|
+
while ( (matcher = elementMatchers[j++]) ) {
|
5329
5350
|
if ( matcher( elem, context, xml ) ) {
|
5330
5351
|
results.push( elem );
|
5331
5352
|
break;
|
@@ -5352,10 +5373,10 @@ function matcherFromGroupMatchers( elementMatchers, setMatchers ) {
|
|
5352
5373
|
}
|
5353
5374
|
|
5354
5375
|
// Apply set filters to unmatched elements
|
5355
|
-
// `i` starts as a string, so matchedCount would equal "00" if there are no elements
|
5356
5376
|
matchedCount += i;
|
5357
5377
|
if ( bySet && i !== matchedCount ) {
|
5358
|
-
|
5378
|
+
j = 0;
|
5379
|
+
while ( (matcher = setMatchers[j++]) ) {
|
5359
5380
|
matcher( unmatched, setMatched, context, xml );
|
5360
5381
|
}
|
5361
5382
|
|
@@ -5457,7 +5478,8 @@ function select( selector, context, results, seed ) {
|
|
5457
5478
|
}
|
5458
5479
|
|
5459
5480
|
// Fetch a seed set for right-to-left matching
|
5460
|
-
|
5481
|
+
i = matchExpr["needsContext"].test( selector ) ? 0 : tokens.length;
|
5482
|
+
while ( i-- ) {
|
5461
5483
|
token = tokens[i];
|
5462
5484
|
|
5463
5485
|
// Abort if we hit a combinator
|
@@ -5535,12 +5557,13 @@ var runtil = /Until$/,
|
|
5535
5557
|
|
5536
5558
|
jQuery.fn.extend({
|
5537
5559
|
find: function( selector ) {
|
5538
|
-
var i, ret, self
|
5560
|
+
var i, ret, self,
|
5561
|
+
len = this.length;
|
5539
5562
|
|
5540
5563
|
if ( typeof selector !== "string" ) {
|
5541
5564
|
self = this;
|
5542
5565
|
return this.pushStack( jQuery( selector ).filter(function() {
|
5543
|
-
for ( i = 0; i <
|
5566
|
+
for ( i = 0; i < len; i++ ) {
|
5544
5567
|
if ( jQuery.contains( self[ i ], this ) ) {
|
5545
5568
|
return true;
|
5546
5569
|
}
|
@@ -5549,12 +5572,12 @@ jQuery.fn.extend({
|
|
5549
5572
|
}
|
5550
5573
|
|
5551
5574
|
ret = [];
|
5552
|
-
for ( i = 0; i <
|
5575
|
+
for ( i = 0; i < len; i++ ) {
|
5553
5576
|
jQuery.find( selector, this[ i ], ret );
|
5554
5577
|
}
|
5555
5578
|
|
5556
5579
|
// Needed because $( selector, context ) becomes $( context ).find( selector )
|
5557
|
-
ret = this.pushStack( jQuery.unique( ret ) );
|
5580
|
+
ret = this.pushStack( len > 1 ? jQuery.unique( ret ) : ret );
|
5558
5581
|
ret.selector = ( this.selector ? this.selector + " " : "" ) + selector;
|
5559
5582
|
return ret;
|
5560
5583
|
},
|
@@ -6066,15 +6089,9 @@ jQuery.fn.extend({
|
|
6066
6089
|
var next = this.nextSibling,
|
6067
6090
|
parent = this.parentNode;
|
6068
6091
|
|
6069
|
-
if ( parent
|
6070
|
-
|
6092
|
+
if ( parent ) {
|
6071
6093
|
jQuery( this ).remove();
|
6072
|
-
|
6073
|
-
if ( next ) {
|
6074
|
-
next.parentNode.insertBefore( elem, next );
|
6075
|
-
} else {
|
6076
|
-
parent.appendChild( elem );
|
6077
|
-
}
|
6094
|
+
parent.insertBefore( elem, next );
|
6078
6095
|
}
|
6079
6096
|
});
|
6080
6097
|
},
|
@@ -6088,7 +6105,8 @@ jQuery.fn.extend({
|
|
6088
6105
|
// Flatten any nested arrays
|
6089
6106
|
args = core_concat.apply( [], args );
|
6090
6107
|
|
6091
|
-
var
|
6108
|
+
var first, node, hasScripts,
|
6109
|
+
scripts, doc, fragment,
|
6092
6110
|
i = 0,
|
6093
6111
|
l = this.length,
|
6094
6112
|
set = this,
|
@@ -6239,7 +6257,7 @@ function cloneCopyEvent( src, dest ) {
|
|
6239
6257
|
}
|
6240
6258
|
|
6241
6259
|
function fixCloneNodeIssues( src, dest ) {
|
6242
|
-
var nodeName,
|
6260
|
+
var nodeName, e, data;
|
6243
6261
|
|
6244
6262
|
// We do not need to do anything for non-Elements
|
6245
6263
|
if ( dest.nodeType !== 1 ) {
|
@@ -6334,8 +6352,8 @@ jQuery.each({
|
|
6334
6352
|
function getAll( context, tag ) {
|
6335
6353
|
var elems, elem,
|
6336
6354
|
i = 0,
|
6337
|
-
found = typeof context.getElementsByTagName !==
|
6338
|
-
typeof context.querySelectorAll !==
|
6355
|
+
found = typeof context.getElementsByTagName !== core_strundefined ? context.getElementsByTagName( tag || "*" ) :
|
6356
|
+
typeof context.querySelectorAll !== core_strundefined ? context.querySelectorAll( tag || "*" ) :
|
6339
6357
|
undefined;
|
6340
6358
|
|
6341
6359
|
if ( !found ) {
|
@@ -6362,7 +6380,7 @@ function fixDefaultChecked( elem ) {
|
|
6362
6380
|
|
6363
6381
|
jQuery.extend({
|
6364
6382
|
clone: function( elem, dataAndEvents, deepDataAndEvents ) {
|
6365
|
-
var destElements,
|
6383
|
+
var destElements, node, clone, i, srcElements,
|
6366
6384
|
inPage = jQuery.contains( elem.ownerDocument, elem );
|
6367
6385
|
|
6368
6386
|
if ( jQuery.support.html5Clone || jQuery.isXMLDoc(elem) || !rnoshimcache.test( "<" + elem.nodeName + ">" ) ) {
|
@@ -6417,7 +6435,8 @@ jQuery.extend({
|
|
6417
6435
|
},
|
6418
6436
|
|
6419
6437
|
buildFragment: function( elems, context, scripts, selection ) {
|
6420
|
-
var
|
6438
|
+
var j, elem, contains,
|
6439
|
+
tmp, tag, tbody, wrap,
|
6421
6440
|
l = elems.length,
|
6422
6441
|
|
6423
6442
|
// Ensure a safe fragment
|
@@ -6543,7 +6562,7 @@ jQuery.extend({
|
|
6543
6562
|
},
|
6544
6563
|
|
6545
6564
|
cleanData: function( elems, /* internal */ acceptData ) {
|
6546
|
-
var
|
6565
|
+
var elem, type, id, data,
|
6547
6566
|
i = 0,
|
6548
6567
|
internalKey = jQuery.expando,
|
6549
6568
|
cache = jQuery.cache,
|
@@ -6581,7 +6600,7 @@ jQuery.extend({
|
|
6581
6600
|
if ( deleteExpando ) {
|
6582
6601
|
delete elem[ internalKey ];
|
6583
6602
|
|
6584
|
-
} else if ( typeof elem.removeAttribute !==
|
6603
|
+
} else if ( typeof elem.removeAttribute !== core_strundefined ) {
|
6585
6604
|
elem.removeAttribute( internalKey );
|
6586
6605
|
|
6587
6606
|
} else {
|
@@ -6595,7 +6614,7 @@ jQuery.extend({
|
|
6595
6614
|
}
|
6596
6615
|
}
|
6597
6616
|
});
|
6598
|
-
var
|
6617
|
+
var iframe, getStyles, curCSS,
|
6599
6618
|
ralpha = /alpha\([^)]*\)/i,
|
6600
6619
|
ropacity = /opacity\s*=\s*([^)]*)/,
|
6601
6620
|
rposition = /^(top|right|bottom|left)$/,
|
@@ -6648,7 +6667,7 @@ function isHidden( elem, el ) {
|
|
6648
6667
|
}
|
6649
6668
|
|
6650
6669
|
function showHide( elements, show ) {
|
6651
|
-
var elem,
|
6670
|
+
var display, elem, hidden,
|
6652
6671
|
values = [],
|
6653
6672
|
index = 0,
|
6654
6673
|
length = elements.length;
|
@@ -6658,11 +6677,13 @@ function showHide( elements, show ) {
|
|
6658
6677
|
if ( !elem.style ) {
|
6659
6678
|
continue;
|
6660
6679
|
}
|
6680
|
+
|
6661
6681
|
values[ index ] = jQuery._data( elem, "olddisplay" );
|
6682
|
+
display = elem.style.display;
|
6662
6683
|
if ( show ) {
|
6663
6684
|
// Reset the inline display of this element to learn if it is
|
6664
6685
|
// being hidden by cascaded rules or not
|
6665
|
-
if ( !values[ index ] &&
|
6686
|
+
if ( !values[ index ] && display === "none" ) {
|
6666
6687
|
elem.style.display = "";
|
6667
6688
|
}
|
6668
6689
|
|
@@ -6672,8 +6693,15 @@ function showHide( elements, show ) {
|
|
6672
6693
|
if ( elem.style.display === "" && isHidden( elem ) ) {
|
6673
6694
|
values[ index ] = jQuery._data( elem, "olddisplay", css_defaultDisplay(elem.nodeName) );
|
6674
6695
|
}
|
6675
|
-
} else
|
6676
|
-
|
6696
|
+
} else {
|
6697
|
+
|
6698
|
+
if ( !values[ index ] ) {
|
6699
|
+
hidden = isHidden( elem );
|
6700
|
+
|
6701
|
+
if ( display && display !== "none" || !hidden ) {
|
6702
|
+
jQuery._data( elem, "olddisplay", hidden ? display : jQuery.css( elem, "display" ) );
|
6703
|
+
}
|
6704
|
+
}
|
6677
6705
|
}
|
6678
6706
|
}
|
6679
6707
|
|
@@ -6695,7 +6723,7 @@ function showHide( elements, show ) {
|
|
6695
6723
|
jQuery.fn.extend({
|
6696
6724
|
css: function( name, value ) {
|
6697
6725
|
return jQuery.access( this, function( elem, name, value ) {
|
6698
|
-
var
|
6726
|
+
var len, styles,
|
6699
6727
|
map = {},
|
6700
6728
|
i = 0;
|
6701
6729
|
|
@@ -6836,7 +6864,7 @@ jQuery.extend({
|
|
6836
6864
|
},
|
6837
6865
|
|
6838
6866
|
css: function( elem, name, extra, styles ) {
|
6839
|
-
var
|
6867
|
+
var num, val, hooks,
|
6840
6868
|
origName = jQuery.camelCase( name );
|
6841
6869
|
|
6842
6870
|
// Make sure that we're working with the right name
|
@@ -6862,7 +6890,7 @@ jQuery.extend({
|
|
6862
6890
|
}
|
6863
6891
|
|
6864
6892
|
// Return, converting to number if forced or a qualifier was provided and val looks numeric
|
6865
|
-
if ( extra ) {
|
6893
|
+
if ( extra === "" || extra ) {
|
6866
6894
|
num = parseFloat( val );
|
6867
6895
|
return extra === true || jQuery.isNumeric( num ) ? num || 0 : val;
|
6868
6896
|
}
|
@@ -7227,7 +7255,10 @@ jQuery(function() {
|
|
7227
7255
|
|
7228
7256
|
if ( jQuery.expr && jQuery.expr.filters ) {
|
7229
7257
|
jQuery.expr.filters.hidden = function( elem ) {
|
7230
|
-
|
7258
|
+
// Support: Opera <= 12.12
|
7259
|
+
// Opera reports offsetWidths and offsetHeights less than zero on some elements
|
7260
|
+
return elem.offsetWidth <= 0 && elem.offsetHeight <= 0 ||
|
7261
|
+
(!jQuery.support.reliableHiddenOffsets && ((elem.style && elem.style.display) || jQuery.css( elem, "display" )) === "none");
|
7231
7262
|
};
|
7232
7263
|
|
7233
7264
|
jQuery.expr.filters.visible = function( elem ) {
|
@@ -7265,7 +7296,7 @@ jQuery.each({
|
|
7265
7296
|
var r20 = /%20/g,
|
7266
7297
|
rbracket = /\[\]$/,
|
7267
7298
|
rCRLF = /\r?\n/g,
|
7268
|
-
rsubmitterTypes = /^(?:submit|button|image|reset)$/i,
|
7299
|
+
rsubmitterTypes = /^(?:submit|button|image|reset|file)$/i,
|
7269
7300
|
rsubmittable = /^(?:input|select|textarea|keygen)/i;
|
7270
7301
|
|
7271
7302
|
jQuery.fn.extend({
|
@@ -7361,11 +7392,25 @@ function buildParams( prefix, obj, traditional, add ) {
|
|
7361
7392
|
add( prefix, obj );
|
7362
7393
|
}
|
7363
7394
|
}
|
7395
|
+
jQuery.each( ("blur focus focusin focusout load resize scroll unload click dblclick " +
|
7396
|
+
"mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave " +
|
7397
|
+
"change select submit keydown keypress keyup error contextmenu").split(" "), function( i, name ) {
|
7398
|
+
|
7399
|
+
// Handle event binding
|
7400
|
+
jQuery.fn[ name ] = function( data, fn ) {
|
7401
|
+
return arguments.length > 0 ?
|
7402
|
+
this.on( name, null, data, fn ) :
|
7403
|
+
this.trigger( name );
|
7404
|
+
};
|
7405
|
+
});
|
7406
|
+
|
7407
|
+
jQuery.fn.hover = function( fnOver, fnOut ) {
|
7408
|
+
return this.mouseenter( fnOver ).mouseleave( fnOut || fnOver );
|
7409
|
+
};
|
7364
7410
|
var
|
7365
7411
|
// Document location
|
7366
7412
|
ajaxLocParts,
|
7367
7413
|
ajaxLocation,
|
7368
|
-
|
7369
7414
|
ajax_nonce = jQuery.now(),
|
7370
7415
|
|
7371
7416
|
ajax_rquery = /\?/,
|
@@ -7478,7 +7523,7 @@ function inspectPrefiltersOrTransports( structure, options, originalOptions, jqX
|
|
7478
7523
|
// that takes "flat" options (not to be deep extended)
|
7479
7524
|
// Fixes #9887
|
7480
7525
|
function ajaxExtend( target, src ) {
|
7481
|
-
var
|
7526
|
+
var deep, key,
|
7482
7527
|
flatOptions = jQuery.ajaxSettings.flatOptions || {};
|
7483
7528
|
|
7484
7529
|
for ( key in src ) {
|
@@ -7498,7 +7543,7 @@ jQuery.fn.load = function( url, params, callback ) {
|
|
7498
7543
|
return _load.apply( this, arguments );
|
7499
7544
|
}
|
7500
7545
|
|
7501
|
-
var selector,
|
7546
|
+
var selector, response, type,
|
7502
7547
|
self = this,
|
7503
7548
|
off = url.indexOf(" ");
|
7504
7549
|
|
@@ -7679,20 +7724,23 @@ jQuery.extend({
|
|
7679
7724
|
// Force options to be an object
|
7680
7725
|
options = options || {};
|
7681
7726
|
|
7682
|
-
var
|
7727
|
+
var // Cross-domain detection vars
|
7728
|
+
parts,
|
7729
|
+
// Loop variable
|
7730
|
+
i,
|
7683
7731
|
// URL without anti-cache param
|
7684
7732
|
cacheURL,
|
7685
|
-
// Response headers
|
7733
|
+
// Response headers as string
|
7686
7734
|
responseHeadersString,
|
7687
|
-
responseHeaders,
|
7688
7735
|
// timeout handle
|
7689
7736
|
timeoutTimer,
|
7690
|
-
|
7691
|
-
parts,
|
7737
|
+
|
7692
7738
|
// To know if global events are to be dispatched
|
7693
7739
|
fireGlobals,
|
7694
|
-
|
7695
|
-
|
7740
|
+
|
7741
|
+
transport,
|
7742
|
+
// Response headers
|
7743
|
+
responseHeaders,
|
7696
7744
|
// Create the final options object
|
7697
7745
|
s = jQuery.ajaxSetup( {}, options ),
|
7698
7746
|
// Callbacks context
|
@@ -7987,12 +8035,17 @@ jQuery.extend({
|
|
7987
8035
|
}
|
7988
8036
|
}
|
7989
8037
|
|
7990
|
-
//
|
7991
|
-
if ( status ===
|
8038
|
+
// if no content
|
8039
|
+
if ( status === 204 ) {
|
8040
|
+
isSuccess = true;
|
8041
|
+
statusText = "nocontent";
|
8042
|
+
|
8043
|
+
// if not modified
|
8044
|
+
} else if ( status === 304 ) {
|
7992
8045
|
isSuccess = true;
|
7993
8046
|
statusText = "notmodified";
|
7994
8047
|
|
7995
|
-
// If we have data
|
8048
|
+
// If we have data, let's convert it
|
7996
8049
|
} else {
|
7997
8050
|
isSuccess = ajaxConvert( s, response );
|
7998
8051
|
statusText = isSuccess.state;
|
@@ -8062,8 +8115,7 @@ jQuery.extend({
|
|
8062
8115
|
* - returns the corresponding response
|
8063
8116
|
*/
|
8064
8117
|
function ajaxHandleResponses( s, jqXHR, responses ) {
|
8065
|
-
|
8066
|
-
var ct, type, finalDataType, firstDataType,
|
8118
|
+
var firstDataType, ct, finalDataType, type,
|
8067
8119
|
contents = s.contents,
|
8068
8120
|
dataTypes = s.dataTypes,
|
8069
8121
|
responseFields = s.responseFields;
|
@@ -8124,8 +8176,7 @@ function ajaxHandleResponses( s, jqXHR, responses ) {
|
|
8124
8176
|
|
8125
8177
|
// Chain conversions given the request and the original response
|
8126
8178
|
function ajaxConvert( s, response ) {
|
8127
|
-
|
8128
|
-
var conv, conv2, current, tmp,
|
8179
|
+
var conv2, current, conv, tmp,
|
8129
8180
|
converters = {},
|
8130
8181
|
i = 0,
|
8131
8182
|
// Work with a copy of dataTypes in case we need to modify it for conversion
|
@@ -8476,12 +8527,7 @@ if ( xhrSupported ) {
|
|
8476
8527
|
|
8477
8528
|
// Listener
|
8478
8529
|
callback = function( _, isAbort ) {
|
8479
|
-
|
8480
|
-
var status,
|
8481
|
-
statusText,
|
8482
|
-
responseHeaders,
|
8483
|
-
responses,
|
8484
|
-
xml;
|
8530
|
+
var status, responseHeaders, statusText, responses;
|
8485
8531
|
|
8486
8532
|
// Firefox throws exceptions when accessing properties
|
8487
8533
|
// of an xhr when a network error occurred
|
@@ -8511,14 +8557,8 @@ if ( xhrSupported ) {
|
|
8511
8557
|
} else {
|
8512
8558
|
responses = {};
|
8513
8559
|
status = xhr.status;
|
8514
|
-
xml = xhr.responseXML;
|
8515
8560
|
responseHeaders = xhr.getAllResponseHeaders();
|
8516
8561
|
|
8517
|
-
// Construct response list
|
8518
|
-
if ( xml && xml.documentElement /* #4958 */ ) {
|
8519
|
-
responses.xml = xml;
|
8520
|
-
}
|
8521
|
-
|
8522
8562
|
// When requesting binary data, IE6-9 will throw an exception
|
8523
8563
|
// on any attempt to access responseText (#11426)
|
8524
8564
|
if ( typeof xhr.responseText === "string" ) {
|
@@ -8768,7 +8808,7 @@ function Animation( elem, properties, options ) {
|
|
8768
8808
|
}
|
8769
8809
|
|
8770
8810
|
function propFilter( props, specialEasing ) {
|
8771
|
-
var
|
8811
|
+
var value, name, index, easing, hooks;
|
8772
8812
|
|
8773
8813
|
// camelCase, specialEasing and expand cssHook pass
|
8774
8814
|
for ( index in props ) {
|
@@ -8836,7 +8876,9 @@ jQuery.Animation = jQuery.extend( Animation, {
|
|
8836
8876
|
|
8837
8877
|
function defaultPrefilter( elem, props, opts ) {
|
8838
8878
|
/*jshint validthis:true */
|
8839
|
-
var
|
8879
|
+
var prop, index, length,
|
8880
|
+
value, dataShow, toggle,
|
8881
|
+
tween, hooks, oldfire,
|
8840
8882
|
anim = this,
|
8841
8883
|
style = elem.style,
|
8842
8884
|
orig = {},
|
@@ -8896,7 +8938,7 @@ function defaultPrefilter( elem, props, opts ) {
|
|
8896
8938
|
if ( opts.overflow ) {
|
8897
8939
|
style.overflow = "hidden";
|
8898
8940
|
if ( !jQuery.support.shrinkWrapBlocks ) {
|
8899
|
-
anim.
|
8941
|
+
anim.always(function() {
|
8900
8942
|
style.overflow = opts.overflow[ 0 ];
|
8901
8943
|
style.overflowX = opts.overflow[ 1 ];
|
8902
8944
|
style.overflowY = opts.overflow[ 2 ];
|
@@ -9020,11 +9062,11 @@ Tween.propHooks = {
|
|
9020
9062
|
return tween.elem[ tween.prop ];
|
9021
9063
|
}
|
9022
9064
|
|
9023
|
-
// passing
|
9065
|
+
// passing an empty string as a 3rd parameter to .css will automatically
|
9024
9066
|
// attempt a parseFloat and fallback to a string if the parse fails
|
9025
9067
|
// so, simple values such as "10px" are parsed to Float.
|
9026
9068
|
// complex values such as "rotate(1rad)" are returned as is.
|
9027
|
-
result = jQuery.css( tween.elem, tween.prop, "
|
9069
|
+
result = jQuery.css( tween.elem, tween.prop, "" );
|
9028
9070
|
// Empty strings, null, undefined and "auto" are converted to 0.
|
9029
9071
|
return !result || result === "auto" ? 0 : result;
|
9030
9072
|
},
|
@@ -9346,7 +9388,7 @@ jQuery.fn.offset = function( options ) {
|
|
9346
9388
|
|
9347
9389
|
// If we don't have gBCR, just use 0,0 rather than error
|
9348
9390
|
// BlackBerry 5, iOS 3 (original iPhone)
|
9349
|
-
if ( typeof elem.getBoundingClientRect !==
|
9391
|
+
if ( typeof elem.getBoundingClientRect !== core_strundefined ) {
|
9350
9392
|
box = elem.getBoundingClientRect();
|
9351
9393
|
}
|
9352
9394
|
win = getWindow( doc );
|