Closed
Bug 1297000
Opened 10 years ago
Closed 10 years ago
Modify comparison of zero TimeDuration in animation.
Categories
(Core :: DOM: Animation, defect)
Core
DOM: Animation
Tracking
()
RESOLVED
FIXED
mozilla51
| Tracking | Status | |
|---|---|---|
| firefox51 | --- | fixed |
People
(Reporter: mantaroh, Assigned: yusuke20023)
Details
(Whiteboard: [good first bug])
Attachments
(1 file, 1 obsolete file)
|
1.76 KB,
patch
|
birtles
:
review+
|
Details | Diff | Splinter Review |
Currently, We use the TimeDuration::ToMilliseconds() in animation's implementation. [1]
However we can specify zero to TimeDuration's constructor.[2][3]
So we should replace comparison of zero TimeDuraion in animation's implementation.
e.g:
foo.ToMilliseconds() < 0.0 to foo < TimeDuration(0)
[1] https://dxr.mozilla.org/mozilla-central/search?q=ToMilliseconds+path%3Adom%2Fanimation%2FAnimation.cpp&redirect=true
[2] https://dxr.mozilla.org/mozilla-central/rev/f97a056ae6235de7855fd8aaa04fb1c8d183bd06/mozglue/misc/TimeStamp.h#69
[3] https://dxr.mozilla.org/mozilla-central/source/dom/animation/Animation.cpp#386
| Reporter | ||
Updated•10 years ago
|
Summary: Modify comparison of zero TimeDuration. → Modify comparison of zero TimeDuration in animation.
Comment 1•10 years ago
|
||
We have a constexpr variable.
http://hg.mozilla.org/mozilla-central/file/01748a2b1a46/mozglue/misc/TimeStamp.h#l65
We should use it.
Updated•10 years ago
|
Assignee: nobody → yusuke20023
Attachment #8785539 -
Flags: review?(bbirtles)
Attachment #8785539 -
Attachment is obsolete: true
Attachment #8785539 -
Flags: review?(bbirtles)
Attachment #8785541 -
Flags: review?(bbirtles)
Comment 4•10 years ago
|
||
Comment on attachment 8785541 [details] [diff] [review]
bug1297000.patch
Review of attachment 8785541 [details] [diff] [review]:
-----------------------------------------------------------------
Looks good. Thanks!
Attachment #8785541 -
Flags: review?(bbirtles) → review+
Comment 5•10 years ago
|
||
Pushed by bbirtles@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/1e2503f29f53
Modify comparison of zero TimeDuration to use TimeDuration object rather than converting to milliseconds; r=birtles
Comment 7•10 years ago
|
||
| bugherder | ||
Status: NEW → RESOLVED
Closed: 10 years ago
status-firefox51:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla51
You need to log in
before you can comment on or make changes to this bug.
Description
•