Skip to content

Conversation

@stephenmcgruer
Copy link
Contributor

…'double'

As per the web-idl spec, float should only be used if there is a
specific reason, as double much more closely matches the ECMAScript
Number type. In the case of TransitionEvent there does not appear to be
such a reason.

Furthermore, switching to double allows the elapsedTime to reach higher
values without overflowing. A rough calculation (with some assumptions
and possible errors) suggests that this change will raise the celing
from ~4.5 hours to years.

…'double'

As per the web-idl spec, float should only be used if there is a
specific reason, as double much more closely matches the ECMAScript
Number type. In the case of TransitionEvent there does not appear to be
such a reason.

Furthermore, switching to double allows the elapsedTime to reach higher
values without overflowing. A rough calculation (with some assumptions
and possible errors) suggests that this change will raise the celing
from ~4.5 hours to years.
@stephenmcgruer
Copy link
Contributor Author

@birtles

@birtles
Copy link
Contributor

birtles commented May 13, 2018

Thanks!

aarongable pushed a commit to chromium/chromium that referenced this pull request May 14, 2018
w3c/csswg-drafts#2666 and
w3c/csswg-drafts#2671 updated the spec so that
elapsedTime as a member of AnimationEvent and TransitionEvent is
specified as a double instead of a float. Remove the TODOs as our
implementation is now correct.

Change-Id: I1c7abf14765fdbd46e37b4f8c506fed574cecdd0
Reviewed-on: https://chromium-review.googlesource.com/1056787
Reviewed-by: Philip Jägenstedt <foolip@chromium.org>
Commit-Queue: Chris Nardi <cnardi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#558285}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants