Changeset 87896 in webkit


Ignore:
Timestamp:
Jun 2, 2011 5:00:55 AM (13 years ago)
Author:
commit-queue@webkit.org
Message:

2011-06-02 Naiem Shaik <naiem.shaik@gmail.com>

Reviewed by Kent Tamura.

Fixing invalid value being returned for default checkbox and radio state
https://bugs.webkit.org/show_bug.cgi?id=61674

As per http://www.w3.org/TR/html5/number-state.html#checkbox-state and
http://www.w3.org/TR/html5/number-state.html#radio-button-state:
The value IDL attribute is in mode default/on:
If the element has a value attribute, it must return that attribute's
value; otherwise, it must return the string "on".
Currently default value is empty string;Default value of Radio button
and checkbox should be "on"
This works as per spec in IE9,Firefox and Opera

  • fast/forms/checkbox-default-value-expected.txt: Added.
  • fast/forms/checkbox-default-value.html: Added.
  • fast/forms/radio-default-value-expected.txt: Added.
  • fast/forms/radio-default-value.html: Added.

2011-06-02 Naiem Shaik <naiem.shaik@gmail.com>

Reviewed by Kent Tamura.

Fixing invalid value being returned for default checkbox and radio state
https://bugs.webkit.org/show_bug.cgi?id=61674

As per http://www.w3.org/TR/html5/number-state.html#checkbox-state and
http://www.w3.org/TR/html5/number-state.html#radio-button-state:
The value IDL attribute is in mode default/on:
If the element has a value attribute, it must return that attribute's
value; otherwise, it must return the string "on".
Currently default value is empty string;Default value of Radio button
and checkbox should be "on".Changed fallbackValue function to return the same
This works as per spec in IE9,Firefox and Opera

Tests: fast/forms/checkbox-default-value.html

fast/forms/radio-default-value.html

  • html/BaseCheckableInputType.cpp: (WebCore::BaseCheckableInputType::fallbackValue):
Location:
trunk
Files:
4 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r87895 r87896  
     12011-06-02  Naiem Shaik  <naiem.shaik@gmail.com>
     2
     3        Reviewed by Kent Tamura.
     4
     5        Fixing invalid value being returned for default checkbox and radio state
     6        https://bugs.webkit.org/show_bug.cgi?id=61674
     7
     8        As per http://www.w3.org/TR/html5/number-state.html#checkbox-state and
     9        http://www.w3.org/TR/html5/number-state.html#radio-button-state:
     10        The value IDL attribute is in mode default/on:
     11        If the element has a value attribute, it must return that attribute's
     12        value; otherwise, it must return the string "on".
     13        Currently default value is empty string;Default value of Radio button
     14        and checkbox should be "on"
     15        This works as per spec in IE9,Firefox and Opera
     16
     17        * fast/forms/checkbox-default-value-expected.txt: Added.
     18        * fast/forms/checkbox-default-value.html: Added.
     19        * fast/forms/radio-default-value-expected.txt: Added.
     20        * fast/forms/radio-default-value.html: Added.
     21
    1222011-06-02  Mario Sanchez Prada  <msanchez@igalia.com>
    223
  • trunk/Source/WebCore/ChangeLog

    r87891 r87896  
     12011-06-02  Naiem Shaik  <naiem.shaik@gmail.com>
     2
     3        Reviewed by Kent Tamura.
     4       
     5        Fixing invalid value being returned for default checkbox and radio state
     6        https://bugs.webkit.org/show_bug.cgi?id=61674
     7
     8        As per http://www.w3.org/TR/html5/number-state.html#checkbox-state and
     9        http://www.w3.org/TR/html5/number-state.html#radio-button-state:
     10        The value IDL attribute is in mode default/on:
     11        If the element has a value attribute, it must return that attribute's
     12        value; otherwise, it must return the string "on". 
     13        Currently default value is empty string;Default value of Radio button
     14        and checkbox should be "on".Changed fallbackValue function to return the same
     15        This works as per spec in IE9,Firefox and Opera
     16
     17        Tests: fast/forms/checkbox-default-value.html
     18               fast/forms/radio-default-value.html
     19
     20        * html/BaseCheckableInputType.cpp:
     21        (WebCore::BaseCheckableInputType::fallbackValue):
     22
    1232011-06-02  Kent Tamura  <tkent@chromium.org>
    224
  • trunk/Source/WebCore/html/BaseCheckableInputType.cpp

    r74895 r87896  
    9595String BaseCheckableInputType::fallbackValue()
    9696{
    97     return element()->checked() ? "on" : "";
     97    return "on";
    9898}
    9999
Note: See TracChangeset for help on using the changeset viewer.