Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
J
jquery
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
夏彬
jquery
Commits
22120cea
Commit
22120cea
authored
Nov 07, 2013
by
Oleg
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix some code style inconsistencies
parent
bcae4270
Changes
24
Hide whitespace changes
Inline
Side-by-side
Showing
24 changed files
with
41 additions
and
45 deletions
+41
-45
ajax.js
src/ajax.js
+5
-6
parseXML.js
src/ajax/parseXML.js
+1
-1
support.js
src/attributes/support.js
+1
-1
val.js
src/attributes/val.js
+1
-1
callbacks.js
src/callbacks.js
+1
-1
ready.js
src/core/ready.js
+0
-1
css.js
src/css.js
+1
-1
support.js
src/css/support.js
+1
-2
rmargin.js
src/css/var/rmargin.js
+1
-1
rnumnonpx.js
src/css/var/rnumnonpx.js
+1
-1
data.js
src/data.js
+1
-1
support.js
src/data/support.js
+1
-1
deferred.js
src/deferred.js
+3
-2
effects.js
src/effects.js
+4
-6
Tween.js
src/effects/Tween.js
+1
-1
support.js
src/effects/support.js
+2
-2
event.js
src/event.js
+2
-2
support.js
src/event/support.js
+1
-1
manipulation.js
src/manipulation.js
+3
-3
support.js
src/manipulation/support.js
+1
-1
offset.js
src/offset.js
+3
-3
queue.js
src/queue.js
+1
-1
selector-sizzle.js
src/selector-sizzle.js
+1
-1
serialize.js
src/serialize.js
+4
-4
No files found.
src/ajax.js
View file @
22120cea
...
@@ -102,7 +102,7 @@ function inspectPrefiltersOrTransports( structure, options, originalOptions, jqX
...
@@ -102,7 +102,7 @@ function inspectPrefiltersOrTransports( structure, options, originalOptions, jqX
inspected
[
dataType
]
=
true
;
inspected
[
dataType
]
=
true
;
jQuery
.
each
(
structure
[
dataType
]
||
[],
function
(
_
,
prefilterOrFactory
)
{
jQuery
.
each
(
structure
[
dataType
]
||
[],
function
(
_
,
prefilterOrFactory
)
{
var
dataTypeOrTransport
=
prefilterOrFactory
(
options
,
originalOptions
,
jqXHR
);
var
dataTypeOrTransport
=
prefilterOrFactory
(
options
,
originalOptions
,
jqXHR
);
if
(
typeof
dataTypeOrTransport
===
"string"
&&
!
seekingTransport
&&
!
inspected
[
dataTypeOrTransport
]
)
{
if
(
typeof
dataTypeOrTransport
===
"string"
&&
!
seekingTransport
&&
!
inspected
[
dataTypeOrTransport
]
)
{
options
.
dataTypes
.
unshift
(
dataTypeOrTransport
);
options
.
dataTypes
.
unshift
(
dataTypeOrTransport
);
inspect
(
dataTypeOrTransport
);
inspect
(
dataTypeOrTransport
);
return
false
;
return
false
;
...
@@ -135,7 +135,6 @@ function ajaxExtend( target, src ) {
...
@@ -135,7 +135,6 @@ function ajaxExtend( target, src ) {
return
target
;
return
target
;
}
}
/* Handles responses to an ajax request:
/* Handles responses to an ajax request:
* - finds the right dataType (mediates between content-type and expected dataType)
* - finds the right dataType (mediates between content-type and expected dataType)
* - returns the corresponding response
* - returns the corresponding response
...
@@ -146,7 +145,7 @@ function ajaxHandleResponses( s, jqXHR, responses ) {
...
@@ -146,7 +145,7 @@ function ajaxHandleResponses( s, jqXHR, responses ) {
dataTypes
=
s
.
dataTypes
;
dataTypes
=
s
.
dataTypes
;
// Remove auto dataType and get content-type in the process
// Remove auto dataType and get content-type in the process
while
(
dataTypes
[
0
]
===
"*"
)
{
while
(
dataTypes
[
0
]
===
"*"
)
{
dataTypes
.
shift
();
dataTypes
.
shift
();
if
(
ct
===
undefined
)
{
if
(
ct
===
undefined
)
{
ct
=
s
.
mimeType
||
jqXHR
.
getResponseHeader
(
"Content-Type"
);
ct
=
s
.
mimeType
||
jqXHR
.
getResponseHeader
(
"Content-Type"
);
...
@@ -512,7 +511,7 @@ jQuery.extend({
...
@@ -512,7 +511,7 @@ jQuery.extend({
s
.
type
=
options
.
method
||
options
.
type
||
s
.
method
||
s
.
type
;
s
.
type
=
options
.
method
||
options
.
type
||
s
.
method
||
s
.
type
;
// Extract dataTypes list
// Extract dataTypes list
s
.
dataTypes
=
jQuery
.
trim
(
s
.
dataType
||
"*"
).
toLowerCase
().
match
(
rnotwhite
)
||
[
""
];
s
.
dataTypes
=
jQuery
.
trim
(
s
.
dataType
||
"*"
).
toLowerCase
().
match
(
rnotwhite
)
||
[
""
];
// A cross-domain request is in order when we have a protocol:host:port mismatch
// A cross-domain request is in order when we have a protocol:host:port mismatch
if
(
s
.
crossDomain
==
null
)
{
if
(
s
.
crossDomain
==
null
)
{
...
@@ -798,8 +797,8 @@ jQuery.each( [ "get", "post" ], function( i, method ) {
...
@@ -798,8 +797,8 @@ jQuery.each( [ "get", "post" ], function( i, method ) {
});
});
// Attach a bunch of functions for handling common AJAX events
// Attach a bunch of functions for handling common AJAX events
jQuery
.
each
(
[
"ajaxStart"
,
"ajaxStop"
,
"ajaxComplete"
,
"ajaxError"
,
"ajaxSuccess"
,
"ajaxSend"
],
function
(
i
,
type
){
jQuery
.
each
(
[
"ajaxStart"
,
"ajaxStop"
,
"ajaxComplete"
,
"ajaxError"
,
"ajaxSuccess"
,
"ajaxSend"
],
function
(
i
,
type
)
{
jQuery
.
fn
[
type
]
=
function
(
fn
){
jQuery
.
fn
[
type
]
=
function
(
fn
)
{
return
this
.
on
(
type
,
fn
);
return
this
.
on
(
type
,
fn
);
};
};
});
});
...
...
src/ajax/parseXML.js
View file @
22120cea
...
@@ -11,7 +11,7 @@ jQuery.parseXML = function( data ) {
...
@@ -11,7 +11,7 @@ jQuery.parseXML = function( data ) {
try
{
try
{
if
(
window
.
DOMParser
)
{
// Standard
if
(
window
.
DOMParser
)
{
// Standard
tmp
=
new
DOMParser
();
tmp
=
new
DOMParser
();
xml
=
tmp
.
parseFromString
(
data
,
"text/xml"
);
xml
=
tmp
.
parseFromString
(
data
,
"text/xml"
);
}
else
{
// IE
}
else
{
// IE
xml
=
new
ActiveXObject
(
"Microsoft.XMLDOM"
);
xml
=
new
ActiveXObject
(
"Microsoft.XMLDOM"
);
xml
.
async
=
"false"
;
xml
.
async
=
"false"
;
...
...
src/attributes/support.js
View file @
22120cea
...
@@ -2,7 +2,7 @@ define([
...
@@ -2,7 +2,7 @@ define([
"../var/support"
"../var/support"
],
function
(
support
)
{
],
function
(
support
)
{
(
function
()
{
(
function
()
{
var
a
,
input
,
select
,
opt
,
var
a
,
input
,
select
,
opt
,
div
=
document
.
createElement
(
"div"
);
div
=
document
.
createElement
(
"div"
);
...
...
src/attributes/val.js
View file @
22120cea
...
@@ -52,7 +52,7 @@ jQuery.fn.extend({
...
@@ -52,7 +52,7 @@ jQuery.fn.extend({
}
else
if
(
typeof
val
===
"number"
)
{
}
else
if
(
typeof
val
===
"number"
)
{
val
+=
""
;
val
+=
""
;
}
else
if
(
jQuery
.
isArray
(
val
)
)
{
}
else
if
(
jQuery
.
isArray
(
val
)
)
{
val
=
jQuery
.
map
(
val
,
function
(
value
)
{
val
=
jQuery
.
map
(
val
,
function
(
value
)
{
return
value
==
null
?
""
:
value
+
""
;
return
value
==
null
?
""
:
value
+
""
;
});
});
}
}
...
...
src/callbacks.js
View file @
22120cea
...
@@ -126,7 +126,7 @@ jQuery.Callbacks = function( options ) {
...
@@ -126,7 +126,7 @@ jQuery.Callbacks = function( options ) {
if
(
list
)
{
if
(
list
)
{
jQuery
.
each
(
arguments
,
function
(
_
,
arg
)
{
jQuery
.
each
(
arguments
,
function
(
_
,
arg
)
{
var
index
;
var
index
;
while
(
(
index
=
jQuery
.
inArray
(
arg
,
list
,
index
)
)
>
-
1
)
{
while
(
(
index
=
jQuery
.
inArray
(
arg
,
list
,
index
)
)
>
-
1
)
{
list
.
splice
(
index
,
1
);
list
.
splice
(
index
,
1
);
// Handle firing indexes
// Handle firing indexes
if
(
firing
)
{
if
(
firing
)
{
...
...
src/core/ready.js
View file @
22120cea
...
@@ -87,7 +87,6 @@ function completed() {
...
@@ -87,7 +87,6 @@ function completed() {
}
}
}
}
jQuery
.
ready
.
promise
=
function
(
obj
)
{
jQuery
.
ready
.
promise
=
function
(
obj
)
{
if
(
!
readyList
)
{
if
(
!
readyList
)
{
...
...
src/css.js
View file @
22120cea
...
@@ -422,7 +422,7 @@ if ( !support.opacity ) {
...
@@ -422,7 +422,7 @@ if ( !support.opacity ) {
}
}
jQuery
.
cssHooks
.
marginRight
=
addGetHookIf
(
support
.
reliableMarginRight
,
jQuery
.
cssHooks
.
marginRight
=
addGetHookIf
(
support
.
reliableMarginRight
,
function
(
elem
,
computed
)
{
function
(
elem
,
computed
)
{
if
(
computed
)
{
if
(
computed
)
{
// WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right
// WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right
// Work around by temporarily setting element display to inline-block
// Work around by temporarily setting element display to inline-block
...
...
src/css/support.js
View file @
22120cea
...
@@ -3,7 +3,7 @@ define([
...
@@ -3,7 +3,7 @@ define([
"../var/support"
"../var/support"
],
function
(
jQuery
,
support
)
{
],
function
(
jQuery
,
support
)
{
(
function
()
{
(
function
()
{
var
a
,
reliableHiddenOffsetsVal
,
boxSizingVal
,
boxSizingReliableVal
,
var
a
,
reliableHiddenOffsetsVal
,
boxSizingVal
,
boxSizingReliableVal
,
pixelPositionVal
,
reliableMarginRightVal
,
pixelPositionVal
,
reliableMarginRightVal
,
div
=
document
.
createElement
(
"div"
),
div
=
document
.
createElement
(
"div"
),
...
@@ -34,7 +34,6 @@ define([
...
@@ -34,7 +34,6 @@ define([
// Null elements to avoid leaks in IE.
// Null elements to avoid leaks in IE.
a
=
div
=
null
;
a
=
div
=
null
;
jQuery
.
extend
(
support
,
{
jQuery
.
extend
(
support
,
{
reliableHiddenOffsets
:
function
()
{
reliableHiddenOffsets
:
function
()
{
if
(
reliableHiddenOffsetsVal
!=
null
)
{
if
(
reliableHiddenOffsetsVal
!=
null
)
{
...
...
src/css/var/rmargin.js
View file @
22120cea
define
(
function
()
{
define
(
function
()
{
return
(
/^margin/
);
return
(
/^margin/
);
});
});
\ No newline at end of file
src/css/var/rnumnonpx.js
View file @
22120cea
...
@@ -2,4 +2,4 @@ define([
...
@@ -2,4 +2,4 @@ define([
"../../var/pnum"
"../../var/pnum"
],
function
(
pnum
)
{
],
function
(
pnum
)
{
return
new
RegExp
(
"^("
+
pnum
+
")(?!px)[a-z%]+$"
,
"i"
);
return
new
RegExp
(
"^("
+
pnum
+
")(?!px)[a-z%]+$"
,
"i"
);
});
});
\ No newline at end of file
src/data.js
View file @
22120cea
...
@@ -56,7 +56,7 @@ function isEmptyDataObject( obj ) {
...
@@ -56,7 +56,7 @@ function isEmptyDataObject( obj ) {
return
true
;
return
true
;
}
}
function
internalData
(
elem
,
name
,
data
,
pvt
/* Internal Use Only */
){
function
internalData
(
elem
,
name
,
data
,
pvt
/* Internal Use Only */
)
{
if
(
!
jQuery
.
acceptData
(
elem
)
)
{
if
(
!
jQuery
.
acceptData
(
elem
)
)
{
return
;
return
;
}
}
...
...
src/data/support.js
View file @
22120cea
...
@@ -2,7 +2,7 @@ define([
...
@@ -2,7 +2,7 @@ define([
"../var/support"
"../var/support"
],
function
(
support
)
{
],
function
(
support
)
{
(
function
()
{
(
function
()
{
var
div
=
document
.
createElement
(
"div"
);
var
div
=
document
.
createElement
(
"div"
);
// Execute the test only if not already executed in another module.
// Execute the test only if not already executed in another module.
...
...
src/deferred.js
View file @
22120cea
...
@@ -109,9 +109,10 @@ jQuery.extend({
...
@@ -109,9 +109,10 @@ jQuery.extend({
return
function
(
value
)
{
return
function
(
value
)
{
contexts
[
i
]
=
this
;
contexts
[
i
]
=
this
;
values
[
i
]
=
arguments
.
length
>
1
?
slice
.
call
(
arguments
)
:
value
;
values
[
i
]
=
arguments
.
length
>
1
?
slice
.
call
(
arguments
)
:
value
;
if
(
values
===
progressValues
)
{
if
(
values
===
progressValues
)
{
deferred
.
notifyWith
(
contexts
,
values
);
deferred
.
notifyWith
(
contexts
,
values
);
}
else
if
(
!
(
--
remaining
)
)
{
}
else
if
(
!
(
--
remaining
)
)
{
deferred
.
resolveWith
(
contexts
,
values
);
deferred
.
resolveWith
(
contexts
,
values
);
}
}
};
};
...
...
src/effects.js
View file @
22120cea
...
@@ -21,7 +21,7 @@ var
...
@@ -21,7 +21,7 @@ var
rrun
=
/queueHooks$/
,
rrun
=
/queueHooks$/
,
animationPrefilters
=
[
defaultPrefilter
],
animationPrefilters
=
[
defaultPrefilter
],
tweeners
=
{
tweeners
=
{
"*"
:
[
function
(
prop
,
value
)
{
"*"
:
[
function
(
prop
,
value
)
{
var
tween
=
this
.
createTween
(
prop
,
value
),
var
tween
=
this
.
createTween
(
prop
,
value
),
target
=
tween
.
cur
(),
target
=
tween
.
cur
(),
parts
=
rfxnum
.
exec
(
value
),
parts
=
rfxnum
.
exec
(
value
),
...
@@ -68,7 +68,7 @@ var
...
@@ -68,7 +68,7 @@ var
}
}
return
tween
;
return
tween
;
}]
}
]
};
};
// Animations created synchronously will run synchronously
// Animations created synchronously will run synchronously
...
@@ -87,8 +87,8 @@ function genFx( type, includeWidth ) {
...
@@ -87,8 +87,8 @@ function genFx( type, includeWidth ) {
// if we include width, step value is 1 to do all cssExpand values,
// if we include width, step value is 1 to do all cssExpand values,
// if we don't include width, step value is 2 to skip over Left and Right
// if we don't include width, step value is 2 to skip over Left and Right
includeWidth
=
includeWidth
?
1
:
0
;
includeWidth
=
includeWidth
?
1
:
0
;
for
(
;
i
<
4
;
i
+=
2
-
includeWidth
)
{
for
(
;
i
<
4
;
i
+=
2
-
includeWidth
)
{
which
=
cssExpand
[
i
];
which
=
cssExpand
[
i
];
attrs
[
"margin"
+
which
]
=
attrs
[
"padding"
+
which
]
=
type
;
attrs
[
"margin"
+
which
]
=
attrs
[
"padding"
+
which
]
=
type
;
}
}
...
@@ -100,7 +100,6 @@ function genFx( type, includeWidth ) {
...
@@ -100,7 +100,6 @@ function genFx( type, includeWidth ) {
return
attrs
;
return
attrs
;
}
}
function
createTween
(
value
,
prop
,
animation
)
{
function
createTween
(
value
,
prop
,
animation
)
{
var
tween
,
var
tween
,
collection
=
(
tweeners
[
prop
]
||
[]
).
concat
(
tweeners
[
"*"
]
),
collection
=
(
tweeners
[
prop
]
||
[]
).
concat
(
tweeners
[
"*"
]
),
...
@@ -189,7 +188,6 @@ function defaultPrefilter( elem, props, opts ) {
...
@@ -189,7 +188,6 @@ function defaultPrefilter( elem, props, opts ) {
}
}
}
}
// show/hide pass
// show/hide pass
for
(
prop
in
props
)
{
for
(
prop
in
props
)
{
value
=
props
[
prop
];
value
=
props
[
prop
];
...
...
src/effects/Tween.js
View file @
22120cea
...
@@ -102,7 +102,7 @@ jQuery.easing = {
...
@@ -102,7 +102,7 @@ jQuery.easing = {
return
p
;
return
p
;
},
},
swing
:
function
(
p
)
{
swing
:
function
(
p
)
{
return
0.5
-
Math
.
cos
(
p
*
Math
.
PI
)
/
2
;
return
0.5
-
Math
.
cos
(
p
*
Math
.
PI
)
/
2
;
}
}
};
};
...
...
src/effects/support.js
View file @
22120cea
...
@@ -3,7 +3,7 @@ define([
...
@@ -3,7 +3,7 @@ define([
"../var/support"
"../var/support"
],
function
(
strundefined
,
support
)
{
],
function
(
strundefined
,
support
)
{
(
function
()
{
(
function
()
{
var
a
,
shrinkWrapBlocksVal
,
var
a
,
shrinkWrapBlocksVal
,
div
=
document
.
createElement
(
"div"
),
div
=
document
.
createElement
(
"div"
),
divReset
=
divReset
=
...
@@ -32,7 +32,7 @@ define([
...
@@ -32,7 +32,7 @@ define([
// Null elements to avoid leaks in IE.
// Null elements to avoid leaks in IE.
a
=
div
=
null
;
a
=
div
=
null
;
support
.
shrinkWrapBlocks
=
function
()
{
support
.
shrinkWrapBlocks
=
function
()
{
var
body
,
container
,
div
,
containerStyles
;
var
body
,
container
,
div
,
containerStyles
;
if
(
shrinkWrapBlocksVal
==
null
)
{
if
(
shrinkWrapBlocksVal
==
null
)
{
...
...
src/event.js
View file @
22120cea
...
@@ -79,7 +79,7 @@ jQuery.event = {
...
@@ -79,7 +79,7 @@ jQuery.event = {
}
}
// Handle multiple events separated by a space
// Handle multiple events separated by a space
types
=
(
types
||
""
).
match
(
rnotwhite
)
||
[
""
];
types
=
(
types
||
""
).
match
(
rnotwhite
)
||
[
""
];
t
=
types
.
length
;
t
=
types
.
length
;
while
(
t
--
)
{
while
(
t
--
)
{
tmp
=
rtypenamespace
.
exec
(
types
[
t
]
)
||
[];
tmp
=
rtypenamespace
.
exec
(
types
[
t
]
)
||
[];
...
@@ -165,7 +165,7 @@ jQuery.event = {
...
@@ -165,7 +165,7 @@ jQuery.event = {
}
}
// Once for each type.namespace in types; type may be omitted
// Once for each type.namespace in types; type may be omitted
types
=
(
types
||
""
).
match
(
rnotwhite
)
||
[
""
];
types
=
(
types
||
""
).
match
(
rnotwhite
)
||
[
""
];
t
=
types
.
length
;
t
=
types
.
length
;
while
(
t
--
)
{
while
(
t
--
)
{
tmp
=
rtypenamespace
.
exec
(
types
[
t
]
)
||
[];
tmp
=
rtypenamespace
.
exec
(
types
[
t
]
)
||
[];
...
...
src/event/support.js
View file @
22120cea
...
@@ -2,7 +2,7 @@ define([
...
@@ -2,7 +2,7 @@ define([
"../var/support"
"../var/support"
],
function
(
support
)
{
],
function
(
support
)
{
(
function
()
{
(
function
()
{
var
i
,
eventName
,
var
i
,
eventName
,
div
=
document
.
createElement
(
"div"
);
div
=
document
.
createElement
(
"div"
);
...
...
src/manipulation.js
View file @
22120cea
...
@@ -311,7 +311,7 @@ jQuery.extend({
...
@@ -311,7 +311,7 @@ jQuery.extend({
tmp
=
tmp
||
safe
.
appendChild
(
context
.
createElement
(
"div"
)
);
tmp
=
tmp
||
safe
.
appendChild
(
context
.
createElement
(
"div"
)
);
// Deserialize a standard representation
// Deserialize a standard representation
tag
=
(
rtagName
.
exec
(
elem
)
||
[
""
,
""
]
)[
1
].
toLowerCase
();
tag
=
(
rtagName
.
exec
(
elem
)
||
[
""
,
""
])[
1
].
toLowerCase
();
wrap
=
wrapMap
[
tag
]
||
wrapMap
.
_default
;
wrap
=
wrapMap
[
tag
]
||
wrapMap
.
_default
;
tmp
.
innerHTML
=
wrap
[
1
]
+
elem
.
replace
(
rxhtmlTag
,
"<$1></$2>"
)
+
wrap
[
2
];
tmp
.
innerHTML
=
wrap
[
1
]
+
elem
.
replace
(
rxhtmlTag
,
"<$1></$2>"
)
+
wrap
[
2
];
...
@@ -556,7 +556,7 @@ jQuery.fn.extend({
...
@@ -556,7 +556,7 @@ jQuery.fn.extend({
dataAndEvents
=
dataAndEvents
==
null
?
false
:
dataAndEvents
;
dataAndEvents
=
dataAndEvents
==
null
?
false
:
dataAndEvents
;
deepDataAndEvents
=
deepDataAndEvents
==
null
?
dataAndEvents
:
deepDataAndEvents
;
deepDataAndEvents
=
deepDataAndEvents
==
null
?
dataAndEvents
:
deepDataAndEvents
;
return
this
.
map
(
function
()
{
return
this
.
map
(
function
()
{
return
jQuery
.
clone
(
this
,
dataAndEvents
,
deepDataAndEvents
);
return
jQuery
.
clone
(
this
,
dataAndEvents
,
deepDataAndEvents
);
});
});
},
},
...
@@ -577,7 +577,7 @@ jQuery.fn.extend({
...
@@ -577,7 +577,7 @@ jQuery.fn.extend({
if
(
typeof
value
===
"string"
&&
!
rnoInnerhtml
.
test
(
value
)
&&
if
(
typeof
value
===
"string"
&&
!
rnoInnerhtml
.
test
(
value
)
&&
(
support
.
htmlSerialize
||
!
rnoshimcache
.
test
(
value
)
)
&&
(
support
.
htmlSerialize
||
!
rnoshimcache
.
test
(
value
)
)
&&
(
support
.
leadingWhitespace
||
!
rleadingWhitespace
.
test
(
value
)
)
&&
(
support
.
leadingWhitespace
||
!
rleadingWhitespace
.
test
(
value
)
)
&&
!
wrapMap
[
(
rtagName
.
exec
(
value
)
||
[
""
,
""
]
)[
1
].
toLowerCase
()
]
)
{
!
wrapMap
[
(
rtagName
.
exec
(
value
)
||
[
""
,
""
])[
1
].
toLowerCase
()
]
)
{
value
=
value
.
replace
(
rxhtmlTag
,
"<$1></$2>"
);
value
=
value
.
replace
(
rxhtmlTag
,
"<$1></$2>"
);
...
...
src/manipulation/support.js
View file @
22120cea
...
@@ -2,7 +2,7 @@ define([
...
@@ -2,7 +2,7 @@ define([
"../var/support"
"../var/support"
],
function
(
support
)
{
],
function
(
support
)
{
(
function
()
{
(
function
()
{
var
fragment
=
document
.
createDocumentFragment
(),
var
fragment
=
document
.
createDocumentFragment
(),
div
=
document
.
createElement
(
"div"
),
div
=
document
.
createElement
(
"div"
),
input
=
document
.
createElement
(
"input"
);
input
=
document
.
createElement
(
"input"
);
...
...
src/offset.js
View file @
22120cea
...
@@ -44,7 +44,7 @@ jQuery.offset = {
...
@@ -44,7 +44,7 @@ jQuery.offset = {
curCSSTop
=
jQuery
.
css
(
elem
,
"top"
);
curCSSTop
=
jQuery
.
css
(
elem
,
"top"
);
curCSSLeft
=
jQuery
.
css
(
elem
,
"left"
);
curCSSLeft
=
jQuery
.
css
(
elem
,
"left"
);
calculatePosition
=
(
position
===
"absolute"
||
position
===
"fixed"
)
&&
calculatePosition
=
(
position
===
"absolute"
||
position
===
"fixed"
)
&&
jQuery
.
inArray
(
"auto"
,
[
curCSSTop
,
curCSSLeft
]
)
>
-
1
;
jQuery
.
inArray
(
"auto"
,
[
curCSSTop
,
curCSSLeft
]
)
>
-
1
;
// need to be able to calculate position if either top or left is auto and position is either absolute or fixed
// need to be able to calculate position if either top or left is auto and position is either absolute or fixed
if
(
calculatePosition
)
{
if
(
calculatePosition
)
{
...
@@ -163,7 +163,7 @@ jQuery.fn.extend({
...
@@ -163,7 +163,7 @@ jQuery.fn.extend({
});
});
// Create scrollLeft and scrollTop methods
// Create scrollLeft and scrollTop methods
jQuery
.
each
(
{
scrollLeft
:
"pageXOffset"
,
scrollTop
:
"pageYOffset"
},
function
(
method
,
prop
)
{
jQuery
.
each
(
{
scrollLeft
:
"pageXOffset"
,
scrollTop
:
"pageYOffset"
},
function
(
method
,
prop
)
{
var
top
=
/Y/
.
test
(
prop
);
var
top
=
/Y/
.
test
(
prop
);
jQuery
.
fn
[
method
]
=
function
(
val
)
{
jQuery
.
fn
[
method
]
=
function
(
val
)
{
...
@@ -195,7 +195,7 @@ jQuery.each( {scrollLeft: "pageXOffset", scrollTop: "pageYOffset"}, function( me
...
@@ -195,7 +195,7 @@ jQuery.each( {scrollLeft: "pageXOffset", scrollTop: "pageYOffset"}, function( me
// rather than make the css module depend on the offset module, we just check for it here
// rather than make the css module depend on the offset module, we just check for it here
jQuery
.
each
(
[
"top"
,
"left"
],
function
(
i
,
prop
)
{
jQuery
.
each
(
[
"top"
,
"left"
],
function
(
i
,
prop
)
{
jQuery
.
cssHooks
[
prop
]
=
addGetHookIf
(
support
.
pixelPosition
,
jQuery
.
cssHooks
[
prop
]
=
addGetHookIf
(
support
.
pixelPosition
,
function
(
elem
,
computed
)
{
function
(
elem
,
computed
)
{
if
(
computed
)
{
if
(
computed
)
{
computed
=
curCSS
(
elem
,
prop
);
computed
=
curCSS
(
elem
,
prop
);
// if curCSS returns percentage, fallback to offset
// if curCSS returns percentage, fallback to offset
...
...
src/queue.js
View file @
22120cea
...
@@ -126,7 +126,7 @@ jQuery.fn.extend({
...
@@ -126,7 +126,7 @@ jQuery.fn.extend({
}
}
type
=
type
||
"fx"
;
type
=
type
||
"fx"
;
while
(
i
--
)
{
while
(
i
--
)
{
tmp
=
jQuery
.
_data
(
elements
[
i
],
type
+
"queueHooks"
);
tmp
=
jQuery
.
_data
(
elements
[
i
],
type
+
"queueHooks"
);
if
(
tmp
&&
tmp
.
empty
)
{
if
(
tmp
&&
tmp
.
empty
)
{
count
++
;
count
++
;
...
...
src/selector-sizzle.js
View file @
22120cea
define
([
define
([
"./core"
,
"./core"
,
"sizzle"
"sizzle"
],
function
(
jQuery
,
Sizzle
)
{
],
function
(
jQuery
,
Sizzle
)
{
jQuery
.
find
=
Sizzle
;
jQuery
.
find
=
Sizzle
;
jQuery
.
expr
=
Sizzle
.
selectors
;
jQuery
.
expr
=
Sizzle
.
selectors
;
...
...
src/serialize.js
View file @
22120cea
...
@@ -80,25 +80,25 @@ jQuery.fn.extend({
...
@@ -80,25 +80,25 @@ jQuery.fn.extend({
return
jQuery
.
param
(
this
.
serializeArray
()
);
return
jQuery
.
param
(
this
.
serializeArray
()
);
},
},
serializeArray
:
function
()
{
serializeArray
:
function
()
{
return
this
.
map
(
function
(){
return
this
.
map
(
function
()
{
// Can add propHook for "elements" to filter or add form elements
// Can add propHook for "elements" to filter or add form elements
var
elements
=
jQuery
.
prop
(
this
,
"elements"
);
var
elements
=
jQuery
.
prop
(
this
,
"elements"
);
return
elements
?
jQuery
.
makeArray
(
elements
)
:
this
;
return
elements
?
jQuery
.
makeArray
(
elements
)
:
this
;
})
})
.
filter
(
function
(){
.
filter
(
function
()
{
var
type
=
this
.
type
;
var
type
=
this
.
type
;
// Use .is(":disabled") so that fieldset[disabled] works
// Use .is(":disabled") so that fieldset[disabled] works
return
this
.
name
&&
!
jQuery
(
this
).
is
(
":disabled"
)
&&
return
this
.
name
&&
!
jQuery
(
this
).
is
(
":disabled"
)
&&
rsubmittable
.
test
(
this
.
nodeName
)
&&
!
rsubmitterTypes
.
test
(
type
)
&&
rsubmittable
.
test
(
this
.
nodeName
)
&&
!
rsubmitterTypes
.
test
(
type
)
&&
(
this
.
checked
||
!
rcheckableType
.
test
(
type
)
);
(
this
.
checked
||
!
rcheckableType
.
test
(
type
)
);
})
})
.
map
(
function
(
i
,
elem
){
.
map
(
function
(
i
,
elem
)
{
var
val
=
jQuery
(
this
).
val
();
var
val
=
jQuery
(
this
).
val
();
return
val
==
null
?
return
val
==
null
?
null
:
null
:
jQuery
.
isArray
(
val
)
?
jQuery
.
isArray
(
val
)
?
jQuery
.
map
(
val
,
function
(
val
){
jQuery
.
map
(
val
,
function
(
val
)
{
return
{
name
:
elem
.
name
,
value
:
val
.
replace
(
rCRLF
,
"
\
r
\n
"
)
};
return
{
name
:
elem
.
name
,
value
:
val
.
replace
(
rCRLF
,
"
\
r
\n
"
)
};
})
:
})
:
{
name
:
elem
.
name
,
value
:
val
.
replace
(
rCRLF
,
"
\
r
\n
"
)
};
{
name
:
elem
.
name
,
value
:
val
.
replace
(
rCRLF
,
"
\
r
\n
"
)
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment