[html5] r7554 - [giow] (3) Try to clear up some ambiguities and errors in the navigation algorit [...]

whatwg at whatwg.org whatwg at whatwg.org
Fri Nov 30 16:46:03 PST 2012


Author: ianh
Date: 2012-11-30 16:46:01 -0800 (Fri, 30 Nov 2012)
New Revision: 7554

Modified:
   complete.html
   index
   source
Log:
[giow] (3) Try to clear up some ambiguities and errors in the navigation algorithm, and prevent beforeunload from ever navigating its browsing context.
Fixing https://www.w3.org/Bugs/Public/show_bug.cgi?id=16801
Affected topics: HTML

Modified: complete.html
===================================================================
--- complete.html	2012-11-30 22:14:13 UTC (rev 7553)
+++ complete.html	2012-12-01 00:46:01 UTC (rev 7554)
@@ -248,7 +248,7 @@
 
   <header class=head id=head><p><a class=logo href=http://www.whatwg.org/><img alt=WHATWG height=101 src=/images/logo width=101></a></p>
    <hgroup><h1 class=allcaps>HTML</h1>
-    <h2 class="no-num no-toc">Living Standard — Last Updated 30 November 2012</h2>
+    <h2 class="no-num no-toc">Living Standard — Last Updated 1 December 2012</h2>
    </hgroup><dl><dt><strong>Web developer edition:</strong></dt>
     <dd><strong><a href=http://developers.whatwg.org/>http://developers.whatwg.org/</a></strong></dd>
     <dt>Multiple-page version:</dt>
@@ -69016,6 +69016,13 @@
    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 the <a href=#prompt-to-unload-a-document>prompt to unload a document</a> algorithm is being run 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=#prompt-to-unload-a-document>prompt to unload a document</a> algorithm.</li>
+   <!-- http://software.hixie.ch/utilities/js/live-dom-viewer/saved/1946 to 1955 -->
+
+   <li><p>Let <var title="">gone async</var> be false.</li>
+
    <li id=navigate-fragid-step><p><i>Fragment identifiers</i>: If the <a href=#absolute-url>absolute URL</a> of
    the new resource is the same as the <a href="#the-document's-address" title="the document's address">address</a> of the
    <a href=#active-document>active document</a> of the <a href=#browsing-context>browsing context</a> being navigated, ignoring any
@@ -69024,25 +69031,35 @@
    is empty), then <a href=#scroll-to-fragid title=navigate-fragid>navigate to that fragment identifier</a> and
    abort these steps.</li>
 
-   <li><p>Cancel any preexisting attempt to navigate the <a href=#browsing-context>browsing context</a>, including
-   canceling any instances of the <a href=#fetch>fetch</a> algorithm started by those attempts. If one of
-   those attempts has already <a href=#create-a-document-object title="create a document object">created a new
-   <code>Document</code> object</a>, <a href=#abort-a-document title="abort a document">abort</a> that
-   <code><a href=#document>Document</a></code> also. (Previous navigation attempts whose <a href=#fetch>fetch</a> requests have
-   <em>finished</em> are unaffected, however.)</li>
+   <li><p>If <var title="">gone async</var> is false, cancel any preexisting but not yet <a href=#concept-navigate-mature title=concept-navigate-mature>mature</a> attempt to navigate the <a href=#browsing-context>browsing
+   context</a>, including canceling any instances of the <a href=#fetch>fetch</a> algorithm started by
+   those attempts. If one of those attempts has already <a href=#create-a-document-object title="create a document
+   object">created a new <code>Document</code> object</a>, <a href=#abort-a-document title="abort a
+   document">abort</a> that <code><a href=#document>Document</a></code> also. (Navigation attempts that have <a href=#concept-navigate-mature title=concept-navigate-mature>matured</a> already have session history entries, and are
+   therefore handled during the <a href=#update-the-session-history-with-the-new-page>update the session history with the new page</a> algorithm,
+   later.)</li>
 
    <li><p>If the new resource is to be handled using a mechanism that does not affect the browsing
    context, e.g. ignoring the navigation request altogether because the specified scheme is not one
    of the supported protocols, then abort these steps and proceed with that mechanism
    instead.</li>
 
-   <li><p><a href=#prompt-to-unload-a-document title="prompt to unload a document">Prompt to unload</a> the
-   <code><a href=#document>Document</a></code> object. 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>
 
-   <li><p><a href=#abort-a-document title="abort a document">Abort</a> the <a href=#active-document>active document</a> of the
-   <a href=#browsing-context>browsing context</a>.</li>
+    <p>If <var title="">gone async</var> is false, <a href=#prompt-to-unload-a-document title="prompt to unload a document">prompt
+    to unload</a> the <code><a href=#document>Document</a></code> object. 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.</p>
 
+    <p>If this instance of the <a href=#navigate title=navigate>navigation</a> algorithm gets canceled
+    while this step is running, the <a href=#prompt-to-unload-a-document>prompt to unload a document</a> algorithm must
+    nonetheless be run to completion.</p>
+
+   </li>
+
+   <li><p>If <var title="">gone async</var> is false, <a href=#abort-a-document title="abort a
+   document">abort</a> the <a href=#active-document>active document</a> of the <a href=#browsing-context>browsing
+   context</a>.</li>
+
    <li>
 
     <p>If the new resource is to be handled by displaying some sort of inline content, e.g. an error
@@ -69108,12 +69125,13 @@
 
     <!-- *********************************** ASYNC BOUNDARY *********************************** -->
 
-    <p>At this point, unless this step has already been reached once before in the execution of this
-    instance of the algorithm, the user agents must return to whatever algorithm invoked the
-    navigation steps and must continue these steps asynchronously.</p>
+    <p>If <var title="">gone async</var> is false, the user agents must return to whatever
+    algorithm invoked the navigation steps and must continue running these steps asynchronously.</p>
 
    </li>
 
+   <li><p>Let <var title="">gone async</var> be true.</li>
+
    <li>
 
     <p>If fetching the resource results in a redirect, and either the <a href=#url>URL</a> of the target

Modified: index
===================================================================
--- index	2012-11-30 22:14:13 UTC (rev 7553)
+++ index	2012-12-01 00:46:01 UTC (rev 7554)
@@ -248,7 +248,7 @@
 
   <header class=head id=head><p><a class=logo href=http://www.whatwg.org/><img alt=WHATWG height=101 src=/images/logo width=101></a></p>
    <hgroup><h1 class=allcaps>HTML</h1>
-    <h2 class="no-num no-toc">Living Standard — Last Updated 30 November 2012</h2>
+    <h2 class="no-num no-toc">Living Standard — Last Updated 1 December 2012</h2>
    </hgroup><dl><dt><strong>Web developer edition:</strong></dt>
     <dd><strong><a href=http://developers.whatwg.org/>http://developers.whatwg.org/</a></strong></dd>
     <dt>Multiple-page version:</dt>
@@ -69016,6 +69016,13 @@
    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 the <a href=#prompt-to-unload-a-document>prompt to unload a document</a> algorithm is being run 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=#prompt-to-unload-a-document>prompt to unload a document</a> algorithm.</li>
+   <!-- http://software.hixie.ch/utilities/js/live-dom-viewer/saved/1946 to 1955 -->
+
+   <li><p>Let <var title="">gone async</var> be false.</li>
+
    <li id=navigate-fragid-step><p><i>Fragment identifiers</i>: If the <a href=#absolute-url>absolute URL</a> of
    the new resource is the same as the <a href="#the-document's-address" title="the document's address">address</a> of the
    <a href=#active-document>active document</a> of the <a href=#browsing-context>browsing context</a> being navigated, ignoring any
@@ -69024,25 +69031,35 @@
    is empty), then <a href=#scroll-to-fragid title=navigate-fragid>navigate to that fragment identifier</a> and
    abort these steps.</li>
 
-   <li><p>Cancel any preexisting attempt to navigate the <a href=#browsing-context>browsing context</a>, including
-   canceling any instances of the <a href=#fetch>fetch</a> algorithm started by those attempts. If one of
-   those attempts has already <a href=#create-a-document-object title="create a document object">created a new
-   <code>Document</code> object</a>, <a href=#abort-a-document title="abort a document">abort</a> that
-   <code><a href=#document>Document</a></code> also. (Previous navigation attempts whose <a href=#fetch>fetch</a> requests have
-   <em>finished</em> are unaffected, however.)</li>
+   <li><p>If <var title="">gone async</var> is false, cancel any preexisting but not yet <a href=#concept-navigate-mature title=concept-navigate-mature>mature</a> attempt to navigate the <a href=#browsing-context>browsing
+   context</a>, including canceling any instances of the <a href=#fetch>fetch</a> algorithm started by
+   those attempts. If one of those attempts has already <a href=#create-a-document-object title="create a document
+   object">created a new <code>Document</code> object</a>, <a href=#abort-a-document title="abort a
+   document">abort</a> that <code><a href=#document>Document</a></code> also. (Navigation attempts that have <a href=#concept-navigate-mature title=concept-navigate-mature>matured</a> already have session history entries, and are
+   therefore handled during the <a href=#update-the-session-history-with-the-new-page>update the session history with the new page</a> algorithm,
+   later.)</li>
 
    <li><p>If the new resource is to be handled using a mechanism that does not affect the browsing
    context, e.g. ignoring the navigation request altogether because the specified scheme is not one
    of the supported protocols, then abort these steps and proceed with that mechanism
    instead.</li>
 
-   <li><p><a href=#prompt-to-unload-a-document title="prompt to unload a document">Prompt to unload</a> the
-   <code><a href=#document>Document</a></code> object. 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>
 
-   <li><p><a href=#abort-a-document title="abort a document">Abort</a> the <a href=#active-document>active document</a> of the
-   <a href=#browsing-context>browsing context</a>.</li>
+    <p>If <var title="">gone async</var> is false, <a href=#prompt-to-unload-a-document title="prompt to unload a document">prompt
+    to unload</a> the <code><a href=#document>Document</a></code> object. 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.</p>
 
+    <p>If this instance of the <a href=#navigate title=navigate>navigation</a> algorithm gets canceled
+    while this step is running, the <a href=#prompt-to-unload-a-document>prompt to unload a document</a> algorithm must
+    nonetheless be run to completion.</p>
+
+   </li>
+
+   <li><p>If <var title="">gone async</var> is false, <a href=#abort-a-document title="abort a
+   document">abort</a> the <a href=#active-document>active document</a> of the <a href=#browsing-context>browsing
+   context</a>.</li>
+
    <li>
 
     <p>If the new resource is to be handled by displaying some sort of inline content, e.g. an error
@@ -69108,12 +69125,13 @@
 
     <!-- *********************************** ASYNC BOUNDARY *********************************** -->
 
-    <p>At this point, unless this step has already been reached once before in the execution of this
-    instance of the algorithm, the user agents must return to whatever algorithm invoked the
-    navigation steps and must continue these steps asynchronously.</p>
+    <p>If <var title="">gone async</var> is false, the user agents must return to whatever
+    algorithm invoked the navigation steps and must continue running these steps asynchronously.</p>
 
    </li>
 
+   <li><p>Let <var title="">gone async</var> be true.</li>
+
    <li>
 
     <p>If fetching the resource results in a redirect, and either the <a href=#url>URL</a> of the target

Modified: source
===================================================================
--- source	2012-11-30 22:14:13 UTC (rev 7553)
+++ source	2012-12-01 00:46:01 UTC (rev 7554)
@@ -80773,6 +80773,13 @@
    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 the <span>prompt to unload a document</span> algorithm is being run for the
+   <span>active document</span> of the <span>browsing context</span> being navigated, then abort
+   these steps without affecting the <span>prompt to unload a document</span> algorithm.</p></li>
+   <!-- http://software.hixie.ch/utilities/js/live-dom-viewer/saved/1946 to 1955 -->
+
+   <li><p>Let <var title="">gone async</var> be false.</p></li>
+
    <li id="navigate-fragid-step"><p><i>Fragment identifiers</i>: If the <span>absolute URL</span> of
    the new resource is the same as the <span title="the document's address">address</span> of the
    <span>active document</span> of the <span>browsing context</span> being navigated, ignoring any
@@ -80783,25 +80790,37 @@
    is empty), then <span title="navigate-fragid">navigate to that fragment identifier</span> and
    abort these steps.</p></li>
 
-   <li><p>Cancel any preexisting attempt to navigate the <span>browsing context</span>, including
-   canceling any instances of the <span>fetch</span> algorithm started by those attempts. If one of
-   those attempts has already <span title="create a document object">created a new
-   <code>Document</code> object</span>, <span title="abort a document">abort</span> that
-   <code>Document</code> also. (Previous navigation attempts whose <span>fetch</span> requests have
-   <em>finished</em> are unaffected, however.)</p></li>
+   <li><p>If <var title="">gone async</var> is false, cancel any preexisting but not yet <span
+   title="concept-navigate-mature">mature</span> attempt to navigate the <span>browsing
+   context</span>, including canceling any instances of the <span>fetch</span> algorithm started by
+   those attempts. If one of those attempts has already <span title="create a document
+   object">created a new <code>Document</code> object</span>, <span title="abort a
+   document">abort</span> that <code>Document</code> also. (Navigation attempts that have <span
+   title="concept-navigate-mature">matured</span> already have session history entries, and are
+   therefore handled during the <span>update the session history with the new page</span> algorithm,
+   later.)</p></li>
 
    <li><p>If the new resource is to be handled using a mechanism that does not affect the browsing
    context, e.g. ignoring the navigation request altogether because the specified scheme is not one
    of the supported protocols, then abort these steps and proceed with that mechanism
    instead.</p></li>
 
-   <li><p><span title="prompt to unload a document">Prompt to unload</span> the
-   <code>Document</code> object. If the user <span>refused to allow the document to be
-   unloaded</span>, then abort these steps.</p></li>
+   <li>
 
-   <li><p><span title="abort a document">Abort</span> the <span>active document</span> of the
-   <span>browsing context</span>.</p></li>
+    <p>If <var title="">gone async</var> is false, <span title="prompt to unload a document">prompt
+    to unload</span> the <code>Document</code> object. If the user <span>refused to allow the
+    document to be unloaded</span>, then abort these steps.</p>
 
+    <p>If this instance of the <span title="navigate">navigation</span> algorithm gets canceled
+    while this step is running, the <span>prompt to unload a document</span> algorithm must
+    nonetheless be run to completion.</p>
+
+   </li>
+
+   <li><p>If <var title="">gone async</var> is false, <span title="abort a
+   document">abort</span> the <span>active document</span> of the <span>browsing
+   context</span>.</p></li>
+
    <li>
 
     <p>If the new resource is to be handled by displaying some sort of inline content, e.g. an error
@@ -80872,12 +80891,13 @@
 
     <!-- *********************************** ASYNC BOUNDARY *********************************** -->
 
-    <p>At this point, unless this step has already been reached once before in the execution of this
-    instance of the algorithm, the user agents must return to whatever algorithm invoked the
-    navigation steps and must continue these steps asynchronously.</p>
+    <p>If <var title="">gone async</var> is false, the user agents must return to whatever
+    algorithm invoked the navigation steps and must continue running these steps asynchronously.</p>
 
    </li>
 
+   <li><p>Let <var title="">gone async</var> be true.</p></li>
+
    <li>
 
     <p>If fetching the resource results in a redirect, and either the <span>URL</span> of the target




More information about the Commit-Watchers mailing list