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
75a4bc4a
Commit
75a4bc4a
authored
Apr 07, 2011
by
jaubourg
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Makes sure each animation tick has the same timestamp for all animations in the batch.
parent
b7dd8404
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
3 deletions
+14
-3
effects.js
src/effects.js
+14
-3
No files found.
src/effects.js
View file @
75a4bc4a
...
@@ -11,7 +11,17 @@ var elemdisplay = {},
...
@@ -11,7 +11,17 @@ var elemdisplay = {},
[
"width"
,
"marginLeft"
,
"marginRight"
,
"paddingLeft"
,
"paddingRight"
],
[
"width"
,
"marginLeft"
,
"marginRight"
,
"paddingLeft"
,
"paddingRight"
],
// opacity animations
// opacity animations
[
"opacity"
]
[
"opacity"
]
];
],
fxNow
;
function
clearFxNow
()
{
fxNow
=
undefined
;
}
function
createFxNow
()
{
setTimeout
(
clearFxNow
,
0
);
return
(
fxNow
=
jQuery
.
now
()
);
}
jQuery
.
fn
.
extend
({
jQuery
.
fn
.
extend
({
show
:
function
(
speed
,
easing
,
callback
)
{
show
:
function
(
speed
,
easing
,
callback
)
{
...
@@ -349,7 +359,7 @@ jQuery.fx.prototype = {
...
@@ -349,7 +359,7 @@ jQuery.fx.prototype = {
var
self
=
this
,
var
self
=
this
,
fx
=
jQuery
.
fx
;
fx
=
jQuery
.
fx
;
this
.
startTime
=
jQuery
.
n
ow
();
this
.
startTime
=
fxNow
||
createFxN
ow
();
this
.
start
=
from
;
this
.
start
=
from
;
this
.
end
=
to
;
this
.
end
=
to
;
this
.
unit
=
unit
||
this
.
unit
||
(
jQuery
.
cssNumber
[
this
.
prop
]
?
""
:
"px"
);
this
.
unit
=
unit
||
this
.
unit
||
(
jQuery
.
cssNumber
[
this
.
prop
]
?
""
:
"px"
);
...
@@ -394,7 +404,8 @@ jQuery.fx.prototype = {
...
@@ -394,7 +404,8 @@ jQuery.fx.prototype = {
// Each step of an animation
// Each step of an animation
step
:
function
(
gotoEnd
)
{
step
:
function
(
gotoEnd
)
{
var
t
=
jQuery
.
now
(),
done
=
true
;
var
t
=
fxNow
||
createFxNow
(),
done
=
true
;
if
(
gotoEnd
||
t
>=
this
.
options
.
duration
+
this
.
startTime
)
{
if
(
gotoEnd
||
t
>=
this
.
options
.
duration
+
this
.
startTime
)
{
this
.
now
=
this
.
end
;
this
.
now
=
this
.
end
;
...
...
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