Skip to content

Commit

Permalink
* refer to the 'set of presentations' in 'Joining a presentation sess…
Browse files Browse the repository at this point in the history
…ion'

  and simplify the algorithm prose

* refer to the URL concept in the 'presentation session URL'
  • Loading branch information
anssiko committed Jun 9, 2015
1 parent 52c5bca commit cda94c8
Show file tree
Hide file tree
Showing 2 changed files with 62 additions and 60 deletions.
63 changes: 32 additions & 31 deletions Overview.src.html
Expand Up @@ -542,8 +542,9 @@ <h3>
Each <span>presentation session</span> has a <dfn>presentation
session state</dfn>, a <dfn>presentation session identifier</dfn> to
distinguish it from other <span>presentation sessions</span>, and a
<dfn>presentation session URL</dfn> that is a URL used to create or
resume the <span>presentation session</span>.
<dfn>presentation session URL</dfn> that is a <span data-anolis-spec=
"url">URL</span> used to create or resume the <span>presentation
session</span>.
</p>
<p>
A <dfn>controlling browsing context</dfn> (or <em>controller</em> for
Expand Down Expand Up @@ -1160,11 +1161,12 @@ <h4>
Input
</dt>
<dd>
<code>presentationUrl</code>, the <span data-anolis-spec=
"url">URL</span> of the document being presented
<code>presentationUrl</code>, the <span>presentation session
URL</span>
</dd>
<dd>
<code>presentationId</code>, the identifier for the presentation
<code>presentationId</code>, the <span>presentation session
identifier</span>
</dd>
<dt>
Output
Expand All @@ -1180,36 +1182,35 @@ <h4>
</li>
<li>Return <em>P</em>.
</li>
<li>Let <em>D</em> be the <span>set of presentations</span> for the
user agent.
</li>
<li>
<span data-anolis-spec="w3c-html">Queue a task</span> <em>T</em>
to run the following steps in order:
<ol>
<li>For each presentation <em>(U, I, S)</em> in <em>D</em>,
<ol>
<li>Let <em>u</em> equal <em>U</em>, <em>i</em> equal <em>
I</em>, and <em>s</em> equal <em>S</em>.
</li>
<li>If <em>u</em> is equal to <code>presentationUrl</code>
and <em>i</em> is equal to <code>presentationId</code>, run
the following steps:
<ol>
<li>
<span data-anolis-spec="promguide" title=
"resolve-reject">Resolve</span> <em>P</em> with
<em>S</em>.
</li>
<li>
<span>Establish a presentation connection</span> with
<em>S</em>.
</li>
<li>Abort the remaining steps of <em>T</em>.
</li>
</ol>
</li>
</ol>
<li>For each <var>known session</var> in the <span>set of
presentations</span>,
<div style="margin-left: 2em">
If the <span>presentation session URL</span> of <var>known
session</var> is equal to <code>presentationUrl</code>, and
the <span>presentation session identifier</span> of
<var>known session</var> is equal to
<code>presentationId</code>, run the following steps:
<ol>
<li>Let <var>S</var> be the <span>presentation
session</span> of <var>known session</var>.
</li>
<li>
<span data-anolis-spec="promguide" title=
"resolve-reject">Resolve</span> <var>P</var> with
<var>S</var>.
</li>
<li>
<span>Establish a presentation connection</span> with
<var>S</var>.
</li>
<li>Abort the remaining steps of <var>T</var>.
</li>
</ol>
</div>
</li>
<li>
<span data-anolis-spec="promguide" title=
Expand Down
59 changes: 30 additions & 29 deletions index.html
Expand Up @@ -617,8 +617,8 @@ <h3 id="common-idioms"><span class="secno">6.1 </span>
Each <a href="#presentation-session">presentation session</a> has a <dfn id="presentation-session-state">presentation
session state</dfn>, a <dfn id="presentation-session-identifier">presentation session identifier</dfn> to
distinguish it from other <span>presentation sessions</span>, and a
<dfn id="presentation-session-url">presentation session URL</dfn> that is a URL used to create or
resume the <a href="#presentation-session">presentation session</a>.
<dfn id="presentation-session-url">presentation session URL</dfn> that is a <a class="external" data-anolis-spec="url" href="https://url.spec.whatwg.org/#url">URL</a> used to create or resume the <a href="#presentation-session">presentation
session</a>.
</p>
<p>
A <dfn id="controlling-browsing-context">controlling browsing context</dfn> (or <em>controller</em> for
Expand Down Expand Up @@ -1202,10 +1202,12 @@ <h4 id="joining-a-presentation-session"><span class="secno">6.4.2 </span>
Input
</dt>
<dd>
<code>presentationUrl</code>, the <a class="external" data-anolis-spec="url" href="https://url.spec.whatwg.org/#url">URL</a> of the document being presented
<code>presentationUrl</code>, the <a href="#presentation-session-url">presentation session
URL</a>
</dd>
<dd>
<code>presentationId</code>, the identifier for the presentation
<code>presentationId</code>, the <a href="#presentation-session-identifier">presentation session
identifier</a>
</dd>
<dt>
Output
Expand All @@ -1219,35 +1221,34 @@ <h4 id="joining-a-presentation-session"><span class="secno">6.4.2 </span>
</li>
<li>Return <em>P</em>.
</li>
<li>Let <em>D</em> be the <a href="#set-of-presentations">set of presentations</a> for the
user agent.
</li>
<li>
<a class="external" data-anolis-spec="w3c-html" href="http://www.w3.org/html/wg/drafts/html/master/webappapis.html#queue-a-task">Queue a task</a> <em>T</em>
to run the following steps in order:
<ol>
<li>For each presentation <em>(U, I, S)</em> in <em>D</em>,
<ol>
<li>Let <em>u</em> equal <em>U</em>, <em>i</em> equal <em>
I</em>, and <em>s</em> equal <em>S</em>.
</li>
<li>If <em>u</em> is equal to <code>presentationUrl</code>
and <em>i</em> is equal to <code>presentationId</code>, run
the following steps:
<ol>
<li>
<a class="external" data-anolis-spec="promguide" href="http://www.w3.org/2001/tag/doc/promises-guide#shorthand-manipulating" title="resolve-reject">Resolve</a> <em>P</em> with
<em>S</em>.
</li>
<li>
<a href="#establish-a-presentation-connection">Establish a presentation connection</a> with
<em>S</em>.
</li>
<li>Abort the remaining steps of <em>T</em>.
</li>
</ol>
</li>
</ol>
<li>For each <var>known session</var> in the <a href="#set-of-presentations">set of
presentations</a>,
<div style="margin-left: 2em">
If the <a href="#presentation-session-url">presentation session URL</a> of <var>known
session</var> is equal to <code>presentationUrl</code>, and
the <a href="#presentation-session-identifier">presentation session identifier</a> of
<var>known session</var> is equal to
<code>presentationId</code>, run the following steps:
<ol>
<li>Let <var>S</var> be the <a href="#presentation-session">presentation
session</a> of <var>known session</var>.
</li>
<li>
<a class="external" data-anolis-spec="promguide" href="http://www.w3.org/2001/tag/doc/promises-guide#shorthand-manipulating" title="resolve-reject">Resolve</a> <var>P</var> with
<var>S</var>.
</li>
<li>
<a href="#establish-a-presentation-connection">Establish a presentation connection</a> with
<var>S</var>.
</li>
<li>Abort the remaining steps of <var>T</var>.
</li>
</ol>
</div>
</li>
<li>
<a class="external" data-anolis-spec="promguide" href="http://www.w3.org/2001/tag/doc/promises-guide#shorthand-manipulating" title="resolve-reject">Reject</a> <em>P</em> with a
Expand Down

0 comments on commit cda94c8

Please sign in to comment.