Skip to content

Commit

Permalink
Use of "stopped" in insertDTMF and replaceTrack
Browse files Browse the repository at this point in the history
Fix for Issue #917
  • Loading branch information
aboba committed Nov 11, 2016
1 parent ffbec2f commit a05dff5
Showing 1 changed file with 31 additions and 23 deletions.
54 changes: 31 additions & 23 deletions webrtc.html
Original file line number Diff line number Diff line change
Expand Up @@ -2184,14 +2184,12 @@ <h2>Methods</h2>
<code><var>receiver.rtcpTransport.transport.state</var></code>
to "closed".</p>
</li>
<li>
<p>All <code><a>RTCRtpSender</a></code>s in
<var>senders</var> are now considered <a>stopped</a>.</p>
</li>
<li>
<p>All <code><a>RTCRtpReceiver</a></code>s in
<var>receivers</var> are now considered <a>stopped</a>.</p>
</li>
<p>Let <var>transceivers</var> be the result of executing the
<code><a>CollectTransceivers</a></code> algorithm. For every
<code><a>RTCRtpTransceiver</a></code> <var>transceiver</var> in
<var>transceivers</var>, set
<code><var>transceiver</var>.stopped</code> to
<code>true</code>.</p>
<li>
<p>Set <var>connection</var>'s [[<a>isClosed</a>]] slot to
<code>true</code>.</p>
Expand Down Expand Up @@ -4974,9 +4972,6 @@ <h3>RTCRtpSender Interface</h3>
encoded and transmitted to a remote peer. When <code>setParameters</code>
is called on an <code><a>RTCRtpSender</a></code> object, the encoding is
changed appropriately.</p>
<p>An <code><a>RTCRtpSender</a></code> can be <dfn id=
"sender-stopped">stopped</dfn>, which indicates that it will no longer
send any media.</p>
<p>To <dfn>create an RTCRtpSender</dfn> with a
<code><a>MediaStreamTrack</a></code>, <var>track</var>, a list of
<code><a>MediaStream</a></code> objects, <var>streams</var>, and
Expand Down Expand Up @@ -5220,24 +5215,25 @@ <h2>Methods</h2>
<li>Let <var>sender</var> be the
<code><a>RTCRtpSender</a></code> object on which
<code>replaceTrack</code> is invoked.</li>
<li>
<p>Let <var>transceiver</var> be the
<code><a>RTCRtpTransceiver</a></code> object associated with
<var>sender</var>.</p>
</li>
<li>
<p>Let <var>connection</var> be the
<code><a>RTCPeerConnection</a></code> object that created
<var>sender</var>.</p>
</li>
<li>
<p>If <var>sender</var> is <a>stopped</a>, return a promise
rejected with an <code>InvalidStateError</code>.</p>
<p>If <code><var>transceiver</var>.stopped</code> is
<code>true</code>, return a promise rejected
with an <code>InvalidStateError</code>.</p>
</li>
<li>
<p>Let <var>withTrack</var> be the argument to this
method.</p>
</li>
<li>
<p>Let <var>transceiver</var> be the
<code><a>RTCRtpTransceiver</a></code> object associated with
<var>sender</var>.</p>
</li>
<li>
<p>If <code><var>withTrack</var>.kind</code> differs from the
<a>transceiver kind</a> of <var>transceiver</var>, return a
Expand Down Expand Up @@ -6145,7 +6141,7 @@ <h2>Attributes</h2>
of this transceiver will no longer send, and that the receiver
will no longer receive. It is true if either <code>stop</code>
has been called or if setting the local or remote description has
caused the <a><code>RTCRtpReceiver</code></a> to be stopped.</p>
caused the <a><code>RTCTransceiver</code></a> to be stopped.</p>
</dd>
<dt><dfn><code>direction</code></dfn> of type <span class=
"idlAttrType"><a>RTCRtpTransceiverDirection</a></span>,
Expand Down Expand Up @@ -8147,8 +8143,17 @@ <h2>Methods</h2>
<ol>
<li>let <var>sender</var> be the
<code><a>RTCRtpSender</a></code> used to send DTMF.</li>
<li>If <var>sender</var> has been stopped, throw an
<code>InvalidStateError</code> exception.</li>
<li>
<p>Let <var>transceiver</var> be the
<code><a>RTCRtpTransceiver</a></code> object associated with
<var>sender</var>.</p>
</li>
<li>If <code><var>transceiver</var>.stopped</code> is
<code>true</code>, throw an <code>InvalidStateError</code>
exception.</li>
<li>If <code><var>transceiver</var>.currentDirection</code>
is <code>recvonly</code> or <code>inactive</code>,
throw an <code>InvalidStateError</code> exception.</li>
<li>Let <var>tones</var> be the method's first argument.</li>
<li>If <var>tones</var> contains any <a>unrecognized</a>
characters, throw an <code>InvalidCharacterError</code>
Expand All @@ -8170,8 +8175,11 @@ <h2>Methods</h2>
these steps; otherwise queue a task that runs the following
steps (<em>Playout task</em>):
<ol>
<li>If <var>sender</var> has been stopped, abort these
steps.</li>
<li>If <code><var>transceiver</var>.stopped</code> is
<code>true</code>, abort these steps.</li>
<li>If <code><var>transceiver</var>.currentDirection</code>
is <code>recvonly</code> or <code>inactive</code>,
abort these steps.</li>
<li>If <code><a data-for=
"RTCDTMFSender">toneBuffer</a></code> is an empty string,
fire an event named <code><a>tonechange</a></code> with an
Expand Down

0 comments on commit a05dff5

Please sign in to comment.