[html5] r8744 - [giow] (2) Make RadioNodeList's radio button logic support the magical 'on' valu [...]

whatwg at whatwg.org whatwg at whatwg.org
Thu Sep 4 14:31:10 PDT 2014


Author: ianh
Date: 2014-09-04 14:31:07 -0700 (Thu, 04 Sep 2014)
New Revision: 8744

Modified:
   complete.html
   index
   source
Log:
[giow] (2) Make RadioNodeList's radio button logic support the magical 'on' value.
Fixing https://www.w3.org/Bugs/Public/show_bug.cgi?id=26353
Affected topics: DOM APIs

Modified: complete.html
===================================================================
--- complete.html	2014-09-04 21:21:34 UTC (rev 8743)
+++ complete.html	2014-09-04 21:31:07 UTC (rev 8744)
@@ -5150,16 +5150,20 @@
 
   <ol><li><p>Let <var>element</var> be the first element in <a href=#tree-order id=htmlformcontrolscollection:tree-order-4>tree order</a>
    represented by the <code id=htmlformcontrolscollection:radionodelist-9><a href=#radionodelist>RadioNodeList</a></code> object that is an <code id=htmlformcontrolscollection:the-input-element><a href=#the-input-element>input</a></code> element whose
-   <code id=htmlformcontrolscollection:attr-input-type><a href=#attr-input-type>type</a></code> attribute is in the <a href="#radio-button-state-(type=radio)" id="htmlformcontrolscollection:radio-button-state-(type=radio)">Radio Button</a> state and whose <a href=#concept-fe-checked id=htmlformcontrolscollection:concept-fe-checked>checkedness</a> is true. Otherwise, let it be null.<li><p>If <var>element</var> is null, or if it is an element with no <code id=htmlformcontrolscollection:attr-input-value><a href=#attr-input-value>value</a></code> attribute, return the empty string.<li><p>Otherwise, return the value of <var>element</var>'s <code id=htmlformcontrolscollection:attr-input-value-2><a href=#attr-input-value>value</a></code> attribute.</ol>
+   <code id=htmlformcontrolscollection:attr-input-type><a href=#attr-input-type>type</a></code> attribute is in the <a href="#radio-button-state-(type=radio)" id="htmlformcontrolscollection:radio-button-state-(type=radio)">Radio Button</a> state and whose <a href=#concept-fe-checked id=htmlformcontrolscollection:concept-fe-checked>checkedness</a> is true. Otherwise, let it be null.<li><p>If <var>element</var> is null, return the empty string.<li><p>If <var>element</var> is an element with no <code id=htmlformcontrolscollection:attr-input-value><a href=#attr-input-value>value</a></code> attribute, return the string "<code>on</code>".<li><p>Otherwise, return the value of <var>element</var>'s <code id=htmlformcontrolscollection:attr-input-value-2><a href=#attr-input-value>value</a></code> attribute.</ol>
 
   <p>On setting, the <code id=htmlformcontrolscollection:dom-radionodelist-value-2><a href=#dom-radionodelist-value>value</a></code> IDL attribute must run the
   following steps:</p>
 
-  <ol><li><p>Let <var>element</var> be the first element in <a href=#tree-order id=htmlformcontrolscollection:tree-order-5>tree order</a>
+  <ol><li><p>If the new value is the string "<code>on</code>": let <var>element</var> be the first element in <a href=#tree-order id=htmlformcontrolscollection:tree-order-5>tree order</a>
    represented by the <code id=htmlformcontrolscollection:radionodelist-10><a href=#radionodelist>RadioNodeList</a></code> object that is an <code id=htmlformcontrolscollection:the-input-element-2><a href=#the-input-element>input</a></code> element whose
-   <code id=htmlformcontrolscollection:attr-input-type-2><a href=#attr-input-type>type</a></code> attribute is in the <a href="#radio-button-state-(type=radio)" id="htmlformcontrolscollection:radio-button-state-(type=radio)-2">Radio Button</a> state and whose <code id=htmlformcontrolscollection:attr-input-value-3><a href=#attr-input-value>value</a></code> content attribute is present and equal to the new value, if
-   any. Otherwise, let it be null.<li><p>If <var>element</var> is not null, then set its <a href=#concept-fe-checked id=htmlformcontrolscollection:concept-fe-checked-2>checkedness</a> to true.</p>
+   <code id=htmlformcontrolscollection:attr-input-type-2><a href=#attr-input-type>type</a></code> attribute is in the <a href="#radio-button-state-(type=radio)" id="htmlformcontrolscollection:radio-button-state-(type=radio)-2">Radio Button</a> state and whose <code id=htmlformcontrolscollection:attr-input-value-3><a href=#attr-input-value>value</a></code> content attribute is either absent, or present and equal to the new value, if any. If no such element exists, then instead let <var>element</var> be null.</p>
 
+   <p>Otherwise: let <var>element</var> be the first element in <a href=#tree-order id=htmlformcontrolscollection:tree-order-6>tree order</a>
+   represented by the <code id=htmlformcontrolscollection:radionodelist-11><a href=#radionodelist>RadioNodeList</a></code> object that is an <code id=htmlformcontrolscollection:the-input-element-3><a href=#the-input-element>input</a></code> element whose
+   <code id=htmlformcontrolscollection:attr-input-type-3><a href=#attr-input-type>type</a></code> attribute is in the <a href="#radio-button-state-(type=radio)" id="htmlformcontrolscollection:radio-button-state-(type=radio)-3">Radio Button</a> state and whose <code id=htmlformcontrolscollection:attr-input-value-4><a href=#attr-input-value>value</a></code> content attribute is present and equal to the new value, if
+   any. If no such element exists, then instead let <var>element</var> be null.<li><p>If <var>element</var> is not null, then set its <a href=#concept-fe-checked id=htmlformcontrolscollection:concept-fe-checked-2>checkedness</a> to true.</p>
+
   </ol>
 
 

Modified: index
===================================================================
--- index	2014-09-04 21:21:34 UTC (rev 8743)
+++ index	2014-09-04 21:31:07 UTC (rev 8744)
@@ -5150,16 +5150,20 @@
 
   <ol><li><p>Let <var>element</var> be the first element in <a href=#tree-order id=htmlformcontrolscollection:tree-order-4>tree order</a>
    represented by the <code id=htmlformcontrolscollection:radionodelist-9><a href=#radionodelist>RadioNodeList</a></code> object that is an <code id=htmlformcontrolscollection:the-input-element><a href=#the-input-element>input</a></code> element whose
-   <code id=htmlformcontrolscollection:attr-input-type><a href=#attr-input-type>type</a></code> attribute is in the <a href="#radio-button-state-(type=radio)" id="htmlformcontrolscollection:radio-button-state-(type=radio)">Radio Button</a> state and whose <a href=#concept-fe-checked id=htmlformcontrolscollection:concept-fe-checked>checkedness</a> is true. Otherwise, let it be null.<li><p>If <var>element</var> is null, or if it is an element with no <code id=htmlformcontrolscollection:attr-input-value><a href=#attr-input-value>value</a></code> attribute, return the empty string.<li><p>Otherwise, return the value of <var>element</var>'s <code id=htmlformcontrolscollection:attr-input-value-2><a href=#attr-input-value>value</a></code> attribute.</ol>
+   <code id=htmlformcontrolscollection:attr-input-type><a href=#attr-input-type>type</a></code> attribute is in the <a href="#radio-button-state-(type=radio)" id="htmlformcontrolscollection:radio-button-state-(type=radio)">Radio Button</a> state and whose <a href=#concept-fe-checked id=htmlformcontrolscollection:concept-fe-checked>checkedness</a> is true. Otherwise, let it be null.<li><p>If <var>element</var> is null, return the empty string.<li><p>If <var>element</var> is an element with no <code id=htmlformcontrolscollection:attr-input-value><a href=#attr-input-value>value</a></code> attribute, return the string "<code>on</code>".<li><p>Otherwise, return the value of <var>element</var>'s <code id=htmlformcontrolscollection:attr-input-value-2><a href=#attr-input-value>value</a></code> attribute.</ol>
 
   <p>On setting, the <code id=htmlformcontrolscollection:dom-radionodelist-value-2><a href=#dom-radionodelist-value>value</a></code> IDL attribute must run the
   following steps:</p>
 
-  <ol><li><p>Let <var>element</var> be the first element in <a href=#tree-order id=htmlformcontrolscollection:tree-order-5>tree order</a>
+  <ol><li><p>If the new value is the string "<code>on</code>": let <var>element</var> be the first element in <a href=#tree-order id=htmlformcontrolscollection:tree-order-5>tree order</a>
    represented by the <code id=htmlformcontrolscollection:radionodelist-10><a href=#radionodelist>RadioNodeList</a></code> object that is an <code id=htmlformcontrolscollection:the-input-element-2><a href=#the-input-element>input</a></code> element whose
-   <code id=htmlformcontrolscollection:attr-input-type-2><a href=#attr-input-type>type</a></code> attribute is in the <a href="#radio-button-state-(type=radio)" id="htmlformcontrolscollection:radio-button-state-(type=radio)-2">Radio Button</a> state and whose <code id=htmlformcontrolscollection:attr-input-value-3><a href=#attr-input-value>value</a></code> content attribute is present and equal to the new value, if
-   any. Otherwise, let it be null.<li><p>If <var>element</var> is not null, then set its <a href=#concept-fe-checked id=htmlformcontrolscollection:concept-fe-checked-2>checkedness</a> to true.</p>
+   <code id=htmlformcontrolscollection:attr-input-type-2><a href=#attr-input-type>type</a></code> attribute is in the <a href="#radio-button-state-(type=radio)" id="htmlformcontrolscollection:radio-button-state-(type=radio)-2">Radio Button</a> state and whose <code id=htmlformcontrolscollection:attr-input-value-3><a href=#attr-input-value>value</a></code> content attribute is either absent, or present and equal to the new value, if any. If no such element exists, then instead let <var>element</var> be null.</p>
 
+   <p>Otherwise: let <var>element</var> be the first element in <a href=#tree-order id=htmlformcontrolscollection:tree-order-6>tree order</a>
+   represented by the <code id=htmlformcontrolscollection:radionodelist-11><a href=#radionodelist>RadioNodeList</a></code> object that is an <code id=htmlformcontrolscollection:the-input-element-3><a href=#the-input-element>input</a></code> element whose
+   <code id=htmlformcontrolscollection:attr-input-type-3><a href=#attr-input-type>type</a></code> attribute is in the <a href="#radio-button-state-(type=radio)" id="htmlformcontrolscollection:radio-button-state-(type=radio)-3">Radio Button</a> state and whose <code id=htmlformcontrolscollection:attr-input-value-4><a href=#attr-input-value>value</a></code> content attribute is present and equal to the new value, if
+   any. If no such element exists, then instead let <var>element</var> be null.<li><p>If <var>element</var> is not null, then set its <a href=#concept-fe-checked id=htmlformcontrolscollection:concept-fe-checked-2>checkedness</a> to true.</p>
+
   </ol>
 
 

Modified: source
===================================================================
--- source	2014-09-04 21:21:34 UTC (rev 8743)
+++ source	2014-09-04 21:31:07 UTC (rev 8744)
@@ -7643,9 +7643,11 @@
    data-x="attr-input-type-radio">Radio Button</span> state and whose <span
    data-x="concept-fe-checked">checkedness</span> is true. Otherwise, let it be null.</p></li>
 
-   <li><p>If <var>element</var> is null, or if it is an element with no <code
-   data-x="attr-input-value">value</code> attribute, return the empty string.</p></li>
+   <li><p>If <var>element</var> is null, return the empty string.</p></li>
 
+   <li><p>If <var>element</var> is an element with no <code
+   data-x="attr-input-value">value</code> attribute, return the string "<code data-x="">on</code>".</p></li>
+
    <li><p>Otherwise, return the value of <var>element</var>'s <code
    data-x="attr-input-value">value</code> attribute.</p></li>
 
@@ -7656,12 +7658,18 @@
 
   <ol>
 
-   <li><p>Let <var>element</var> be the first element in <span>tree order</span>
+   <li><p>If the new value is the string "<code data-x="">on</code>": let <var>element</var> be the first element in <span>tree order</span>
    represented by the <code>RadioNodeList</code> object that is an <code>input</code> element whose
    <code data-x="attr-input-type">type</code> attribute is in the <span
    data-x="attr-input-type-radio">Radio Button</span> state and whose <code
+   data-x="attr-input-value">value</code> content attribute is either absent, or present and equal to the new value, if any. If no such element exists, then instead let <var>element</var> be null.</p>
+
+   <p>Otherwise: let <var>element</var> be the first element in <span>tree order</span>
+   represented by the <code>RadioNodeList</code> object that is an <code>input</code> element whose
+   <code data-x="attr-input-type">type</code> attribute is in the <span
+   data-x="attr-input-type-radio">Radio Button</span> state and whose <code
    data-x="attr-input-value">value</code> content attribute is present and equal to the new value, if
-   any. Otherwise, let it be null.</p></li>
+   any. If no such element exists, then instead let <var>element</var> be null.</p></li>
 
    <li><p>If <var>element</var> is not null, then set its <span
    data-x="concept-fe-checked">checkedness</span> to true.</p>



More information about the Commit-Watchers mailing list