[html5] r8338 - [giow] (1) Make <dialog> autofocus the first focusable control if there isn't on [...]

whatwg at whatwg.org whatwg at whatwg.org
Tue Dec 10 14:09:42 PST 2013


Author: ianh
Date: 2013-12-10 14:09:38 -0800 (Tue, 10 Dec 2013)
New Revision: 8338

Modified:
   complete.html
   index
   source
Log:
[giow] (1) Make <dialog> autofocus the first focusable control if there isn't one with autofocus=''.
Fixing https://www.w3.org/Bugs/Public/show_bug.cgi?id=23366
Affected topics: CSS, DOM APIs

Modified: complete.html
===================================================================
--- complete.html	2013-12-09 21:17:21 UTC (rev 8337)
+++ complete.html	2013-12-10 22:09:38 UTC (rev 8338)
@@ -298,7 +298,7 @@
 
   <header class=head id=head><p><a href=http://www.whatwg.org/ class=logo><img width=101 src=/images/logo alt=WHATWG height=101></a></p>
    <hgroup><h1 class=allcaps>HTML</h1>
-    <h2 class="no-num no-toc">Living Standard — Last Updated 9 December 2013</h2>
+    <h2 class="no-num no-toc">Living Standard — Last Updated 10 December 2013</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>
@@ -51027,9 +51027,20 @@
    <li><p>Push <var title="">subject</var> onto <var title="">subject</var>'s
    <code><a href=#document>Document</a></code>'s <a href=#pending-dialog-stack>pending dialog stack</a>.</li>
 
-   <li><p>Let <var title="">control</var> be the first element in tree order whose nearest ancestor
-   <code><a href=#the-dialog-element>dialog</a></code> element is <var title="">subject</var> and that has an <code title=attr-fe-autofocus><a href=#attr-fe-autofocus>autofocus</a></code> attribute specified, if any.</li>
+   <li>
+   
+    <p>Let <var title="">control</var> be the first element in tree order whose nearest ancestor
+    <code><a href=#the-dialog-element>dialog</a></code> element is <var title="">subject</var> and that has an <code title=attr-fe-autofocus><a href=#attr-fe-autofocus>autofocus</a></code> attribute specified, if any.</p>
 
+    <p>If there isn't one, then let <var title="">control</var> be the first element in tree order
+    whose nearest ancestor <code><a href=#the-dialog-element>dialog</a></code> element is <var title="">subject</var> and that is
+    <a href=#focusable>focusable</a>, if any.</p>
+
+    <p>If there isn't one of those either but <var title="">subject</var> itself is
+    <a href=#focusable>focusable</a>, then let <var title="">control</var> be <var title="">subject</var>. (This is unusual.)</p>
+
+   </li>
+
    <li><p>If there is no <var title="">control</var>, then abort these steps.</li>
 
    <li><p>Run the <a href=#focusing-steps>focusing steps</a> for <var title="">control</var>.</li>

Modified: index
===================================================================
--- index	2013-12-09 21:17:21 UTC (rev 8337)
+++ index	2013-12-10 22:09:38 UTC (rev 8338)
@@ -298,7 +298,7 @@
 
   <header class=head id=head><p><a href=http://www.whatwg.org/ class=logo><img width=101 src=/images/logo alt=WHATWG height=101></a></p>
    <hgroup><h1 class=allcaps>HTML</h1>
-    <h2 class="no-num no-toc">Living Standard — Last Updated 9 December 2013</h2>
+    <h2 class="no-num no-toc">Living Standard — Last Updated 10 December 2013</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>
@@ -51027,9 +51027,20 @@
    <li><p>Push <var title="">subject</var> onto <var title="">subject</var>'s
    <code><a href=#document>Document</a></code>'s <a href=#pending-dialog-stack>pending dialog stack</a>.</li>
 
-   <li><p>Let <var title="">control</var> be the first element in tree order whose nearest ancestor
-   <code><a href=#the-dialog-element>dialog</a></code> element is <var title="">subject</var> and that has an <code title=attr-fe-autofocus><a href=#attr-fe-autofocus>autofocus</a></code> attribute specified, if any.</li>
+   <li>
+   
+    <p>Let <var title="">control</var> be the first element in tree order whose nearest ancestor
+    <code><a href=#the-dialog-element>dialog</a></code> element is <var title="">subject</var> and that has an <code title=attr-fe-autofocus><a href=#attr-fe-autofocus>autofocus</a></code> attribute specified, if any.</p>
 
+    <p>If there isn't one, then let <var title="">control</var> be the first element in tree order
+    whose nearest ancestor <code><a href=#the-dialog-element>dialog</a></code> element is <var title="">subject</var> and that is
+    <a href=#focusable>focusable</a>, if any.</p>
+
+    <p>If there isn't one of those either but <var title="">subject</var> itself is
+    <a href=#focusable>focusable</a>, then let <var title="">control</var> be <var title="">subject</var>. (This is unusual.)</p>
+
+   </li>
+
    <li><p>If there is no <var title="">control</var>, then abort these steps.</li>
 
    <li><p>Run the <a href=#focusing-steps>focusing steps</a> for <var title="">control</var>.</li>

Modified: source
===================================================================
--- source	2013-12-09 21:17:21 UTC (rev 8337)
+++ source	2013-12-10 22:09:38 UTC (rev 8338)
@@ -56310,10 +56310,22 @@
    <li><p>Push <var data-x="">subject</var> onto <var data-x="">subject</var>'s
    <code>Document</code>'s <span>pending dialog stack</span>.</p></li>
 
-   <li><p>Let <var data-x="">control</var> be the first element in tree order whose nearest ancestor
-   <code>dialog</code> element is <var data-x="">subject</var> and that has an <code
-   data-x="attr-fe-autofocus">autofocus</code> attribute specified, if any.</p></li>
+   <li>
+   
+    <p>Let <var data-x="">control</var> be the first element in tree order whose nearest ancestor
+    <code>dialog</code> element is <var data-x="">subject</var> and that has an <code
+    data-x="attr-fe-autofocus">autofocus</code> attribute specified, if any.</p>
 
+    <p>If there isn't one, then let <var data-x="">control</var> be the first element in tree order
+    whose nearest ancestor <code>dialog</code> element is <var data-x="">subject</var> and that is
+    <span>focusable</span>, if any.</p>
+
+    <p>If there isn't one of those either but <var data-x="">subject</var> itself is
+    <span>focusable</span>, then let <var data-x="">control</var> be <var
+    data-x="">subject</var>. (This is unusual.)</p>
+
+   </li>
+
    <li><p>If there is no <var data-x="">control</var>, then abort these steps.</p></li>
 
    <li><p>Run the <span>focusing steps</span> for <var data-x="">control</var>.</p></li>




More information about the Commit-Watchers mailing list