Diff
Modified: trunk/LayoutTests/fast/forms/ValidityState-001.html (205523 => 205524)
--- trunk/LayoutTests/fast/forms/ValidityState-001.html 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/LayoutTests/fast/forms/ValidityState-001.html 2016-09-07 00:00:12 UTC (rev 205524)
@@ -22,7 +22,7 @@
v = document.getElementsByName("victim");
for (i = 0; i < v.length; i++)
- log('Test for ' + v[i].tagName + ': ' + ((v[i].validity && countAttr(v[i].validity) == 10) ? "SUCCESS" : "FAILURE"));
+ log('Test for ' + v[i].tagName + ': ' + ((v[i].validity && countAttr(v[i].validity) == 11) ? "SUCCESS" : "FAILURE"));
}
</script>
</head>
Modified: trunk/LayoutTests/imported/w3c/ChangeLog (205523 => 205524)
--- trunk/LayoutTests/imported/w3c/ChangeLog 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/LayoutTests/imported/w3c/ChangeLog 2016-09-07 00:00:12 UTC (rev 205524)
@@ -1,5 +1,17 @@
2016-09-06 Chris Dumez <[email protected]>
+ Add support for input.minLength / textArea.minLength
+ https://bugs.webkit.org/show_bug.cgi?id=161644
+
+ Reviewed by Darin Adler.
+
+ Rebaseline several W3C tests now that more checks are passing.
+
+ * web-platform-tests/html/dom/interfaces-expected.txt:
+ * web-platform-tests/html/semantics/forms/constraints/form-validation-validity-tooShort-expected.txt:
+
+2016-09-06 Chris Dumez <[email protected]>
+
Align srcset attribute parsing with the HTML specification
https://bugs.webkit.org/show_bug.cgi?id=161636
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/interfaces-expected.txt (205523 => 205524)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/interfaces-expected.txt 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/html/dom/interfaces-expected.txt 2016-09-07 00:00:12 UTC (rev 205524)
@@ -2706,7 +2706,7 @@
PASS HTMLInputElement interface: attribute max
PASS HTMLInputElement interface: attribute maxLength
PASS HTMLInputElement interface: attribute min
-FAIL HTMLInputElement interface: attribute minLength assert_true: The prototype object must have a property "minLength" expected true got false
+PASS HTMLInputElement interface: attribute minLength
PASS HTMLInputElement interface: attribute multiple
PASS HTMLInputElement interface: attribute name
PASS HTMLInputElement interface: attribute pattern
@@ -2766,7 +2766,7 @@
PASS HTMLInputElement interface: document.createElement("input") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: document.createElement("input") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: document.createElement("input") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: document.createElement("input") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: document.createElement("input") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: document.createElement("input") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: document.createElement("input") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: document.createElement("input") must inherit property "pattern" with the proper type (25)
@@ -2832,7 +2832,7 @@
PASS HTMLInputElement interface: createInput("text") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("text") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("text") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("text") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("text") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("text") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("text") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("text") must inherit property "pattern" with the proper type (25)
@@ -2898,7 +2898,7 @@
PASS HTMLInputElement interface: createInput("hidden") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("hidden") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("hidden") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("hidden") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("hidden") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("hidden") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("hidden") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("hidden") must inherit property "pattern" with the proper type (25)
@@ -2964,7 +2964,7 @@
PASS HTMLInputElement interface: createInput("search") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("search") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("search") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("search") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("search") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("search") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("search") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("search") must inherit property "pattern" with the proper type (25)
@@ -3030,7 +3030,7 @@
PASS HTMLInputElement interface: createInput("tel") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("tel") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("tel") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("tel") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("tel") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("tel") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("tel") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("tel") must inherit property "pattern" with the proper type (25)
@@ -3096,7 +3096,7 @@
PASS HTMLInputElement interface: createInput("url") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("url") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("url") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("url") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("url") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("url") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("url") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("url") must inherit property "pattern" with the proper type (25)
@@ -3162,7 +3162,7 @@
PASS HTMLInputElement interface: createInput("email") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("email") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("email") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("email") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("email") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("email") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("email") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("email") must inherit property "pattern" with the proper type (25)
@@ -3228,7 +3228,7 @@
PASS HTMLInputElement interface: createInput("password") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("password") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("password") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("password") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("password") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("password") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("password") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("password") must inherit property "pattern" with the proper type (25)
@@ -3294,7 +3294,7 @@
PASS HTMLInputElement interface: createInput("date") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("date") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("date") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("date") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("date") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("date") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("date") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("date") must inherit property "pattern" with the proper type (25)
@@ -3360,7 +3360,7 @@
PASS HTMLInputElement interface: createInput("month") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("month") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("month") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("month") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("month") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("month") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("month") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("month") must inherit property "pattern" with the proper type (25)
@@ -3426,7 +3426,7 @@
PASS HTMLInputElement interface: createInput("week") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("week") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("week") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("week") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("week") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("week") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("week") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("week") must inherit property "pattern" with the proper type (25)
@@ -3492,7 +3492,7 @@
PASS HTMLInputElement interface: createInput("time") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("time") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("time") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("time") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("time") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("time") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("time") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("time") must inherit property "pattern" with the proper type (25)
@@ -3558,7 +3558,7 @@
PASS HTMLInputElement interface: createInput("datetime-local") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("datetime-local") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("datetime-local") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("datetime-local") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("datetime-local") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("datetime-local") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("datetime-local") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("datetime-local") must inherit property "pattern" with the proper type (25)
@@ -3624,7 +3624,7 @@
PASS HTMLInputElement interface: createInput("number") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("number") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("number") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("number") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("number") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("number") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("number") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("number") must inherit property "pattern" with the proper type (25)
@@ -3690,7 +3690,7 @@
PASS HTMLInputElement interface: createInput("range") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("range") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("range") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("range") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("range") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("range") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("range") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("range") must inherit property "pattern" with the proper type (25)
@@ -3756,7 +3756,7 @@
PASS HTMLInputElement interface: createInput("color") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("color") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("color") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("color") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("color") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("color") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("color") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("color") must inherit property "pattern" with the proper type (25)
@@ -3822,7 +3822,7 @@
PASS HTMLInputElement interface: createInput("checkbox") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("checkbox") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("checkbox") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("checkbox") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("checkbox") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("checkbox") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("checkbox") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("checkbox") must inherit property "pattern" with the proper type (25)
@@ -3888,7 +3888,7 @@
PASS HTMLInputElement interface: createInput("radio") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("radio") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("radio") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("radio") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("radio") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("radio") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("radio") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("radio") must inherit property "pattern" with the proper type (25)
@@ -3954,7 +3954,7 @@
PASS HTMLInputElement interface: createInput("file") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("file") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("file") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("file") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("file") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("file") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("file") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("file") must inherit property "pattern" with the proper type (25)
@@ -4020,7 +4020,7 @@
PASS HTMLInputElement interface: createInput("submit") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("submit") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("submit") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("submit") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("submit") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("submit") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("submit") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("submit") must inherit property "pattern" with the proper type (25)
@@ -4086,7 +4086,7 @@
PASS HTMLInputElement interface: createInput("image") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("image") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("image") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("image") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("image") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("image") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("image") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("image") must inherit property "pattern" with the proper type (25)
@@ -4152,7 +4152,7 @@
PASS HTMLInputElement interface: createInput("reset") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("reset") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("reset") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("reset") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("reset") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("reset") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("reset") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("reset") must inherit property "pattern" with the proper type (25)
@@ -4218,7 +4218,7 @@
PASS HTMLInputElement interface: createInput("button") must inherit property "max" with the proper type (19)
PASS HTMLInputElement interface: createInput("button") must inherit property "maxLength" with the proper type (20)
PASS HTMLInputElement interface: createInput("button") must inherit property "min" with the proper type (21)
-FAIL HTMLInputElement interface: createInput("button") must inherit property "minLength" with the proper type (22) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLInputElement interface: createInput("button") must inherit property "minLength" with the proper type (22)
PASS HTMLInputElement interface: createInput("button") must inherit property "multiple" with the proper type (23)
PASS HTMLInputElement interface: createInput("button") must inherit property "name" with the proper type (24)
PASS HTMLInputElement interface: createInput("button") must inherit property "pattern" with the proper type (25)
@@ -4436,7 +4436,7 @@
PASS HTMLTextAreaElement interface: attribute form
FAIL HTMLTextAreaElement interface: attribute inputMode assert_true: The prototype object must have a property "inputMode" expected true got false
PASS HTMLTextAreaElement interface: attribute maxLength
-FAIL HTMLTextAreaElement interface: attribute minLength assert_true: The prototype object must have a property "minLength" expected true got false
+PASS HTMLTextAreaElement interface: attribute minLength
PASS HTMLTextAreaElement interface: attribute name
PASS HTMLTextAreaElement interface: attribute placeholder
PASS HTMLTextAreaElement interface: attribute readOnly
@@ -4471,7 +4471,7 @@
PASS HTMLTextAreaElement interface: document.createElement("textarea") must inherit property "form" with the proper type (5)
FAIL HTMLTextAreaElement interface: document.createElement("textarea") must inherit property "inputMode" with the proper type (6) assert_inherits: property "inputMode" not found in prototype chain
PASS HTMLTextAreaElement interface: document.createElement("textarea") must inherit property "maxLength" with the proper type (7)
-FAIL HTMLTextAreaElement interface: document.createElement("textarea") must inherit property "minLength" with the proper type (8) assert_inherits: property "minLength" not found in prototype chain
+PASS HTMLTextAreaElement interface: document.createElement("textarea") must inherit property "minLength" with the proper type (8)
PASS HTMLTextAreaElement interface: document.createElement("textarea") must inherit property "name" with the proper type (9)
PASS HTMLTextAreaElement interface: document.createElement("textarea") must inherit property "placeholder" with the proper type (10)
PASS HTMLTextAreaElement interface: document.createElement("textarea") must inherit property "readOnly" with the proper type (11)
@@ -4650,7 +4650,7 @@
PASS ValidityState interface: attribute typeMismatch
PASS ValidityState interface: attribute patternMismatch
PASS ValidityState interface: attribute tooLong
-FAIL ValidityState interface: attribute tooShort assert_true: The prototype object must have a property "tooShort" expected true got false
+PASS ValidityState interface: attribute tooShort
PASS ValidityState interface: attribute rangeUnderflow
PASS ValidityState interface: attribute rangeOverflow
PASS ValidityState interface: attribute stepMismatch
@@ -4663,7 +4663,7 @@
PASS ValidityState interface: document.createElement("input").validity must inherit property "typeMismatch" with the proper type (1)
PASS ValidityState interface: document.createElement("input").validity must inherit property "patternMismatch" with the proper type (2)
PASS ValidityState interface: document.createElement("input").validity must inherit property "tooLong" with the proper type (3)
-FAIL ValidityState interface: document.createElement("input").validity must inherit property "tooShort" with the proper type (4) assert_inherits: property "tooShort" not found in prototype chain
+PASS ValidityState interface: document.createElement("input").validity must inherit property "tooShort" with the proper type (4)
PASS ValidityState interface: document.createElement("input").validity must inherit property "rangeUnderflow" with the proper type (5)
PASS ValidityState interface: document.createElement("input").validity must inherit property "rangeOverflow" with the proper type (6)
PASS ValidityState interface: document.createElement("input").validity must inherit property "stepMismatch" with the proper type (7)
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/forms/constraints/form-validation-validity-tooShort-expected.txt (205523 => 205524)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/forms/constraints/form-validation-validity-tooShort-expected.txt 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/forms/constraints/form-validation-validity-tooShort-expected.txt 2016-09-07 00:00:12 UTC (rev 205524)
@@ -1,65 +1,65 @@
-FAIL [INPUT in TEXT status] Non-dirty value - minLength is not set assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEXT status] Non-dirty value - value is empty string assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEXT status] Non-dirty value - length of value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEXT status] Non-dirty value - length of value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEXT status] Non-dirty value - length of value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEXT status] Dirty value - value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEXT status] Dirty value - length of value(AAAAA) in unicode is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEXT status] Dirty value - value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEXT status] Dirty value - length of value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in SEARCH status] Non-dirty value - minLength is not set assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in SEARCH status] Non-dirty value - value is empty string assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in SEARCH status] Non-dirty value - length of value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in SEARCH status] Non-dirty value - length of value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in SEARCH status] Non-dirty value - length of value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in SEARCH status] Dirty value - value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in SEARCH status] Dirty value - length of value(AAAAA) in unicode is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in SEARCH status] Dirty value - value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in SEARCH status] Dirty value - length of value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEL status] Non-dirty value - minLength is not set assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEL status] Non-dirty value - value is empty string assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEL status] Non-dirty value - length of value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEL status] Non-dirty value - length of value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEL status] Non-dirty value - length of value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEL status] Dirty value - value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEL status] Dirty value - length of value(AAAAA) in unicode is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEL status] Dirty value - value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in TEL status] Dirty value - length of value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in URL status] Non-dirty value - minLength is not set assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in URL status] Non-dirty value - value is empty string assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in URL status] Non-dirty value - length of value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in URL status] Non-dirty value - length of value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in URL status] Non-dirty value - length of value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in URL status] Dirty value - value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in URL status] Dirty value - length of value(AAAAA) in unicode is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in URL status] Dirty value - value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in URL status] Dirty value - length of value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in EMAIL status] Non-dirty value - minLength is not set assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in EMAIL status] Non-dirty value - value is empty string assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in EMAIL status] Non-dirty value - length of value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in EMAIL status] Non-dirty value - length of value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in EMAIL status] Non-dirty value - length of value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in EMAIL status] Dirty value - value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in EMAIL status] Dirty value - length of value(AAAAA) in unicode is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in EMAIL status] Dirty value - value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in EMAIL status] Dirty value - length of value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in PASSWORD status] Non-dirty value - minLength is not set assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in PASSWORD status] Non-dirty value - value is empty string assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in PASSWORD status] Non-dirty value - length of value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in PASSWORD status] Non-dirty value - length of value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in PASSWORD status] Non-dirty value - length of value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in PASSWORD status] Dirty value - value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in PASSWORD status] Dirty value - length of value(AAAAA) in unicode is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in PASSWORD status] Dirty value - value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [INPUT in PASSWORD status] Dirty value - length of value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [textarea] Non-dirty value - minLength is no set assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [textarea] Non-dirty value - value is empty string assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [textarea] Non-dirty value - length of value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [textarea] Non-dirty value - length of value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [textarea] Non-dirty value - length of length of value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [textarea] Dirty value - value is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [textarea] Dirty value - length of value(LF, CRLF) in unicode is less than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [textarea] Dirty value - length of value equals to minLength assert_true: The tooShort attribute doesn't exist. expected true got false
-FAIL [textarea] Dirty value - length of value is greater than minLength assert_true: The tooShort attribute doesn't exist. expected true got false
+PASS [INPUT in TEXT status] Non-dirty value - minLength is not set
+PASS [INPUT in TEXT status] Non-dirty value - value is empty string
+PASS [INPUT in TEXT status] Non-dirty value - length of value is greater than minLength
+PASS [INPUT in TEXT status] Non-dirty value - length of value equals to minLength
+PASS [INPUT in TEXT status] Non-dirty value - length of value is less than minLength
+PASS [INPUT in TEXT status] Dirty value - value is greater than minLength
+PASS [INPUT in TEXT status] Dirty value - length of value(AAAAA) in unicode is greater than minLength
+PASS [INPUT in TEXT status] Dirty value - value equals to minLength
+PASS [INPUT in TEXT status] Dirty value - length of value is less than minLength
+PASS [INPUT in SEARCH status] Non-dirty value - minLength is not set
+PASS [INPUT in SEARCH status] Non-dirty value - value is empty string
+PASS [INPUT in SEARCH status] Non-dirty value - length of value is greater than minLength
+PASS [INPUT in SEARCH status] Non-dirty value - length of value equals to minLength
+PASS [INPUT in SEARCH status] Non-dirty value - length of value is less than minLength
+PASS [INPUT in SEARCH status] Dirty value - value is greater than minLength
+PASS [INPUT in SEARCH status] Dirty value - length of value(AAAAA) in unicode is greater than minLength
+PASS [INPUT in SEARCH status] Dirty value - value equals to minLength
+PASS [INPUT in SEARCH status] Dirty value - length of value is less than minLength
+PASS [INPUT in TEL status] Non-dirty value - minLength is not set
+PASS [INPUT in TEL status] Non-dirty value - value is empty string
+PASS [INPUT in TEL status] Non-dirty value - length of value is greater than minLength
+PASS [INPUT in TEL status] Non-dirty value - length of value equals to minLength
+PASS [INPUT in TEL status] Non-dirty value - length of value is less than minLength
+PASS [INPUT in TEL status] Dirty value - value is greater than minLength
+PASS [INPUT in TEL status] Dirty value - length of value(AAAAA) in unicode is greater than minLength
+PASS [INPUT in TEL status] Dirty value - value equals to minLength
+PASS [INPUT in TEL status] Dirty value - length of value is less than minLength
+PASS [INPUT in URL status] Non-dirty value - minLength is not set
+PASS [INPUT in URL status] Non-dirty value - value is empty string
+PASS [INPUT in URL status] Non-dirty value - length of value is greater than minLength
+PASS [INPUT in URL status] Non-dirty value - length of value equals to minLength
+PASS [INPUT in URL status] Non-dirty value - length of value is less than minLength
+PASS [INPUT in URL status] Dirty value - value is greater than minLength
+PASS [INPUT in URL status] Dirty value - length of value(AAAAA) in unicode is greater than minLength
+PASS [INPUT in URL status] Dirty value - value equals to minLength
+PASS [INPUT in URL status] Dirty value - length of value is less than minLength
+PASS [INPUT in EMAIL status] Non-dirty value - minLength is not set
+PASS [INPUT in EMAIL status] Non-dirty value - value is empty string
+PASS [INPUT in EMAIL status] Non-dirty value - length of value is greater than minLength
+PASS [INPUT in EMAIL status] Non-dirty value - length of value equals to minLength
+PASS [INPUT in EMAIL status] Non-dirty value - length of value is less than minLength
+PASS [INPUT in EMAIL status] Dirty value - value is greater than minLength
+PASS [INPUT in EMAIL status] Dirty value - length of value(AAAAA) in unicode is greater than minLength
+PASS [INPUT in EMAIL status] Dirty value - value equals to minLength
+PASS [INPUT in EMAIL status] Dirty value - length of value is less than minLength
+PASS [INPUT in PASSWORD status] Non-dirty value - minLength is not set
+PASS [INPUT in PASSWORD status] Non-dirty value - value is empty string
+PASS [INPUT in PASSWORD status] Non-dirty value - length of value is greater than minLength
+PASS [INPUT in PASSWORD status] Non-dirty value - length of value equals to minLength
+PASS [INPUT in PASSWORD status] Non-dirty value - length of value is less than minLength
+PASS [INPUT in PASSWORD status] Dirty value - value is greater than minLength
+PASS [INPUT in PASSWORD status] Dirty value - length of value(AAAAA) in unicode is greater than minLength
+PASS [INPUT in PASSWORD status] Dirty value - value equals to minLength
+PASS [INPUT in PASSWORD status] Dirty value - length of value is less than minLength
+PASS [textarea] Non-dirty value - minLength is no set
+PASS [textarea] Non-dirty value - value is empty string
+PASS [textarea] Non-dirty value - length of value is greater than minLength
+PASS [textarea] Non-dirty value - length of value equals to minLength
+PASS [textarea] Non-dirty value - length of length of value is greater than minLength
+PASS [textarea] Dirty value - value is less than minLength
+PASS [textarea] Dirty value - length of value(LF, CRLF) in unicode is less than minLength
+PASS [textarea] Dirty value - length of value equals to minLength
+PASS [textarea] Dirty value - length of value is greater than minLength
Modified: trunk/Source/WTF/wtf/text/TextBreakIterator.cpp (205523 => 205524)
--- trunk/Source/WTF/wtf/text/TextBreakIterator.cpp 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WTF/wtf/text/TextBreakIterator.cpp 2016-09-07 00:00:12 UTC (rev 205524)
@@ -894,18 +894,18 @@
return ruleStatus != UBRK_WORD_NONE;
}
-unsigned numGraphemeClusters(const String& s)
+unsigned numGraphemeClusters(StringView string)
{
- unsigned stringLength = s.length();
+ unsigned stringLength = string.length();
if (!stringLength)
return 0;
// The only Latin-1 Extended Grapheme Cluster is CR LF
- if (s.is8Bit() && !s.contains('\r'))
+ if (string.is8Bit() && !string.contains('\r'))
return stringLength;
- NonSharedCharacterBreakIterator it(s);
+ NonSharedCharacterBreakIterator it(string);
if (!it)
return stringLength;
Modified: trunk/Source/WTF/wtf/text/TextBreakIterator.h (205523 => 205524)
--- trunk/Source/WTF/wtf/text/TextBreakIterator.h 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WTF/wtf/text/TextBreakIterator.h 2016-09-07 00:00:12 UTC (rev 205524)
@@ -209,7 +209,7 @@
// Counts the number of grapheme clusters. A surrogate pair or a sequence
// of a non-combining character and following combining characters is
// counted as 1 grapheme cluster.
-WTF_EXPORT_PRIVATE unsigned numGraphemeClusters(const String&);
+WTF_EXPORT_PRIVATE unsigned numGraphemeClusters(StringView);
// Returns the number of characters which will be less than or equal to
// the specified grapheme cluster length.
WTF_EXPORT_PRIVATE unsigned numCharactersInGraphemeClusters(const StringView&, unsigned);
Modified: trunk/Source/WebCore/ChangeLog (205523 => 205524)
--- trunk/Source/WebCore/ChangeLog 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/ChangeLog 2016-09-07 00:00:12 UTC (rev 205524)
@@ -1,3 +1,66 @@
+2016-09-06 Chris Dumez <[email protected]>
+
+ Add support for input.minLength / textArea.minLength
+ https://bugs.webkit.org/show_bug.cgi?id=161644
+
+ Reviewed by Darin Adler.
+
+ Add support for input.minLength / textArea.minLength:
+ - https://html.spec.whatwg.org/#dom-input-minlength
+ - https://html.spec.whatwg.org/#dom-textarea-minlength
+
+ Chrome implements this, Firefox does not yet.
+
+ No new tests, rebaselined existing tests.
+
+ * html/FormAssociatedElement.cpp:
+ (WebCore::FormAssociatedElement::tooShort):
+ (WebCore::FormAssociatedElement::valid):
+ (WebCore::FormAssociatedElement::typeMismatch): Deleted.
+ * html/FormAssociatedElement.h:
+ * html/HTMLAttributeNames.in:
+ * html/HTMLInputElement.cpp:
+ (WebCore::HTMLInputElement::HTMLInputElement):
+ (WebCore::HTMLInputElement::isValidValue):
+ (WebCore::HTMLInputElement::tooShort):
+ (WebCore::HTMLInputElement::tooLong):
+ (WebCore::HTMLInputElement::parseAttribute):
+ (WebCore::HTMLInputElement::effectiveMaxLength):
+ (WebCore::HTMLInputElement::maxLengthAttributeChanged):
+ (WebCore::HTMLInputElement::minLengthAttributeChanged):
+ (WebCore::HTMLInputElement::patternMismatch): Deleted.
+ (WebCore::parseAcceptAttribute): Deleted.
+ (WebCore::HTMLInputElement::isEnumeratable): Deleted.
+ (WebCore::HTMLInputElement::supportLabels): Deleted.
+ * html/HTMLInputElement.h:
+ (WebCore::HTMLInputElement::supportsMinLength):
+ (WebCore::HTMLInputElement::supportsMaxLength): Deleted.
+ * html/HTMLInputElement.idl:
+ * html/HTMLTextAreaElement.cpp:
+ (WebCore::HTMLTextAreaElement::parseAttribute):
+ (WebCore::HTMLTextAreaElement::maxLengthAttributeChanged):
+ (WebCore::HTMLTextAreaElement::minLengthAttributeChanged):
+ (WebCore::HTMLTextAreaElement::validationMessage):
+ (WebCore::HTMLTextAreaElement::tooShort):
+ (WebCore::HTMLTextAreaElement::tooLong):
+ (WebCore::HTMLTextAreaElement::isValidValue):
+ * html/HTMLTextAreaElement.h:
+ * html/HTMLTextAreaElement.idl:
+ * html/HTMLTextFormControlElement.cpp:
+ (WebCore::HTMLTextFormControlElement::setMaxLength):
+ (WebCore::HTMLTextFormControlElement::setMinLength):
+ * html/HTMLTextFormControlElement.h:
+ (WebCore::HTMLTextFormControlElement::maxLength):
+ (WebCore::HTMLTextFormControlElement::setMaxLength):
+ (WebCore::HTMLTextFormControlElement::minLength):
+ (WebCore::HTMLTextFormControlElement::setMinLength):
+ * html/InputType.cpp:
+ (WebCore::InputType::validationMessage):
+ * html/ValidityState.idl:
+ * platform/LocalizedStrings.cpp:
+ (WebCore::validationMessageTooShortText):
+ * platform/LocalizedStrings.h:
+
2016-09-06 Alex Christensen <[email protected]>
Punycode encode non-ascii hosts in URLParser
Modified: trunk/Source/WebCore/html/FormAssociatedElement.cpp (205523 => 205524)
--- trunk/Source/WebCore/html/FormAssociatedElement.cpp 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/FormAssociatedElement.cpp 2016-09-07 00:00:12 UTC (rev 205524)
@@ -222,6 +222,11 @@
return false;
}
+bool FormAssociatedElement::tooShort() const
+{
+ return false;
+}
+
bool FormAssociatedElement::tooLong() const
{
return false;
@@ -235,7 +240,7 @@
bool FormAssociatedElement::valid() const
{
bool someError = typeMismatch() || stepMismatch() || rangeUnderflow() || rangeOverflow()
- || tooLong() || patternMismatch() || valueMissing() || hasBadInput() || customError();
+ || tooShort() || tooLong() || patternMismatch() || valueMissing() || hasBadInput() || customError();
return !someError;
}
Modified: trunk/Source/WebCore/html/FormAssociatedElement.h (205523 => 205524)
--- trunk/Source/WebCore/html/FormAssociatedElement.h 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/FormAssociatedElement.h 2016-09-07 00:00:12 UTC (rev 205524)
@@ -72,12 +72,13 @@
bool badInput() const { return hasBadInput(); }
bool customError() const;
- // Implementations of patternMismatch, rangeOverflow, rangerUnderflow, stepMismatch, tooLong and valueMissing must call willValidate.
+ // Implementations of patternMismatch, rangeOverflow, rangerUnderflow, stepMismatch, tooShort, tooLong and valueMissing must call willValidate.
virtual bool hasBadInput() const;
virtual bool patternMismatch() const;
virtual bool rangeOverflow() const;
virtual bool rangeUnderflow() const;
virtual bool stepMismatch() const;
+ virtual bool tooShort() const;
virtual bool tooLong() const;
virtual bool typeMismatch() const;
virtual bool valueMissing() const;
Modified: trunk/Source/WebCore/html/HTMLAttributeNames.in (205523 => 205524)
--- trunk/Source/WebCore/html/HTMLAttributeNames.in 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/HTMLAttributeNames.in 2016-09-07 00:00:12 UTC (rev 205524)
@@ -164,6 +164,7 @@
marginwidth
max
maxlength
+minlength
mayscript
media
mediagroup
Modified: trunk/Source/WebCore/html/HTMLInputElement.cpp (205523 => 205524)
--- trunk/Source/WebCore/html/HTMLInputElement.cpp 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/HTMLInputElement.cpp 2016-09-07 00:00:12 UTC (rev 205524)
@@ -96,7 +96,6 @@
HTMLInputElement::HTMLInputElement(const QualifiedName& tagName, Document& document, HTMLFormElement* form, bool createdByParser)
: HTMLTextFormControlElement(tagName, document, form)
, m_size(defaultSize)
- , m_maxLength(-1)
, m_maxResults(-1)
, m_isChecked(false)
, m_reflectsCheckedAttribute(true)
@@ -248,11 +247,17 @@
&& !m_inputType->stepMismatch(value)
&& !m_inputType->rangeUnderflow(value)
&& !m_inputType->rangeOverflow(value)
+ && !tooShort(value, IgnoreDirtyFlag)
&& !tooLong(value, IgnoreDirtyFlag)
&& !m_inputType->patternMismatch(value)
&& !m_inputType->valueMissing(value);
}
+bool HTMLInputElement::tooShort() const
+{
+ return willValidate() && tooShort(value(), CheckDirtyFlag);
+}
+
bool HTMLInputElement::tooLong() const
{
return willValidate() && tooLong(value(), CheckDirtyFlag);
@@ -278,12 +283,34 @@
return willValidate() && m_inputType->patternMismatch(value());
}
-bool HTMLInputElement::tooLong(const String& value, NeedsToCheckDirtyFlag check) const
+bool HTMLInputElement::tooShort(StringView value, NeedsToCheckDirtyFlag check) const
{
- // We use isTextType() instead of supportsMaxLength() because of the
- // 'virtual' overhead.
- if (!isTextType())
+ if (!supportsMinLength())
return false;
+
+ int min = minLength();
+ if (min <= 0)
+ return false;
+
+ if (check == CheckDirtyFlag) {
+ // Return false for the default value or a value set by a script even if
+ // it is shorter than minLength.
+ if (!hasDirtyValue() || !m_wasModifiedByUser)
+ return false;
+ }
+
+ // The empty string is excluded from tooShort validation.
+ if (value.isEmpty())
+ return false;
+
+ // FIXME: The HTML specification says that the "number of characters" is measured using code-unit length.
+ return numGraphemeClusters(value) < static_cast<unsigned>(min);
+}
+
+bool HTMLInputElement::tooLong(StringView value, NeedsToCheckDirtyFlag check) const
+{
+ if (!supportsMaxLength())
+ return false;
unsigned max = effectiveMaxLength();
if (check == CheckDirtyFlag) {
// Return false for the default value or a value set by a script even if
@@ -291,6 +318,7 @@
if (!hasDirtyValue() || !m_wasModifiedByUser)
return false;
}
+ // FIXME: The HTML specification says that the "number of characters" is measured using code-unit length.
return numGraphemeClusters(value) > max;
}
@@ -694,6 +722,8 @@
}
} else if (name == maxlengthAttr)
maxLengthAttributeChanged(value);
+ else if (name == minAttr)
+ minLengthAttributeChanged(value);
else if (name == sizeAttr) {
unsigned oldSize = m_size;
m_size = limitToOnlyHTMLNonNegativeNumbersGreaterThanZero(value, defaultSize);
@@ -1276,7 +1306,7 @@
unsigned HTMLInputElement::effectiveMaxLength() const
{
// The number -1 represents no maximum at all; conveniently it becomes a super-large value when converted to unsigned.
- return std::min<unsigned>(m_maxLength, maxEffectiveLength);
+ return std::min<unsigned>(maxLength(), maxEffectiveLength);
}
bool HTMLInputElement::multiple() const
@@ -1755,7 +1785,7 @@
void HTMLInputElement::maxLengthAttributeChanged(const AtomicString& newValue)
{
unsigned oldEffectiveMaxLength = effectiveMaxLength();
- m_maxLength = parseHTMLNonNegativeInteger(newValue).valueOr(-1);
+ setMaxLength(parseHTMLNonNegativeInteger(newValue).valueOr(-1));
if (oldEffectiveMaxLength != effectiveMaxLength())
updateValueIfNeeded();
@@ -1764,6 +1794,18 @@
updateValidity();
}
+void HTMLInputElement::minLengthAttributeChanged(const AtomicString& newValue)
+{
+ int oldMinLength = minLength();
+ setMinLength(parseHTMLNonNegativeInteger(newValue).valueOr(-1));
+ if (oldMinLength != minLength())
+ updateValueIfNeeded();
+
+ // FIXME: Do we really need to do this if the effective minLength has not changed?
+ setNeedsStyleRecalc();
+ updateValidity();
+}
+
void HTMLInputElement::updateValueIfNeeded()
{
String newValue = sanitizeValue(m_valueIfDirty);
Modified: trunk/Source/WebCore/html/HTMLInputElement.h (205523 => 205524)
--- trunk/Source/WebCore/html/HTMLInputElement.h 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/HTMLInputElement.h 2016-09-07 00:00:12 UTC (rev 205524)
@@ -74,6 +74,7 @@
bool rangeUnderflow() const final;
bool rangeOverflow() const final;
bool stepMismatch() const final;
+ bool tooShort() const final;
bool tooLong() const final;
bool typeMismatch() const final;
bool valueMissing() const final;
@@ -236,7 +237,6 @@
URL src() const;
- int maxLengthForBindings() const { return m_maxLength; }
unsigned effectiveMaxLength() const;
bool multiple() const;
@@ -402,9 +402,11 @@
void registerForSuspensionCallbackIfNeeded();
void unregisterForSuspensionCallbackIfNeeded();
+ bool supportsMinLength() const { return isTextType(); }
bool supportsMaxLength() const { return isTextType(); }
bool isTextType() const;
- bool tooLong(const String&, NeedsToCheckDirtyFlag) const;
+ bool tooShort(StringView, NeedsToCheckDirtyFlag) const;
+ bool tooLong(StringView, NeedsToCheckDirtyFlag) const;
bool supportsPlaceholder() const final;
void updatePlaceholderText() final;
@@ -427,6 +429,7 @@
void resetListAttributeTargetObserver();
#endif
void maxLengthAttributeChanged(const AtomicString& newValue);
+ void minLengthAttributeChanged(const AtomicString& newValue);
void updateValueIfNeeded();
void addToRadioButtonGroup();
@@ -435,7 +438,6 @@
AtomicString m_name;
String m_valueIfDirty;
unsigned m_size;
- int m_maxLength;
short m_maxResults;
bool m_isChecked : 1;
bool m_reflectsCheckedAttribute : 1;
Modified: trunk/Source/WebCore/html/HTMLInputElement.idl (205523 => 205524)
--- trunk/Source/WebCore/html/HTMLInputElement.idl 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/HTMLInputElement.idl 2016-09-07 00:00:12 UTC (rev 205524)
@@ -44,7 +44,8 @@
attribute boolean indeterminate;
[Conditional=DATALIST_ELEMENT] readonly attribute HTMLElement list;
[Reflect] attribute DOMString max;
- [ImplementedAs=maxLengthForBindings, SetterRaisesException] attribute long maxLength;
+ [SetterRaisesException] attribute long minLength;
+ [SetterRaisesException] attribute long maxLength;
[Reflect] attribute DOMString min;
[Reflect] attribute boolean multiple;
[Reflect] attribute DOMString name;
Modified: trunk/Source/WebCore/html/HTMLTextAreaElement.cpp (205523 => 205524)
--- trunk/Source/WebCore/html/HTMLTextAreaElement.cpp 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/HTMLTextAreaElement.cpp 2016-09-07 00:00:12 UTC (rev 205524)
@@ -61,12 +61,12 @@
// On submission, LF characters are converted into CRLF.
// This function returns number of characters considering this.
-static inline unsigned computeLengthForSubmission(const String& text, unsigned numberOfLineBreaks)
+static inline unsigned computeLengthForSubmission(StringView text, unsigned numberOfLineBreaks)
{
return numGraphemeClusters(text) + numberOfLineBreaks;
}
-static unsigned numberOfLineBreaks(const String& text)
+static unsigned numberOfLineBreaks(StringView text)
{
unsigned length = text.length();
unsigned count = 0;
@@ -77,12 +77,12 @@
return count;
}
-static inline unsigned computeLengthForSubmission(const String& text)
+static inline unsigned computeLengthForSubmission(StringView text)
{
return numGraphemeClusters(text) + numberOfLineBreaks(text);
}
-static inline unsigned upperBoundForLengthForSubmission(const String& text, unsigned numberOfLineBreaks)
+static inline unsigned upperBoundForLengthForSubmission(StringView text, unsigned numberOfLineBreaks)
{
return text.length() + numberOfLineBreaks;
}
@@ -197,6 +197,8 @@
// ignore for the moment
} else if (name == maxlengthAttr)
maxLengthAttributeChanged(value);
+ else if (name == minlengthAttr)
+ minLengthAttributeChanged(value);
else
HTMLTextFormControlElement::parseAttribute(name, value);
}
@@ -203,10 +205,16 @@
void HTMLTextAreaElement::maxLengthAttributeChanged(const AtomicString& newValue)
{
- m_maxLength = parseHTMLNonNegativeInteger(newValue).valueOr(-1);
+ setMaxLength(parseHTMLNonNegativeInteger(newValue).valueOr(-1));
updateValidity();
}
+void HTMLTextAreaElement::minLengthAttributeChanged(const AtomicString& newValue)
+{
+ setMinLength(parseHTMLNonNegativeInteger(newValue).valueOr(-1));
+ updateValidity();
+}
+
RenderPtr<RenderElement> HTMLTextAreaElement::createElementRenderer(RenderStyle&& style, const RenderTreePosition&)
{
return createRenderer<RenderTextControlMultiLine>(*this, WTFMove(style));
@@ -432,6 +440,9 @@
if (valueMissing())
return validationMessageValueMissingText();
+ if (tooShort())
+ return validationMessageTooShortText(computeLengthForSubmission(value()), minLength());
+
if (tooLong())
return validationMessageTooLongText(computeLengthForSubmission(value()), effectiveMaxLength());
@@ -443,12 +454,40 @@
return willValidate() && valueMissing(value());
}
+bool HTMLTextAreaElement::tooShort() const
+{
+ return willValidate() && tooShort(value(), CheckDirtyFlag);
+}
+
+bool HTMLTextAreaElement::tooShort(StringView value, NeedsToCheckDirtyFlag check) const
+{
+ // Return false for the default value or value set by script even if it is
+ // shorter than minLength.
+ if (check == CheckDirtyFlag && !m_wasModifiedByUser)
+ return false;
+
+ int min = minLength();
+ if (min <= 0)
+ return false;
+
+ // The empty string is excluded from tooShort validation.
+ if (value.isEmpty())
+ return false;
+
+ // FIXME: The HTML specification says that the "number of characters" is measured using code-unit length and,
+ // in the case of textarea elements, with all line breaks normalized to a single character (as opposed to CRLF pairs).
+ unsigned unsignedMin = static_cast<unsigned>(min);
+ unsigned numberOfLineBreaksInValue = numberOfLineBreaks(value);
+ return upperBoundForLengthForSubmission(value, numberOfLineBreaksInValue) < unsignedMin
+ && computeLengthForSubmission(value, numberOfLineBreaksInValue) < unsignedMin;
+}
+
bool HTMLTextAreaElement::tooLong() const
{
return willValidate() && tooLong(value(), CheckDirtyFlag);
}
-bool HTMLTextAreaElement::tooLong(const String& value, NeedsToCheckDirtyFlag check) const
+bool HTMLTextAreaElement::tooLong(StringView value, NeedsToCheckDirtyFlag check) const
{
// Return false for the default value or value set by script even if it is
// longer than maxLength.
@@ -458,6 +497,9 @@
int max = effectiveMaxLength();
if (max < 0)
return false;
+
+ // FIXME: The HTML specification says that the "number of characters" is measured using code-unit length and,
+ // in the case of textarea elements, with all line breaks normalized to a single character (as opposed to CRLF pairs).
unsigned unsignedMax = static_cast<unsigned>(max);
unsigned numberOfLineBreaksInValue = numberOfLineBreaks(value);
return upperBoundForLengthForSubmission(value, numberOfLineBreaksInValue) > unsignedMax
@@ -466,7 +508,7 @@
bool HTMLTextAreaElement::isValidValue(const String& candidate) const
{
- return !valueMissing(candidate) && !tooLong(candidate, IgnoreDirtyFlag);
+ return !valueMissing(candidate) && !tooShort(candidate, IgnoreDirtyFlag) && !tooLong(candidate, IgnoreDirtyFlag);
}
void HTMLTextAreaElement::accessKeyAction(bool)
Modified: trunk/Source/WebCore/html/HTMLTextAreaElement.h (205523 => 205524)
--- trunk/Source/WebCore/html/HTMLTextAreaElement.h 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/HTMLTextAreaElement.h 2016-09-07 00:00:12 UTC (rev 205524)
@@ -45,11 +45,11 @@
WEBCORE_EXPORT String defaultValue() const;
WEBCORE_EXPORT void setDefaultValue(const String&);
int textLength() const { return value().length(); }
- int maxLengthForBindings() const { return m_maxLength; }
- int effectiveMaxLength() const { return m_maxLength; }
+ int effectiveMaxLength() const { return maxLength(); }
// For ValidityState
String validationMessage() const final;
bool valueMissing() const final;
+ bool tooShort() const final;
bool tooLong() const final;
bool isValidValue(const String&) const;
@@ -73,6 +73,7 @@
void didAddUserAgentShadowRoot(ShadowRoot*) final;
void maxLengthAttributeChanged(const AtomicString& newValue);
+ void minLengthAttributeChanged(const AtomicString& newValue);
void handleBeforeTextInsertedEvent(BeforeTextInsertedEvent&) const;
static String sanitizeUserInputValue(const String&, unsigned maxLength);
@@ -120,11 +121,11 @@
bool matchesReadWritePseudoClass() const final;
bool valueMissing(const String& value) const { return isRequiredFormControl() && !isDisabledOrReadOnly() && value.isEmpty(); }
- bool tooLong(const String&, NeedsToCheckDirtyFlag) const;
+ bool tooShort(StringView, NeedsToCheckDirtyFlag) const;
+ bool tooLong(StringView, NeedsToCheckDirtyFlag) const;
unsigned m_rows;
unsigned m_cols;
- int m_maxLength { -1 };
WrapMethod m_wrap { SoftWrap };
RefPtr<HTMLElement> m_placeholder;
mutable String m_value;
Modified: trunk/Source/WebCore/html/HTMLTextAreaElement.idl (205523 => 205524)
--- trunk/Source/WebCore/html/HTMLTextAreaElement.idl 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/HTMLTextAreaElement.idl 2016-09-07 00:00:12 UTC (rev 205524)
@@ -24,7 +24,8 @@
[Reflect] attribute DOMString dirName;
[Reflect] attribute boolean disabled;
readonly attribute HTMLFormElement form;
- [ImplementedAs=maxLengthForBindings, SetterRaisesException] attribute long maxLength;
+ [SetterRaisesException] attribute long minLength;
+ [SetterRaisesException] attribute long maxLength;
[Reflect] attribute DOMString name;
[Reflect] attribute DOMString placeholder;
[Reflect] attribute boolean readOnly;
Modified: trunk/Source/WebCore/html/HTMLTextFormControlElement.cpp (205523 => 205524)
--- trunk/Source/WebCore/html/HTMLTextFormControlElement.cpp 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/HTMLTextFormControlElement.cpp 2016-09-07 00:00:12 UTC (rev 205524)
@@ -760,14 +760,22 @@
return "ltr";
}
-void HTMLTextFormControlElement::setMaxLengthForBindings(int maxLength, ExceptionCode& ec)
+void HTMLTextFormControlElement::setMaxLength(int maxLength, ExceptionCode& ec)
{
- if (maxLength < 0)
+ if (maxLength < 0 || (m_minLength >= 0 && maxLength < m_minLength))
ec = INDEX_SIZE_ERR;
else
setIntegralAttribute(maxlengthAttr, maxLength);
}
+void HTMLTextFormControlElement::setMinLength(int minLength, ExceptionCode& ec)
+{
+ if (minLength < 0 || (m_maxLength >= 0 && minLength > m_maxLength))
+ ec = INDEX_SIZE_ERR;
+ else
+ setIntegralAttribute(minlengthAttr, minLength);
+}
+
void HTMLTextFormControlElement::adjustInnerTextStyle(const RenderStyle& parentStyle, RenderStyle& textBlockStyle) const
{
// The inner block, if present, always has its direction set to LTR,
Modified: trunk/Source/WebCore/html/HTMLTextFormControlElement.h (205523 => 205524)
--- trunk/Source/WebCore/html/HTMLTextFormControlElement.h 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/HTMLTextFormControlElement.h 2016-09-07 00:00:12 UTC (rev 205524)
@@ -40,7 +40,7 @@
class HTMLTextFormControlElement : public HTMLFormControlElementWithState {
public:
- // Common flag for HTMLInputElement::tooLong() and HTMLTextAreaElement::tooLong().
+ // Common flag for HTMLInputElement::tooLong() / tooShort() and HTMLTextAreaElement::tooLong() / tooShort().
enum NeedsToCheckDirtyFlag {CheckDirtyFlag, IgnoreDirtyFlag};
virtual ~HTMLTextFormControlElement();
@@ -48,7 +48,12 @@
void didEditInnerTextValue();
void forwardEvent(Event&);
- WEBCORE_EXPORT void setMaxLengthForBindings(int, ExceptionCode&);
+ long maxLength() const { return m_maxLength; }
+ WEBCORE_EXPORT void setMaxLength(int, ExceptionCode&);
+ void setMaxLength(int maxLength) { m_maxLength = maxLength; }
+ long minLength() const { return m_minLength; }
+ void setMinLength(int, ExceptionCode&);
+ void setMinLength(int minLength) { m_minLength = minLength; }
InsertionNotificationRequest insertedInto(ContainerNode&) override;
@@ -151,6 +156,9 @@
int m_cachedSelectionStart;
int m_cachedSelectionEnd;
+ int m_maxLength { -1 };
+ int m_minLength { -1 };
+
unsigned char m_cachedSelectionDirection : 2;
unsigned char m_lastChangeWasUserEdit : 1;
unsigned char m_isPlaceholderVisible : 1;
Modified: trunk/Source/WebCore/html/InputType.cpp (205523 => 205524)
--- trunk/Source/WebCore/html/InputType.cpp 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/InputType.cpp 2016-09-07 00:00:12 UTC (rev 205524)
@@ -412,6 +412,9 @@
if (patternMismatch(value))
return validationMessagePatternMismatchText();
+ if (element().tooShort())
+ return validationMessageTooShortText(numGraphemeClusters(value), element().minLength());
+
if (element().tooLong())
return validationMessageTooLongText(numGraphemeClusters(value), element().effectiveMaxLength());
Modified: trunk/Source/WebCore/html/TextFieldInputType.cpp (205523 => 205524)
--- trunk/Source/WebCore/html/TextFieldInputType.cpp 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/TextFieldInputType.cpp 2016-09-07 00:00:12 UTC (rev 205524)
@@ -456,7 +456,7 @@
// We use RenderTextControlSingleLine::text() instead of InputElement::value()
// because they can be mismatched by sanitizeValue() in
// HTMLInputElement::subtreeHasChanged() in some cases.
- String innerText = element().innerTextValue();
+ StringView innerText = element().innerTextValue();
unsigned oldLength = numGraphemeClusters(innerText);
// selectionLength represents the selection length of this text field to be
Modified: trunk/Source/WebCore/html/ValidityState.idl (205523 => 205524)
--- trunk/Source/WebCore/html/ValidityState.idl 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/html/ValidityState.idl 2016-09-07 00:00:12 UTC (rev 205524)
@@ -26,6 +26,7 @@
readonly attribute boolean valueMissing;
readonly attribute boolean typeMismatch;
readonly attribute boolean patternMismatch;
+ readonly attribute boolean tooShort;
readonly attribute boolean tooLong;
readonly attribute boolean rangeUnderflow;
readonly attribute boolean rangeOverflow;
Modified: trunk/Source/WebCore/platform/LocalizedStrings.cpp (205523 => 205524)
--- trunk/Source/WebCore/platform/LocalizedStrings.cpp 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/platform/LocalizedStrings.cpp 2016-09-07 00:00:12 UTC (rev 205524)
@@ -1058,6 +1058,11 @@
return WEB_UI_STRING("pattern mismatch", "Validation message for input form controls requiring a constrained value according to pattern");
}
+String validationMessageTooShortText(int, int)
+{
+ return WEB_UI_STRING("too short", "Validation message for form control elements with a value shorter than minimum allowed length");
+}
+
String validationMessageTooLongText(int, int)
{
return WEB_UI_STRING("too long", "Validation message for form control elements with a value longer than maximum allowed length");
Modified: trunk/Source/WebCore/platform/LocalizedStrings.h (205523 => 205524)
--- trunk/Source/WebCore/platform/LocalizedStrings.h 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/platform/LocalizedStrings.h 2016-09-07 00:00:12 UTC (rev 205524)
@@ -242,6 +242,7 @@
String validationMessageTypeMismatchForMultipleEmailText();
String validationMessageTypeMismatchForURLText();
String validationMessagePatternMismatchText();
+ String validationMessageTooShortText(int valueLength, int minLength);
String validationMessageTooLongText(int valueLength, int maxLength);
String validationMessageRangeUnderflowText(const String& minimum);
String validationMessageRangeOverflowText(const String& maximum);
Modified: trunk/Source/WebCore/platform/efl/LocalizedStringsEfl.cpp (205523 => 205524)
--- trunk/Source/WebCore/platform/efl/LocalizedStringsEfl.cpp 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/platform/efl/LocalizedStringsEfl.cpp 2016-09-07 00:00:12 UTC (rev 205524)
@@ -556,6 +556,11 @@
return String::fromUTF8("step mismatch");
}
+String validationMessageTooShortText(int, int)
+{
+ return String::fromUTF8("too short");
+}
+
String validationMessageTooLongText(int, int)
{
return String::fromUTF8("too long");
Modified: trunk/Source/WebCore/platform/gtk/LocalizedStringsGtk.cpp (205523 => 205524)
--- trunk/Source/WebCore/platform/gtk/LocalizedStringsGtk.cpp 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebCore/platform/gtk/LocalizedStringsGtk.cpp 2016-09-07 00:00:12 UTC (rev 205524)
@@ -753,6 +753,11 @@
return String::fromUTF8(_("pattern mismatch"));
}
+String validationMessageTooShortText(int, int)
+{
+ return String::fromUTF8(_("too short"));
+}
+
String validationMessageTooLongText(int, int)
{
return String::fromUTF8(_("too long"));
Modified: trunk/Source/WebKit/mac/ChangeLog (205523 => 205524)
--- trunk/Source/WebKit/mac/ChangeLog 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebKit/mac/ChangeLog 2016-09-07 00:00:12 UTC (rev 205524)
@@ -1,3 +1,19 @@
+2016-09-06 Chris Dumez <[email protected]>
+
+ Add support for input.minLength / textArea.minLength
+ https://bugs.webkit.org/show_bug.cgi?id=161644
+
+ Reviewed by Darin Adler.
+
+ Update ObjC bindings to reflect method renaming.
+
+ * DOM/DOMHTMLInputElement.mm:
+ (-[DOMHTMLInputElement maxLength]):
+ (-[DOMHTMLInputElement setMaxLength:]):
+ * DOM/DOMHTMLTextAreaElement.mm:
+ (-[DOMHTMLTextAreaElement maxLength]):
+ (-[DOMHTMLTextAreaElement setMaxLength:]):
+
2016-09-06 Dan Bernstein <[email protected]>
<rdar://problem/8064563> Ugly NSLog in DOMInternal.mm
Modified: trunk/Source/WebKit/mac/DOM/DOMHTMLInputElement.mm (205523 => 205524)
--- trunk/Source/WebKit/mac/DOM/DOMHTMLInputElement.mm 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebKit/mac/DOM/DOMHTMLInputElement.mm 2016-09-07 00:00:12 UTC (rev 205524)
@@ -275,7 +275,7 @@
- (int)maxLength
{
WebCore::JSMainThreadNullState state;
- return IMPL->maxLengthForBindings();
+ return IMPL->maxLength();
}
- (void)setMaxLength:(int)newMaxLength
@@ -282,7 +282,7 @@
{
WebCore::JSMainThreadNullState state;
WebCore::ExceptionCode ec = 0;
- IMPL->setMaxLengthForBindings(newMaxLength, ec);
+ IMPL->setMaxLength(newMaxLength, ec);
raiseOnDOMError(ec);
}
Modified: trunk/Source/WebKit/mac/DOM/DOMHTMLTextAreaElement.mm (205523 => 205524)
--- trunk/Source/WebKit/mac/DOM/DOMHTMLTextAreaElement.mm 2016-09-06 23:55:09 UTC (rev 205523)
+++ trunk/Source/WebKit/mac/DOM/DOMHTMLTextAreaElement.mm 2016-09-07 00:00:12 UTC (rev 205524)
@@ -100,7 +100,7 @@
- (int)maxLength
{
JSMainThreadNullState state;
- return unwrap(*self).maxLengthForBindings();
+ return unwrap(*self).maxLength();
}
- (void)setMaxLength:(int)newMaxLength
@@ -107,7 +107,7 @@
{
JSMainThreadNullState state;
ExceptionCode ec = 0;
- unwrap(*self).setMaxLengthForBindings(newMaxLength, ec);
+ unwrap(*self).setMaxLength(newMaxLength, ec);
raiseOnDOMError(ec);
}