2009-11-18 Kent Tamura <tkent@chromium.org>
authortkent@chromium.org <tkent@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 19 Nov 2009 02:15:17 +0000 (02:15 +0000)
committertkent@chromium.org <tkent@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 19 Nov 2009 02:15:17 +0000 (02:15 +0000)
commitc242b0a4658361e162a5759251543d5a4ac95b16
treea93f86a1c50469c56607c8991588e182a42759b4
parentf6f7b9d4cf49690080651c9c81f6af6e85265211
2009-11-18  Kent Tamura  <tkent@chromium.org>

        Reviewed by Darin Adler.

        Tests for ValidityState.typeMismatch for the following types of INPUT element:
            date, datetime, datetime-local, month, time and week
        https://bugs.webkit.org/show_bug.cgi?id=31342

        * fast/forms/ValidityState-typeMismatch-date-expected.txt: Added.
        * fast/forms/ValidityState-typeMismatch-date.html: Added.
        * fast/forms/ValidityState-typeMismatch-datetime-expected.txt: Added.
        * fast/forms/ValidityState-typeMismatch-datetime.html: Added.
        * fast/forms/ValidityState-typeMismatch-datetimelocal-expected.txt: Added.
        * fast/forms/ValidityState-typeMismatch-datetimelocal.html: Added.
        * fast/forms/ValidityState-typeMismatch-month-expected.txt: Added.
        * fast/forms/ValidityState-typeMismatch-month.html: Added.
        * fast/forms/ValidityState-typeMismatch-time-expected.txt: Added.
        * fast/forms/ValidityState-typeMismatch-time.html: Added.
        * fast/forms/ValidityState-typeMismatch-week-expected.txt: Added.
        * fast/forms/ValidityState-typeMismatch-week.html: Added.
        * fast/forms/script-tests/ValidityState-typeMismatch-date.js: Added.
        * fast/forms/script-tests/ValidityState-typeMismatch-datetime.js: Added.
        * fast/forms/script-tests/ValidityState-typeMismatch-datetimelocal.js: Added.
        * fast/forms/script-tests/ValidityState-typeMismatch-month.js: Added.
        * fast/forms/script-tests/ValidityState-typeMismatch-time.js: Added.
        * fast/forms/script-tests/ValidityState-typeMismatch-week.js: Added.
2009-11-18  Kent Tamura  <tkent@chromium.org>

        Reviewed by Darin Adler.

        Add support for ValidityState.typeMismatch for the following INPUT types:
          date datetime datetime-local month time week
        https://bugs.webkit.org/show_bug.cgi?id=31342

        Tests: fast/forms/ValidityState-typeMismatch-date.html
               fast/forms/ValidityState-typeMismatch-datetime.html
               fast/forms/ValidityState-typeMismatch-datetimelocal.html
               fast/forms/ValidityState-typeMismatch-month.html
               fast/forms/ValidityState-typeMismatch-time.html
               fast/forms/ValidityState-typeMismatch-week.html

        * html/HTMLInputElement.cpp:
        (WebCore::HTMLInputElement::formStringToISODateTime): Check the type
          validity of the specified type and string using the ISODateTime class.
        * html/HTMLInputElement.h:
        * html/ValidityState.cpp:
        (WebCore::ValidityState::typeMismatch): Check the type validity
          for date, datetime, datetime-local, month, time and week with
          HTMLInputElemtn::formStringToISODateTime()

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@51163 268f45cc-cd09-0410-ab3c-d52691b4dbfc
23 files changed:
LayoutTests/ChangeLog
LayoutTests/fast/forms/ValidityState-typeMismatch-date-expected.txt [new file with mode: 0644]
LayoutTests/fast/forms/ValidityState-typeMismatch-date.html [new file with mode: 0644]
LayoutTests/fast/forms/ValidityState-typeMismatch-datetime-expected.txt [new file with mode: 0644]
LayoutTests/fast/forms/ValidityState-typeMismatch-datetime.html [new file with mode: 0644]
LayoutTests/fast/forms/ValidityState-typeMismatch-datetimelocal-expected.txt [new file with mode: 0644]
LayoutTests/fast/forms/ValidityState-typeMismatch-datetimelocal.html [new file with mode: 0644]
LayoutTests/fast/forms/ValidityState-typeMismatch-month-expected.txt [new file with mode: 0644]
LayoutTests/fast/forms/ValidityState-typeMismatch-month.html [new file with mode: 0644]
LayoutTests/fast/forms/ValidityState-typeMismatch-time-expected.txt [new file with mode: 0644]
LayoutTests/fast/forms/ValidityState-typeMismatch-time.html [new file with mode: 0644]
LayoutTests/fast/forms/ValidityState-typeMismatch-week-expected.txt [new file with mode: 0644]
LayoutTests/fast/forms/ValidityState-typeMismatch-week.html [new file with mode: 0644]
LayoutTests/fast/forms/script-tests/ValidityState-typeMismatch-date.js [new file with mode: 0644]
LayoutTests/fast/forms/script-tests/ValidityState-typeMismatch-datetime.js [new file with mode: 0644]
LayoutTests/fast/forms/script-tests/ValidityState-typeMismatch-datetimelocal.js [new file with mode: 0644]
LayoutTests/fast/forms/script-tests/ValidityState-typeMismatch-month.js [new file with mode: 0644]
LayoutTests/fast/forms/script-tests/ValidityState-typeMismatch-time.js [new file with mode: 0644]
LayoutTests/fast/forms/script-tests/ValidityState-typeMismatch-week.js [new file with mode: 0644]
WebCore/ChangeLog
WebCore/html/HTMLInputElement.cpp
WebCore/html/HTMLInputElement.h
WebCore/html/ValidityState.cpp