Bug 182988

Summary: VTTCue constructor should use 'double' type for startTime / endTime
Product: WebKit Reporter: Chris Dumez <cdumez>
Component: MediaAssignee: Chris Dumez <cdumez>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, eric.carlson, jer.noble, mark.lam, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=182984
Attachments:
Description Flags
Patch
none
Patch none

Description Chris Dumez 2018-02-20 16:12:59 PST
VTTCue constructor should use 'double' type for startTime / endTime, not 'unrestricted double':
- https://w3c.github.io/webvtt/#the-vttcue-interface

Otherwise, we end up potentially returning NaN for TextTrackCue.startTime / endTime, even though those correctly use type 'double':
- https://html.spec.whatwg.org/multipage/media.html#texttrackcue
Comment 1 Chris Dumez 2018-02-20 16:13:54 PST
I have verified that this new behavior would be consistent with Chrome.
Comment 2 Chris Dumez 2018-02-20 16:16:04 PST
(In reply to Chris Dumez from comment #1)
> I have verified that this new behavior would be consistent with Chrome.

Would also be consistent with Firefox.
Comment 3 Chris Dumez 2018-02-20 16:30:33 PST
Created attachment 334316 [details]
Patch
Comment 4 Chris Dumez 2018-02-20 16:38:11 PST
Created attachment 334317 [details]
Patch
Comment 5 WebKit Commit Bot 2018-02-21 11:36:53 PST
Comment on attachment 334317 [details]
Patch

Clearing flags on attachment: 334317

Committed r228886: <https://trac.webkit.org/changeset/228886>
Comment 6 WebKit Commit Bot 2018-02-21 11:36:54 PST
All reviewed patches have been landed.  Closing bug.
Comment 7 Radar WebKit Bug Importer 2018-02-21 11:37:28 PST
<rdar://problem/37754585>