This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 20511 - send(…, DOMHighResTimeStamp? timestamp)
Summary: send(…, DOMHighResTimeStamp? timestamp)
Status: CLOSED FIXED
Alias: None
Product: AudioWG
Classification: Unclassified
Component: MIDI API (show other bugs)
Version: unspecified
Hardware: PC All
: P2 normal
Target Milestone: TBD
Assignee: Chris Wilson
QA Contact: public-audio
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-12-24 08:26 UTC by Marcos Caceres
Modified: 2013-01-18 15:50 UTC (History)
2 users (show)

See Also:


Attachments

Description Marcos Caceres 2012-12-24 08:26:09 UTC
For send()'s second argument, the spec says that it takes DOMHighResTimeStamp… however, "DOMHighResTimeStamp" isn't a "real data type" (in that there is no way to actually force a type check on it in some meaningful way AFAICT). Hence, it's actually just a double that is relative to some start time. This is confirmed in [1]:

typedef double DOMHighResTimeStamp;

To avoid confusion during implementation, I would suggest changing the value data type of the second argument of the send() method to a double.

optional double timestamp;

Also, why is the second argument nullable when it's already optional?

Note that the current text in the spec is redundant because WebIDL already handles the type checking. Please remove " or if timestamp is passed but is not a valid DOMHighResTimeStamp, throw a TYPE_ERROR exception".


[1] http://www.w3.org/TR/2012/REC-hr-time-20121217/#domhighrestimestamp
Comment 1 Chris Wilson 2012-12-26 18:10:16 UTC
Resolved with https://github.com/WebAudio/web-midi-api/commit/23d1a3f64c003ff49077f1a7c6477f109f1d53b9.

Use "double" for all references to DOMHighResTimeStamp parameters.
Comment 2 Olivier Thereaux 2013-01-18 15:50:56 UTC
Batch-closing RESOLVED MIDI issues. Reminder: midi issues now tracked at https://github.com/WebAudio/web-midi-api/issues