Specify the ended event for AudioBufferSourceNode and OscillatorNode
authorEhsan Akhgari <ehsan@mozilla.com>
Sat, 04 May 2013 16:16:39 -0400
changeset 309 c4b01f068f97
parent 308 101ebe21a8f4
child 310 ba6f07a395c5
Specify the ended event for AudioBufferSourceNode and OscillatorNode
webaudio/specification.html
--- a/webaudio/specification.html	Wed May 01 22:21:44 2013 -0400
+++ b/webaudio/specification.html	Sat May 04 16:16:39 2013 -0400
@@ -2228,6 +2228,8 @@
     void start(optional double when = 0, optional double offset = 0, optional double duration);
     void stop(optional double when = 0);
 
+    attribute EventHandler onended;
+
 };
 </code></pre>
 </div>
@@ -2264,6 +2266,18 @@
     Its default value is 0, and it may usefully be set to any value between 0 and the duration of the buffer.</p>
     </dd>
 </dl>
+<dl>
+  <dt id="dfn-onended_AudioBufferSourceNode"><code>onended</code></dt>
+    <dd><p>A property used to set the <code>EventHandler</code> (described in <cite><a
+      href="http://www.whatwg.org/specs/web-apps/current-work/#eventhandler">HTML</a></cite>)
+      for the ended event that is dispatched to <a
+      href="#AudioBufferSourceNode-section"><code>AudioBufferSourceNode</code></a>
+      node types.  When the playback of the buffer for an <code>AudioBufferSourceNode</code>
+      is finished, an event of type <code>Event</code> (described in <cite><a
+      href="http://www.whatwg.org/specs/web-apps/current-work/#event">HTML</a></cite>)
+      will be dispatched to the event handler. </p>
+    </dd>
+</dl>
 
 
 </div>
@@ -3700,6 +3714,8 @@
     void stop(double when);
     void setWaveTable(WaveTable waveTable);
 
+    attribute EventHandler onended;
+
 };
 </code></pre>
 </div>
@@ -3726,6 +3742,18 @@
      This parameter is <em>a-rate</em> </p>
     </dd>
 </dl>
+<dl>
+  <dt id="dfn-onended"><code>onended</code></dt>
+    <dd><p>A property used to set the <code>EventHandler</code> (described in <cite><a
+      href="http://www.whatwg.org/specs/web-apps/current-work/#eventhandler">HTML</a></cite>)
+      for the ended event that is dispatched to <a
+      href="#OscillatorNode-section"><code>OscillatorNode</code></a>
+      node types.  When the playback of the buffer for an <code>OscillatorNode</code>
+      is finished, an event of type <code>Event</code> (described in <cite><a
+      href="http://www.whatwg.org/specs/web-apps/current-work/#event">HTML</a></cite>)
+      will be dispatched to the event handler. </p>
+    </dd>
+</dl>
 </div>
 </div>