Title: [126554] trunk
- Revision
- 126554
- Author
- [email protected]
- Date
- 2012-08-24 01:39:03 -0700 (Fri, 24 Aug 2012)
Log Message
[Forms] Multiple fields time input UI should handle Delete key as Backspace key
https://bugs.webkit.org/show_bug.cgi?id=94902
Reviewed by Kent Tamura.
Source/WebCore:
This patch adds treating "Delete" key as same as "Backspace" key for
multiple fields time input UI. This patch affects ports which enable
both ENABLE_INPUT_TYPE_TIME and ENABLES_INPUT_TYPE_TIME_MULTIPLE_FIELDS.
No new tests. This patch adds a test case for "Delete" key to
fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events.html
* html/shadow/DateTimeFieldElement.cpp:
(WebCore::DateTimeFieldElement::defaultKeyboardEventHandler): Changed
condition _expression_ to check both Backspace(U+0008) key and
Delete(U+007F) key.
LayoutTests:
This patch adds a new test case for "Delete" key behavior for multiple
fields time input UI.
* fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events-expected.txt: Updated expectation.
* fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events.html: Added "Delete" key test case.
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (126553 => 126554)
--- trunk/LayoutTests/ChangeLog 2012-08-24 08:29:09 UTC (rev 126553)
+++ trunk/LayoutTests/ChangeLog 2012-08-24 08:39:03 UTC (rev 126554)
@@ -1,3 +1,16 @@
+2012-08-24 Yoshifumi Inoue <[email protected]>
+
+ [Forms] Multiple fields time input UI should handle Delete key as Backspace key
+ https://bugs.webkit.org/show_bug.cgi?id=94902
+
+ Reviewed by Kent Tamura.
+
+ This patch adds a new test case for "Delete" key behavior for multiple
+ fields time input UI.
+
+ * fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events-expected.txt: Updated expectation.
+ * fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events.html: Added "Delete" key test case.
+
2012-08-24 János Badics <[email protected]>
[Qt] Gardening after r126442. Skip a test because of missing shadow feature.
Modified: trunk/LayoutTests/fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events-expected.txt (126553 => 126554)
--- trunk/LayoutTests/fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events-expected.txt 2012-08-24 08:29:09 UTC (rev 126553)
+++ trunk/LayoutTests/fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events-expected.txt 2012-08-24 08:39:03 UTC (rev 126554)
@@ -28,6 +28,8 @@
PASS document.activeElement.id is "another"
== Backspace key ==
PASS input.value is ""
+== Delete key ==
+PASS input.value is ""
PASS successfullyParsed is true
TEST COMPLETE
Modified: trunk/LayoutTests/fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events.html (126553 => 126554)
--- trunk/LayoutTests/fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events.html 2012-08-24 08:29:09 UTC (rev 126553)
+++ trunk/LayoutTests/fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events.html 2012-08-24 08:39:03 UTC (rev 126554)
@@ -100,6 +100,10 @@
beginTest('Backspace key', '12:34');
keyDown("\b");
shouldBeEqualToString('input.value', '');
+
+beginTest('Delete key', '12:34');
+keyDown("delete");
+shouldBeEqualToString('input.value', '');
</script>
<script src=""
</body>
Modified: trunk/Source/WebCore/ChangeLog (126553 => 126554)
--- trunk/Source/WebCore/ChangeLog 2012-08-24 08:29:09 UTC (rev 126553)
+++ trunk/Source/WebCore/ChangeLog 2012-08-24 08:39:03 UTC (rev 126554)
@@ -1,3 +1,22 @@
+2012-08-24 Yoshifumi Inoue <[email protected]>
+
+ [Forms] Multiple fields time input UI should handle Delete key as Backspace key
+ https://bugs.webkit.org/show_bug.cgi?id=94902
+
+ Reviewed by Kent Tamura.
+
+ This patch adds treating "Delete" key as same as "Backspace" key for
+ multiple fields time input UI. This patch affects ports which enable
+ both ENABLE_INPUT_TYPE_TIME and ENABLES_INPUT_TYPE_TIME_MULTIPLE_FIELDS.
+
+ No new tests. This patch adds a test case for "Delete" key to
+ fast/forms/time-multiple-fields/time-multiple-fields-keyboard-events.html
+
+ * html/shadow/DateTimeFieldElement.cpp:
+ (WebCore::DateTimeFieldElement::defaultKeyboardEventHandler): Changed
+ condition _expression_ to check both Backspace(U+0008) key and
+ Delete(U+007F) key.
+
2012-08-24 Sheriff Bot <[email protected]>
Unreviewed, rolling out r126546.
Modified: trunk/Source/WebCore/html/shadow/DateTimeFieldElement.cpp (126553 => 126554)
--- trunk/Source/WebCore/html/shadow/DateTimeFieldElement.cpp 2012-08-24 08:29:09 UTC (rev 126553)
+++ trunk/Source/WebCore/html/shadow/DateTimeFieldElement.cpp 2012-08-24 08:39:03 UTC (rev 126554)
@@ -80,7 +80,7 @@
return;
}
- if (keyIdentifier == "U+0008") {
+ if (keyIdentifier == "U+0008" || keyIdentifier == "U+007F") {
keyboardEvent->setDefaultHandled();
setEmptyValue(DateComponents(), DispatchEvent);
return;
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes