Collapse MIDIMessage into MIDIEvent, as per https://www.w3.org/Bugs/Public/show_bug.cgi?id=19975.
authorChris Wilson <cwilso@gmail.com>
Wed, 05 Dec 2012 11:28:42 -0800
changeset 237 c19d385a839f
parent 236 cf921b9c41ce
child 238 f572fe073d58
Collapse MIDIMessage into MIDIEvent, as per https://www.w3.org/Bugs/Public/show_bug.cgi?id=19975.
midi/specification.html
--- a/midi/specification.html	Tue Dec 04 15:59:30 2012 -0800
+++ b/midi/specification.html	Wed Dec 05 11:28:42 2012 -0800
@@ -95,9 +95,7 @@
           </li>
           <li>A <a href="#MIDIOutput">MIDIOutput</a> interface, which implements MIDIPort and additionally exposes methods to send MIDI messages to the output port.
           </li>
-          <li>A <a href="#MIDIMessage">MIDIMessage</a> interface, which represents a sequence of MIDI data bytes along with a timestamp.  This interface is used for receiving MIDI messages.
-          </li>
-          <li>A <a href="#MIDIEvent">MIDIEvent</a> interface, which represents the Event object passed to MIDIInput's onmessage handler and contains an array of MIDIMessages.
+          <li>A <a href="#MIDIEvent">MIDIEvent</a> interface, which represents the Event object passed to a MIDIInput's onmessage handler and contains a sequence of MIDI data bytes along with a timestamp.
           </li>
         </ul>
       </section>
@@ -578,17 +576,11 @@
 
           <li>
             <p>
-              Let <code>messages</code> be a newly constructed
-              <code>sequence&lt;<a>MIDIMessage</a>&gt;</code> corresponding the
-              MIDI messages the port sent.
-            </p>
-          </li>
-
-          <li>
-            <p>
               Let <code>event</code> be a newly constructed
-              <code><a>MIDIEvent</a></code>, with the <code>MIDIMessages</code>
-              attribute set to <code>messages</code>.
+              <code><a>MIDIEvent</a></code>, with the <code>timestamp</code>
+              attribute set to the time the message was received by the system, and
+              with the <code>data</code> attribute set to a UInt8Array of MIDI data
+              bytes representing a single MIDI message.
             </p>
           </li>
 
@@ -596,7 +588,7 @@
             <p>
               Fire an event named <code><a
               href="#event-midiinput-message">message</a></code>
-              at the object, using the <code>event</code> as the event object.
+              at the <code>port</code>, using the <code>event</code> as the event object.
             </p>
           </li>
         </ol>
@@ -635,39 +627,20 @@
     </section>
 
     <section>
-      <h2 id="MIDIMessage"><a>MIDIMessage</a> Interface</h2>
+      <h2 id="MIDIEvent"><a>MIDIEvent</a> Interface</h2>
+      <p>An event object implementing this interface is passed to a MIDIInput's onmessage handler when MIDI messages are received.</p>
       <dl title="[NoInterfaceObject]
-                 interface MIDIMessage"
+                 interface MIDIEvent : Event"
           class="idl">
         <dt>readonly attribute DOMHighResTimeStamp timestamp</dt>
         <dd>
-          <p>
-            A <code>DOMHighResTimeStamp</code> specifying when the event occurred.
-          </p>
+          <p>A <code>DOMHighResTimeStamp</code> specifying when the event occurred.</p>
         </dd>
         <dt>readonly attribute Uint8Array data</dt>
         <dd>
-          <p>
-            A Uint8Array containing the MIDI data bytes of a single MIDI message.
-          </p>
+          <p>A Uint8Array containing the MIDI data bytes of a single MIDI message.</p>
         </dd>
       </dl>
-
-      <section>
-        <h2 id="MIDIEvent"><a>MIDIEvent</a> Interface</h2>
-        
-        <dl title="[NoInterfaceObject]
-                   interface MIDIEvent : Event"
-            class="idl">
-          <dt>readonly attribute <a>MIDIMessage</a>[] MIDIMessages</dt>
-          <dd>
-            <p>
-              An array of <code><a>MIDIMessage</a></code>s associated
-              with the event.
-            </p>
-          </dd>
-        </dl>
-      </section>
     </section>
   </body>
 </html>