Skip to content

Commit

Permalink
[giow] (2) history.back() should fire unload too.
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.whatwg.org/webapps@5313 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Aug 20, 2010
1 parent 6053e8a commit 470d3be
Show file tree
Hide file tree
Showing 3 changed files with 60 additions and 11 deletions.
24 changes: 20 additions & 4 deletions complete.html
Expand Up @@ -209,7 +209,7 @@

<header class=head id=head><p><a class=logo href=http://www.whatwg.org/ rel=home><img alt=WHATWG src=/images/logo></a></p>
<hgroup><h1>Web Applications 1.0</h1>
<h2 class="no-num no-toc">Draft Standard &mdash; 18 August 2010</h2>
<h2 class="no-num no-toc">Draft Standard &mdash; 20 August 2010</h2>
</hgroup><p>You can take part in this work. <a href=http://www.whatwg.org/mailing-list>Join the working group's discussion list.</a></p>
<p><strong>Web designers!</strong> We have a <a href=http://blog.whatwg.org/faq/>FAQ</a>, a <a href=http://forums.whatwg.org/>forum</a>, and a <a href=http://www.whatwg.org/mailing-list#help>help mailing list</a> for you!</p>
<!--<p class="impl"><strong>Implementors!</strong> We have a <a href="http://www.whatwg.org/mailing-list#implementors">mailing list</a> for you too!</p>-->
Expand Down Expand Up @@ -59504,7 +59504,7 @@ <h4 id=the-history-interface><span class=secno>6.4.2 </span>The <code><a href=#h
<li><p>If the index of the <a href=#current-entry-of-the-joint-session-history>current entry of the joint session
history</a> plus <var title="">delta</var> is less than zero or
greater than or equal to the number of items in the <a href=#joint-session-history>joint
session history</a>, then the user agent must do nothing.</p>
session history</a>, then abort these steps.</p>

<li><p>Let <var title="">specified entry</var> be the entry in the
<a href=#joint-session-history>joint session history</a> whose index is the sum of <var title="">delta</var> and the index of the <a href=#current-entry-of-the-joint-session-history>current entry of
Expand All @@ -59514,8 +59514,15 @@ <h4 id=the-history-interface><span class=secno>6.4.2 </span>The <code><a href=#h
<a href=#browsing-context>browsing context</a> of the <var title="">specified
entry</var>.</li>

<!-- XXX if going to another doc, try to unload the document here
(firing beforeunload, unload, pagehide) -->
<li><p><a href=#prompt-to-unload-a-document title="prompt to unload a document">Prompt to
unload</a> the <a href=#active-document>active document</a> of the <var title="">specified browsing context</var>. If the user
<a href=#refused-to-allow-the-document-to-be-unloaded>refused to allow the document to be unloaded</a>, then
abort these steps.</li>

<li><p><a href=#unload-a-document title="unload a document">Unload</a> the the
<a href=#active-document>active document</a> of the <var title="">specified
browsing context</var> with the <var title="">recycle</var>
parameter set to false.</li>

<li><p><a href=#traverse-the-history>Traverse the history</a> of the <var title="">specified browsing context</var> to the <var title="">specified entry</var>.</p>

Expand Down Expand Up @@ -60089,6 +60096,15 @@ <h4 id=navigating-across-documents><span class=secno>6.5.1 </span>Navigating acr
<a href=#browsing-context>browsing context</a>.</li>
<!-- http://www.hixie.ch/tests/adhoc/html/navigation/unload/ -->

<li><p>If a <a href=#concept-task title=concept-task>task</a> queued by the
<a href=#traverse-the-history-by-a-delta>traverse the history by a delta</a> algorithm is running
the <a href=#unload-a-document>unload a document</a> algorithm for the <a href=#active-document>active
document</a> of the <a href=#browsing-context>browsing context</a> being
navigated, then abort these steps without affecting the
<a href=#unload-a-document>unload a document</a> algorithm or the aforementioned
history traversal task.</li> <!-- this stops pages from
hijacking the back/forward button -->

<li><p>If there is a preexisting attempt to navigate the
<a href=#browsing-context>browsing context</a>, and either that attempt has not yet
<a href=#concept-navigate-mature title=concept-navigate-mature>matured</a> (i.e. it has
Expand Down
24 changes: 20 additions & 4 deletions index
Expand Up @@ -213,7 +213,7 @@

<header class=head id=head><p><a class=logo href=http://www.whatwg.org/ rel=home><img alt=WHATWG src=/images/logo></a></p>
<hgroup><h1>HTML5 (including next generation additions still in development)</h1>
<h2 class="no-num no-toc">Draft Standard &mdash; 18 August 2010</h2>
<h2 class="no-num no-toc">Draft Standard &mdash; 20 August 2010</h2>
</hgroup><p>You can take part in this work. <a href=http://www.whatwg.org/mailing-list>Join the working group's discussion list.</a></p>
<p><strong>Web designers!</strong> We have a <a href=http://blog.whatwg.org/faq/>FAQ</a>, a <a href=http://forums.whatwg.org/>forum</a>, and a <a href=http://www.whatwg.org/mailing-list#help>help mailing list</a> for you!</p>
<!--<p class="impl"><strong>Implementors!</strong> We have a <a href="http://www.whatwg.org/mailing-list#implementors">mailing list</a> for you too!</p>-->
Expand Down Expand Up @@ -59431,7 +59431,7 @@ x === this; // true</pre>
<li><p>If the index of the <a href=#current-entry-of-the-joint-session-history>current entry of the joint session
history</a> plus <var title="">delta</var> is less than zero or
greater than or equal to the number of items in the <a href=#joint-session-history>joint
session history</a>, then the user agent must do nothing.</p>
session history</a>, then abort these steps.</p>

<li><p>Let <var title="">specified entry</var> be the entry in the
<a href=#joint-session-history>joint session history</a> whose index is the sum of <var title="">delta</var> and the index of the <a href=#current-entry-of-the-joint-session-history>current entry of
Expand All @@ -59441,8 +59441,15 @@ x === this; // true</pre>
<a href=#browsing-context>browsing context</a> of the <var title="">specified
entry</var>.</li>

<!-- XXX if going to another doc, try to unload the document here
(firing beforeunload, unload, pagehide) -->
<li><p><a href=#prompt-to-unload-a-document title="prompt to unload a document">Prompt to
unload</a> the <a href=#active-document>active document</a> of the <var title="">specified browsing context</var>. If the user
<a href=#refused-to-allow-the-document-to-be-unloaded>refused to allow the document to be unloaded</a>, then
abort these steps.</li>

<li><p><a href=#unload-a-document title="unload a document">Unload</a> the the
<a href=#active-document>active document</a> of the <var title="">specified
browsing context</var> with the <var title="">recycle</var>
parameter set to false.</li>

<li><p><a href=#traverse-the-history>Traverse the history</a> of the <var title="">specified browsing context</var> to the <var title="">specified entry</var>.</p>

Expand Down Expand Up @@ -60016,6 +60023,15 @@ State: &lt;OUTPUT NAME=I&gt;1&lt;/OUTPUT&gt; &lt;INPUT VALUE="Increment" TYPE=BU
<a href=#browsing-context>browsing context</a>.</li>
<!-- http://www.hixie.ch/tests/adhoc/html/navigation/unload/ -->

<li><p>If a <a href=#concept-task title=concept-task>task</a> queued by the
<a href=#traverse-the-history-by-a-delta>traverse the history by a delta</a> algorithm is running
the <a href=#unload-a-document>unload a document</a> algorithm for the <a href=#active-document>active
document</a> of the <a href=#browsing-context>browsing context</a> being
navigated, then abort these steps without affecting the
<a href=#unload-a-document>unload a document</a> algorithm or the aforementioned
history traversal task.</li> <!-- this stops pages from
hijacking the back/forward button -->

<li><p>If there is a preexisting attempt to navigate the
<a href=#browsing-context>browsing context</a>, and either that attempt has not yet
<a href=#concept-navigate-mature title=concept-navigate-mature>matured</a> (i.e. it has
Expand Down
23 changes: 20 additions & 3 deletions source
Expand Up @@ -67167,7 +67167,7 @@ x === this; // true</pre>
<li><p>If the index of the <span>current entry of the joint session
history</span> plus <var title="">delta</var> is less than zero or
greater than or equal to the number of items in the <span>joint
session history</span>, then the user agent must do nothing.</p>
session history</span>, then abort these steps.</p>

<li><p>Let <var title="">specified entry</var> be the entry in the
<span>joint session history</span> whose index is the sum of <var
Expand All @@ -67178,8 +67178,16 @@ x === this; // true</pre>
<span>browsing context</span> of the <var title="">specified
entry</var>.</p></li>

<!-- XXX if going to another doc, try to unload the document here
(firing beforeunload, unload, pagehide) -->
<li><p><span title="prompt to unload a document">Prompt to
unload</span> the <span>active document</span> of the <var
title="">specified browsing context</var>. If the user
<span>refused to allow the document to be unloaded</span>, then
abort these steps.</p></li>

<li><p><span title="unload a document">Unload</span> the the
<span>active document</span> of the <var title="">specified
browsing context</var> with the <var title="">recycle</var>
parameter set to false.</p></li>

<li><p><span>Traverse the history</span> of the <var
title="">specified browsing context</var> to the <var
Expand Down Expand Up @@ -67842,6 +67850,15 @@ State: &lt;OUTPUT NAME=I>1&lt;/OUTPUT> &lt;INPUT VALUE="Increment" TYPE=BUTTON O
<span>browsing context</span>.</p></li>
<!-- http://www.hixie.ch/tests/adhoc/html/navigation/unload/ -->

<li><p>If a <span title="concept-task">task</span> queued by the
<span>traverse the history by a delta</span> algorithm is running
the <span>unload a document</span> algorithm for the <span>active
document</span> of the <span>browsing context</span> being
navigated, then abort these steps without affecting the
<span>unload a document</span> algorithm or the aforementioned
history traversal task.</p></li> <!-- this stops pages from
hijacking the back/forward button -->

<li><p>If there is a preexisting attempt to navigate the
<span>browsing context</span>, and either that attempt has not yet
<span title="concept-navigate-mature">matured</span> (i.e. it has
Expand Down

0 comments on commit 470d3be

Please sign in to comment.