Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(328)

Unified Diff: third_party/WebKit/LayoutTests/fast/events/inputevents/before-input-inputtype.html

Issue 2074423004: [InputEvent] Dispatch 'input' event for ContentEditable and typing on Input element (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tkent's review Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/fast/events/inputevents/before-input-inputtype.html
diff --git a/third_party/WebKit/LayoutTests/fast/events/inputevents/before-input-inputtype.html b/third_party/WebKit/LayoutTests/fast/events/inputevents/before-input-inputtype.html
deleted file mode 100644
index 478fa7a7767d33bc272220d0cc7bf2292174fd5b..0000000000000000000000000000000000000000
--- a/third_party/WebKit/LayoutTests/fast/events/inputevents/before-input-inputtype.html
+++ /dev/null
@@ -1,50 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<title>InputEvent: beforeinput inputType</title>
-<script src="../../../resources/testharness.js"></script>
-<script src="../../../resources/testharnessreport.js"></script>
-</head>
-<body>
-<input type="text" id="txt">
-<script>
-test(function() {
- var lastInputType = '';
- var txt = document.getElementById('txt');
- txt.addEventListener('beforeinput', function(event) {
- lastInputType = event.inputType;
- });
- if (!window.eventSender) {
- document.write('This test requires eventSender');
- } else {
- var kNoBeforeInputFired = 'noBeforeInputFired';
- function testKeyDownInputType(key, modifiers, inputType) {
- lastInputType = kNoBeforeInputFired;
- eventSender.keyDown(key, modifiers);
- assert_equals(lastInputType, inputType, `${modifiers.toString()}+${key} should produce inputType: ${inputType}`);
- }
-
- txt.focus();
- // Typing
- testKeyDownInputType('a', [], 'insertText');
- testKeyDownInputType('6', [], 'insertText');
- testKeyDownInputType('backspace', [], 'deleteContent');
- testKeyDownInputType('l', ['shiftKey'], 'insertText');
- testKeyDownInputType('w', ['shiftKey'], 'insertText');
-
- // Keyboard commands
- var isMacOS = (navigator.userAgent.indexOf('Mac OS X') != -1);
- if (!isMacOS) {
- // MacOS's eventSender does not work on hot keys other than arrows.
- testKeyDownInputType('z', ['ctrlKey'], 'undo');
- testKeyDownInputType('z', ['ctrlKey', 'shiftKey'], 'redo');
- }
- // Move command should not generate input events.
- testKeyDownInputType('leftArrow', [], kNoBeforeInputFired);
- testKeyDownInputType('leftArrow', ['shiftKey'], kNoBeforeInputFired);
- testKeyDownInputType('home', [], kNoBeforeInputFired);
- }
-}, 'Testing beforeinput inputType');
-</script>
-</body>
-</html>

Powered by Google App Engine
This is Rietveld 408576698