Diff
Modified: trunk/LayoutTests/ChangeLog (241277 => 241278)
--- trunk/LayoutTests/ChangeLog 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/ChangeLog 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,3 +1,21 @@
+2019-02-11 Commit Queue <[email protected]>
+
+ Unreviewed, rolling out r241272 and r241276.
+ https://bugs.webkit.org/show_bug.cgi?id=194514
+
+ Broke the Apple Internal build and the fix requires human
+ intervention :( (Requested by dydz on #webkit).
+
+ Reverted changesets:
+
+ "[iOS] Mouse/Touch/Pointer events are missing modifier keys"
+ https://bugs.webkit.org/show_bug.cgi?id=191446
+ https://trac.webkit.org/changeset/241272
+
+ "Fix internal iOS build after r241272"
+ https://bugs.webkit.org/show_bug.cgi?id=191446
+ https://trac.webkit.org/changeset/241276
+
2019-02-11 Wenson Hsieh <[email protected]>
fast/forms/ios/force-gregorian-calendar-for-credit-card-expiry.html does not work on iPad
Modified: trunk/LayoutTests/fast/events/ios/key-events-meta-alt-combinations.html (241277 => 241278)
--- trunk/LayoutTests/fast/events/ios/key-events-meta-alt-combinations.html 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/fast/events/ios/key-events-meta-alt-combinations.html 2019-02-11 21:55:14 UTC (rev 241278)
@@ -2,12 +2,11 @@
<html>
<head>
<script src=""
-<script src=""
<script src=""
<script>
const modiferKeySubsetsToTest = computeSubsets(["metaKey", "altKey"]);
for (const k of keysExcludingDeadAndSkippedKeys) {
- for (const modifiers of computeSubsets(modifierKeys))
+ for (const modifiers of modiferKeySubsetsToTest)
tests.push(new KeyCommand(k, modifiers));
}
</script>
Modified: trunk/LayoutTests/fast/events/ios/resources/key-tester.js (241277 => 241278)
--- trunk/LayoutTests/fast/events/ios/resources/key-tester.js 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/fast/events/ios/resources/key-tester.js 2019-02-11 21:55:14 UTC (rev 241278)
@@ -53,6 +53,43 @@
return !!keyCommands.find((k) => areKeyCommandsEqual(k, command));
}
+// This algorithm runs in O(2^N).
+function computeSubsets(anArray)
+{
+ function compareByModifierOrder(a, b) {
+ if (a.length < b.length)
+ return -1;
+ if (a.length > b.length)
+ return 1;
+ for (let i = 0; i < a.length; ++i) {
+ let rankA = anArray.indexOf(a[i]);
+ let rankB = anArray.indexOf(b[i]);
+ if (rankA < rankB)
+ return -1;
+ if (rankA > rankB)
+ return 1;
+ }
+ return 0;
+ }
+ let result = [];
+ const numberOfNonEmptyPermutations = (1 << anArray.length) - 1;
+ // For each ordinal 1, 2, ... numberOfNonEmptyPermutations we look at its binary representation
+ // and generate a permutation that consists of the entries in anArray at the indices where there
+ // is a one bit in the binary representation. For example, suppose anArray = ["metaKey", "altKey", "ctrlKey"].
+ // To generate the 5th permutation we look at the binary representation of i = 5 => 0b101. And
+ // compute the permutation to be [ anArray[0], anArray[2] ] = [ "metaKey", "ctrlKey" ] because
+ // the 0th and 2nd bits are ones in the binary representation.
+ for (let i = 1; i <= numberOfNonEmptyPermutations; ++i) {
+ let temp = [];
+ for (let bitmask = i, j = 0; bitmask; bitmask = Math.floor(bitmask / 2), ++j) {
+ if (bitmask % 2)
+ temp.push(anArray[j]);
+ }
+ result.push(temp);
+ }
+ return result.sort(compareByModifierOrder);
+}
+
const keys = new Set("abcdefghijklmnopqrstuvwxyz0123456789-=[]\\;',./".split(""));
const deadKeys = new Set("`euin".split(""));
const keysExcludingDeadKeys = computeDifference(keys, deadKeys);
@@ -80,6 +117,7 @@
disallowedKeyCommands.push(new KeyCommand(i, ["metaKey"]));
const modifierKeys = ["metaKey", "altKey", "ctrlKey", "shiftKey"];
+const modiferKeySubsets = computeSubsets(modifierKeys);
let tests = [];
Deleted: trunk/LayoutTests/fast/events/resources/compute-subsets.js (241277 => 241278)
--- trunk/LayoutTests/fast/events/resources/compute-subsets.js 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/fast/events/resources/compute-subsets.js 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,36 +0,0 @@
-// This algorithm runs in O(2^N).
-function computeSubsets(anArray)
-{
- function compareByOriginalArrayOrder(a, b) {
- if (a.length < b.length)
- return -1;
- if (a.length > b.length)
- return 1;
- for (let i = 0; i < a.length; ++i) {
- let rankA = anArray.indexOf(a[i]);
- let rankB = anArray.indexOf(b[i]);
- if (rankA < rankB)
- return -1;
- if (rankA > rankB)
- return 1;
- }
- return 0;
- }
- let result = [];
- const numberOfNonEmptyPermutations = (1 << anArray.length) - 1;
- // For each ordinal 1, 2, ... numberOfNonEmptyPermutations we look at its binary representation
- // and generate a permutation that consists of the entries in anArray at the indices where there
- // is a one bit in the binary representation. For example, suppose anArray = ["metaKey", "altKey", "ctrlKey"].
- // To generate the 5th permutation we look at the binary representation of i = 5 => 0b101. And
- // compute the permutation to be [ anArray[0], anArray[2] ] = [ "metaKey", "ctrlKey" ] because
- // the 0th and 2nd bits are ones in the binary representation.
- for (let i = 1; i <= numberOfNonEmptyPermutations; ++i) {
- let temp = [];
- for (let bitmask = i, j = 0; bitmask; bitmask = Math.floor(bitmask / 2), ++j) {
- if (bitmask % 2)
- temp.push(anArray[j]);
- }
- result.push(temp);
- }
- return result.sort(compareByOriginalArrayOrder);
-}
Deleted: trunk/LayoutTests/fast/events/touch/ios/mouse-events-with-modifiers-expected.txt (241277 => 241278)
--- trunk/LayoutTests/fast/events/touch/ios/mouse-events-with-modifiers-expected.txt 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/fast/events/touch/ios/mouse-events-with-modifiers-expected.txt 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,78 +0,0 @@
-This logs DOM mousedown, mousemove, and mouseup events that are dispatched when single tapping an element while holding modifier keys. Must be run in WebKitTestRunner.
-
-
-Test Command + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: true, shiftKey: false
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: true, shiftKey: false
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: true, shiftKey: false
-
-Test Option + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: false, shiftKey: false
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: false, shiftKey: false
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: false, shiftKey: false
-
-Test Control + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: false, shiftKey: false
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: false, shiftKey: false
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: false, shiftKey: false
-
-Test Shift + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: false, shiftKey: true
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: false, shiftKey: true
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: false, shiftKey: true
-
-Test Command + Option + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: true, shiftKey: false
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: true, shiftKey: false
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: true, shiftKey: false
-
-Test Command + Control + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: true, shiftKey: false
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: true, shiftKey: false
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: true, shiftKey: false
-
-Test Command + Shift + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: true, shiftKey: true
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: true, shiftKey: true
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: true, shiftKey: true
-
-Test Option + Control + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: false, shiftKey: false
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: false, shiftKey: false
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: false, shiftKey: false
-
-Test Option + Shift + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: false, shiftKey: true
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: false, shiftKey: true
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: false, shiftKey: true
-
-Test Control + Shift + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: false, shiftKey: true
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: false, shiftKey: true
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: false, shiftKey: true
-
-Test Command + Option + Control + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: true, shiftKey: false
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: true, shiftKey: false
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: true, shiftKey: false
-
-Test Command + Option + Shift + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: true, shiftKey: true
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: true, shiftKey: true
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: true, shiftKey: true
-
-Test Command + Control + Shift + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: true, shiftKey: true
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: true, shiftKey: true
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: true, shiftKey: true
-
-Test Option + Control + Shift + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: false, shiftKey: true
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: false, shiftKey: true
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: false, shiftKey: true
-
-Test Command + Option + Control + Shift + Single Tap:
-type: mousemove, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: true, shiftKey: true
-type: mousedown, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: true, shiftKey: true
-type: mouseup, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: true, shiftKey: true
-
Deleted: trunk/LayoutTests/fast/events/touch/ios/mouse-events-with-modifiers.html (241277 => 241278)
--- trunk/LayoutTests/fast/events/touch/ios/mouse-events-with-modifiers.html 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/fast/events/touch/ios/mouse-events-with-modifiers.html 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,141 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<script src=""
-<script src=""
-<script>
-if (window.testRunner) {
- testRunner.dumpAsText();
- testRunner.waitUntilDone();
-}
-
-class TouchTest {
- constructor(elementToTouch, modifiers = [])
- {
- this.elementToTouch = elementToTouch;
- this.modifiers = modifiers;
- }
-
- toString()
- {
- return `{ ${this.elementToTouch}, [${this.modifiers}] }`;
- }
-
- run()
- {
- let centerX = this.elementToTouch.offsetLeft + this.elementToTouch.offsetWidth / 2;
- let centerY = this.elementToTouch.offsetTop + this.elementToTouch.offsetHeight / 2;
- return UIHelper.tapAt(centerX, centerY, this.modifiers);
- }
-}
-
-const modifierKeys = ["metaKey", "altKey", "ctrlKey", "shiftKey"];
-
-let currentTest;
-let tests = [];
-
-function handleMouseDown(event)
-{
- logMouseEvent(event);
-}
-
-function handleMouseMove(event)
-{
- logMouseEvent(event);
-}
-
-function handleMouseUp(event)
-{
- logMouseEvent(event);
- nextTouchPress();
-}
-
-function log(message)
-{
- document.getElementById("console").appendChild(document.createTextNode(message + "\n"));
-}
-
-function logMouseEvent(event)
-{
- let pieces = [];
- for (let propertyName of ["type", "x", "y", "offsetX", "offsetY", "button", "buttons", "screenX", "screenY", "clientX", "clientY", "altKey", "ctrlKey", "metaKey", "shiftKey"])
- pieces.push(`${propertyName}: ${event[propertyName]}`);
- log(pieces.join(", "));
-}
-
-const modifierDisplayNameMap = {
- "altKey": "Option",
- "ctrlKey": "Control",
- "metaKey": "Command",
- "shiftKey": "Shift",
- "capsLockKey": "Caps Lock",
-}
-
-function displayNameForTest(test)
-{
- let displayNamesOfModifiers = [];
- for (const modifier of test.modifiers)
- displayNamesOfModifiers.push(modifierDisplayNameMap[modifier]);
- let result = "";
- if (displayNamesOfModifiers.length)
- result += displayNamesOfModifiers.join(" + ") + " + ";
- result += "Single Tap";
- return result;
-}
-
-async function nextTouchPress()
-{
- if (!tests.length) {
- document.body.removeChild(document.getElementById("square"));
- if (window.testRunner)
- testRunner.notifyDone();
- return;
- }
- currentTest = tests.shift();
- log(`\nTest ${displayNameForTest(currentTest)}:`);
- if (window.testRunner)
- await currentTest.run();
-}
-
-function runTest()
-{
- if (!window.testRunner)
- return;
- nextTouchPress();
-}
-
-function setUp()
-{
- let square = document.getElementById("square");
- square.addEventListener("mousedown", handleMouseDown, true);
- square.addEventListener("mousemove", handleMouseMove, true);
- square.addEventListener("mouseup", handleMouseUp, true);
-
- for (const modifiers of computeSubsets(modifierKeys))
- tests.push(new TouchTest(square, modifiers));
-
- runTest();
-}
-
-window.addEventListener("load", setUp, true);
-</script>
-<style>
-#square {
- background-color: blue;
- color: white;
- height: 128px;
- width: 128px;
- display: flex;
- align-items: center;
- justify-content: center;
- user-select: none;
- -webkit-user-select: none;
-}
-</style>
-</head>
-<body>
-<p>This logs DOM mousedown, mousemove, and mouseup events that are dispatched when single tapping an element while holding modifier keys. Must be run in WebKitTestRunner.</p>
-<div id="square">Touch Me</div>
-<pre id="console"></pre>
-</body>
-</html>
Deleted: trunk/LayoutTests/fast/events/touch/ios/pointer-events-with-modifiers-expected.txt (241277 => 241278)
--- trunk/LayoutTests/fast/events/touch/ios/pointer-events-with-modifiers-expected.txt 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/fast/events/touch/ios/pointer-events-with-modifiers-expected.txt 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,63 +0,0 @@
-This logs DOM pointerdown and pointerup events that are dispatched when single tapping an element while holding modifier keys. Must be run in WebKitTestRunner.
-
-
-Test Command + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: true, shiftKey: false
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: true, shiftKey: false
-
-Test Option + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: false, shiftKey: false
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: false, shiftKey: false
-
-Test Control + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: false, shiftKey: false
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: false, shiftKey: false
-
-Test Shift + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: false, shiftKey: true
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: false, shiftKey: true
-
-Test Command + Option + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: true, shiftKey: false
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: true, shiftKey: false
-
-Test Command + Control + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: true, shiftKey: false
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: true, shiftKey: false
-
-Test Command + Shift + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: true, shiftKey: true
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: false, metaKey: true, shiftKey: true
-
-Test Option + Control + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: false, shiftKey: false
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: false, shiftKey: false
-
-Test Option + Shift + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: false, shiftKey: true
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: false, shiftKey: true
-
-Test Control + Shift + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: false, shiftKey: true
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: false, shiftKey: true
-
-Test Command + Option + Control + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: true, shiftKey: false
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: true, shiftKey: false
-
-Test Command + Option + Shift + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: true, shiftKey: true
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: false, metaKey: true, shiftKey: true
-
-Test Command + Control + Shift + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: true, shiftKey: true
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: false, ctrlKey: true, metaKey: true, shiftKey: true
-
-Test Option + Control + Shift + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: false, shiftKey: true
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: false, shiftKey: true
-
-Test Command + Option + Control + Shift + Single Tap:
-type: pointerdown, pointerType: touch, isPrimary: true, width: 40, height: 40, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: true, shiftKey: true
-type: pointerup, pointerType: touch, isPrimary: false, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 90, tiltY: 0, twist: 0, x: 72, y: 136, offsetX: 64, offsetY: 64, button: 0, buttons: 0, screenX: 72, screenY: 136, clientX: 72, clientY: 136, altKey: true, ctrlKey: true, metaKey: true, shiftKey: true
-
Deleted: trunk/LayoutTests/fast/events/touch/ios/pointer-events-with-modifiers.html (241277 => 241278)
--- trunk/LayoutTests/fast/events/touch/ios/pointer-events-with-modifiers.html 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/fast/events/touch/ios/pointer-events-with-modifiers.html 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,135 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<script src=""
-<script src=""
-<script>
-if (window.testRunner) {
- testRunner.dumpAsText();
- testRunner.waitUntilDone();
-}
-
-class TouchTest {
- constructor(elementToTouch, modifiers = [])
- {
- this.elementToTouch = elementToTouch;
- this.modifiers = modifiers;
- }
-
- toString()
- {
- return `{ ${this.elementToTouch}, [${this.modifiers}] }`;
- }
-
- run()
- {
- let centerX = this.elementToTouch.offsetLeft + this.elementToTouch.offsetWidth / 2;
- let centerY = this.elementToTouch.offsetTop + this.elementToTouch.offsetHeight / 2;
- return UIHelper.tapAt(centerX, centerY, this.modifiers);
- }
-}
-
-const modifierKeys = ["metaKey", "altKey", "ctrlKey", "shiftKey"];
-
-let currentTest;
-let tests = [];
-
-function handlePointerDown(event)
-{
- logPointerEvent(event);
-}
-
-function handlePointerUp(event)
-{
- logPointerEvent(event);
- nextTouchPress();
-}
-
-function log(message)
-{
- document.getElementById("console").appendChild(document.createTextNode(message + "\n"));
-}
-
-function logPointerEvent(event)
-{
- let pieces = [];
- for (let propertyName of ["type", "pointerType", "isPrimary", "width", "height", "pressure", "tangentialPressure", "tiltX", "tiltY", "twist", "x", "y", "offsetX", "offsetY", "button", "buttons", "screenX", "screenY", "clientX", "clientY", "altKey", "ctrlKey", "metaKey", "shiftKey"])
- pieces.push(`${propertyName}: ${event[propertyName]}`);
- log(pieces.join(", "));
-}
-
-const modifierDisplayNameMap = {
- "altKey": "Option",
- "ctrlKey": "Control",
- "metaKey": "Command",
- "shiftKey": "Shift",
- "capsLockKey": "Caps Lock",
-}
-
-function displayNameForTest(test)
-{
- let displayNamesOfModifiers = [];
- for (const modifier of test.modifiers)
- displayNamesOfModifiers.push(modifierDisplayNameMap[modifier]);
- let result = "";
- if (displayNamesOfModifiers.length)
- result += displayNamesOfModifiers.join(" + ") + " + ";
- result += "Single Tap";
- return result;
-}
-
-async function nextTouchPress()
-{
- if (!tests.length) {
- document.body.removeChild(document.getElementById("square"));
- if (window.testRunner)
- testRunner.notifyDone();
- return;
- }
- currentTest = tests.shift();
- log(`\nTest ${displayNameForTest(currentTest)}:`);
- if (window.testRunner)
- await currentTest.run();
-}
-
-function runTest()
-{
- if (!window.testRunner)
- return;
- nextTouchPress();
-}
-
-function setUp()
-{
- let square = document.getElementById("square");
- square.addEventListener("pointerdown", handlePointerDown, true);
- square.addEventListener("pointerup", handlePointerUp, true);
-
- for (const modifiers of computeSubsets(modifierKeys))
- tests.push(new TouchTest(square, modifiers));
-
- runTest();
-}
-
-window.addEventListener("load", setUp, true);
-</script>
-<style>
-#square {
- background-color: blue;
- color: white;
- height: 128px;
- width: 128px;
- display: flex;
- align-items: center;
- justify-content: center;
- user-select: none;
- -webkit-user-select: none;
-}
-</style>
-</head>
-<body>
-<p>This logs DOM pointerdown and pointerup events that are dispatched when single tapping an element while holding modifier keys. Must be run in WebKitTestRunner.</p>
-<div id="square">Touch Me</div>
-<pre id="console"></pre>
-</body>
-</html>
Deleted: trunk/LayoutTests/fast/events/touch/ios/touch-events-with-modifiers-expected.txt (241277 => 241278)
--- trunk/LayoutTests/fast/events/touch/ios/touch-events-with-modifiers-expected.txt 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/fast/events/touch/ios/touch-events-with-modifiers-expected.txt 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,123 +0,0 @@
-This logs DOM touchdown and touchup events that are dispatched when single tapping an element while holding modifier keys with and without a stylus. Must be run in WebKitTestRunner.
-
-
-Test Command + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: false, metaKey: true, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: false, metaKey: true, shiftKey: false
-
-Test Option + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: false, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: false, shiftKey: false
-
-Test Control + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: false, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: false, shiftKey: false
-
-Test Shift + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: false, metaKey: false, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: false, metaKey: false, shiftKey: true
-
-Test Command + Option + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: true, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: true, shiftKey: false
-
-Test Command + Control + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: true, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: true, shiftKey: false
-
-Test Command + Shift + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: false, metaKey: true, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: false, metaKey: true, shiftKey: true
-
-Test Option + Control + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: false, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: false, shiftKey: false
-
-Test Option + Shift + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: false, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: false, shiftKey: true
-
-Test Control + Shift + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: false, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: false, shiftKey: true
-
-Test Command + Option + Control + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: true, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: true, shiftKey: false
-
-Test Command + Option + Shift + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: true, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: true, shiftKey: true
-
-Test Command + Control + Shift + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: true, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: true, shiftKey: true
-
-Test Option + Control + Shift + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: false, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: false, shiftKey: true
-
-Test Command + Option + Control + Shift + Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: true, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: true, shiftKey: true
-
-Test Command + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: false, metaKey: true, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: false, metaKey: true, shiftKey: false
-
-Test Option + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: false, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: false, shiftKey: false
-
-Test Control + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: false, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: false, shiftKey: false
-
-Test Shift + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: false, metaKey: false, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: false, metaKey: false, shiftKey: true
-
-Test Command + Option + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: true, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: true, shiftKey: false
-
-Test Command + Control + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: true, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: true, shiftKey: false
-
-Test Command + Shift + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: false, metaKey: true, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: false, metaKey: true, shiftKey: true
-
-Test Option + Control + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: false, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: false, shiftKey: false
-
-Test Option + Shift + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: false, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: false, shiftKey: true
-
-Test Control + Shift + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: false, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: false, shiftKey: true
-
-Test Command + Option + Control + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: true, shiftKey: false
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: true, shiftKey: false
-
-Test Command + Option + Shift + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: true, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: false, metaKey: true, shiftKey: true
-
-Test Command + Control + Shift + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: true, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: false, ctrlKey: true, metaKey: true, shiftKey: true
-
-Test Option + Control + Shift + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: false, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: false, shiftKey: true
-
-Test Command + Option + Control + Shift + Stylus Single Tap:
-type: touchstart, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: true, shiftKey: true
-type: touchend, pageX: 72, pageX: 72, scale: 1, rotation: 0, altKey: true, ctrlKey: true, metaKey: true, shiftKey: true
-
Deleted: trunk/LayoutTests/fast/events/touch/ios/touch-events-with-modifiers.html (241277 => 241278)
--- trunk/LayoutTests/fast/events/touch/ios/touch-events-with-modifiers.html 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/fast/events/touch/ios/touch-events-with-modifiers.html 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,150 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<script src=""
-<script src=""
-<script>
-if (window.testRunner) {
- testRunner.dumpAsText();
- testRunner.waitUntilDone();
-}
-
-// FIXME: Add support for testing force touch.
-const TouchType = {
- "SingleTap": "SingleTap",
- "StylusSingleTap": "StylusSingleTap",
-};
-const TouchTypeDisplayName = {
- "SingleTap": "Single Tap",
- "StylusSingleTap": "Stylus Single Tap",
-};
-
-class TouchTest {
- constructor(elementToTouch, touchType, modifiers = [])
- {
- this.elementToTouch = elementToTouch;
- this.touchType = touchType;
- this.modifiers = modifiers;
- }
-
- toString()
- {
- return `{ ${this.touchType}, ${this.elementToTouch}, [${this.modifiers}] }`;
- }
-
- run()
- {
- let centerX = this.elementToTouch.offsetLeft + this.elementToTouch.offsetWidth / 2;
- let centerY = this.elementToTouch.offsetTop + this.elementToTouch.offsetHeight / 2;
- if (this.touchType === TouchType.SingleTap)
- return UIHelper.tapAt(centerX, centerY, this.modifiers);
- return UIHelper.stylusTapAt(centerX, centerY, this.modifiers);
- }
-}
-
-const modifierKeys = ["metaKey", "altKey", "ctrlKey", "shiftKey"];
-
-let currentTest;
-let tests = [];
-
-function handleTouchDown(event)
-{
- logTouchEvent(event);
-}
-
-function handleTouchUp(event)
-{
- logTouchEvent(event);
- nextTouchPress();
-}
-
-function log(message)
-{
- document.getElementById("console").appendChild(document.createTextNode(message + "\n"));
-}
-
-function logTouchEvent(event)
-{
- let pieces = [];
- for (let propertyName of ["type", "pageX", "pageX", "scale", "rotation", "altKey", "ctrlKey", "metaKey", "shiftKey"])
- pieces.push(`${propertyName}: ${event[propertyName]}`);
- log(pieces.join(", "));
-}
-
-const modifierDisplayNameMap = {
- "altKey": "Option",
- "ctrlKey": "Control",
- "metaKey": "Command",
- "shiftKey": "Shift",
- "capsLockKey": "Caps Lock",
-}
-
-function displayNameForTest(test)
-{
- let displayNamesOfModifiers = [];
- for (const modifier of test.modifiers)
- displayNamesOfModifiers.push(modifierDisplayNameMap[modifier]);
- let result = "";
- if (displayNamesOfModifiers.length)
- result += displayNamesOfModifiers.join(" + ") + " + ";
- result += TouchTypeDisplayName[test.touchType];
- return result;
-}
-
-async function nextTouchPress()
-{
- if (!tests.length) {
- document.body.removeChild(document.getElementById("square"));
- if (window.testRunner)
- testRunner.notifyDone();
- return;
- }
- currentTest = tests.shift();
- log(`\nTest ${displayNameForTest(currentTest)}:`);
- if (window.testRunner)
- await currentTest.run();
-}
-
-function runTest()
-{
- if (!window.testRunner)
- return;
- nextTouchPress();
-}
-
-function setUp()
-{
- let square = document.getElementById("square");
- square.addEventListener("touchstart", handleTouchDown, true);
- square.addEventListener("touchend", handleTouchUp, true);
-
- for (const touchType in TouchType) {
- for (const modifiers of computeSubsets(modifierKeys))
- tests.push(new TouchTest(square, touchType, modifiers));
- }
-
- runTest();
-}
-
-window.addEventListener("load", setUp, true);
-</script>
-<style>
-#square {
- background-color: blue;
- color: white;
- height: 128px;
- width: 128px;
- display: flex;
- align-items: center;
- justify-content: center;
- user-select: none;
- -webkit-user-select: none;
-}
-</style>
-</head>
-<body>
-<p>This logs DOM touchdown and touchup events that are dispatched when single tapping an element while holding modifier keys with and without a stylus. Must be run in WebKitTestRunner.</p>
-<div id="square">Touch Me</div>
-<pre id="console"></pre>
-</body>
-</html>
Modified: trunk/LayoutTests/http/tests/adClickAttribution/anchor-tag-attributes-validation-expected.txt (241277 => 241278)
--- trunk/LayoutTests/http/tests/adClickAttribution/anchor-tag-attributes-validation-expected.txt 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/http/tests/adClickAttribution/anchor-tag-attributes-validation-expected.txt 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,13 +1,13 @@
-CONSOLE MESSAGE: line 108: adcampaignid must have a non-negative value less than 64 for Ad Click Attribution.
-CONSOLE MESSAGE: line 108: adcampaignid must have a non-negative value less than 64 for Ad Click Attribution.
-CONSOLE MESSAGE: line 108: adcampaignid can not be converted to a non-negative integer which is required for Ad Click Attribution.
-CONSOLE MESSAGE: line 108: adcampaignid can not be converted to a non-negative integer which is required for Ad Click Attribution.
-CONSOLE MESSAGE: line 108: adcampaignid can not be converted to a non-negative integer which is required for Ad Click Attribution.
-CONSOLE MESSAGE: line 108: adddestination could not be converted to a valid HTTP-family URL.
-CONSOLE MESSAGE: line 108: adddestination could not be converted to a valid HTTP-family URL.
-CONSOLE MESSAGE: line 108: adddestination could not be converted to a valid HTTP-family URL.
-CONSOLE MESSAGE: line 108: Both adcampaignid and addestination need to be set for Ad Click Attribution to work.
-CONSOLE MESSAGE: line 108: Both adcampaignid and addestination need to be set for Ad Click Attribution to work.
+CONSOLE MESSAGE: line 107: adcampaignid must have a non-negative value less than 64 for Ad Click Attribution.
+CONSOLE MESSAGE: line 107: adcampaignid must have a non-negative value less than 64 for Ad Click Attribution.
+CONSOLE MESSAGE: line 107: adcampaignid can not be converted to a non-negative integer which is required for Ad Click Attribution.
+CONSOLE MESSAGE: line 107: adcampaignid can not be converted to a non-negative integer which is required for Ad Click Attribution.
+CONSOLE MESSAGE: line 107: adcampaignid can not be converted to a non-negative integer which is required for Ad Click Attribution.
+CONSOLE MESSAGE: line 107: adddestination could not be converted to a valid HTTP-family URL.
+CONSOLE MESSAGE: line 107: adddestination could not be converted to a valid HTTP-family URL.
+CONSOLE MESSAGE: line 107: adddestination could not be converted to a valid HTTP-family URL.
+CONSOLE MESSAGE: line 107: Both adcampaignid and addestination need to be set for Ad Click Attribution to work.
+CONSOLE MESSAGE: line 107: Both adcampaignid and addestination need to be set for Ad Click Attribution to work.
Test for validity of ad click attribution attributes on anchor tags.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
Modified: trunk/LayoutTests/http/tests/security/anchor-download-block-crossorigin-expected.txt (241277 => 241278)
--- trunk/LayoutTests/http/tests/security/anchor-download-block-crossorigin-expected.txt 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/http/tests/security/anchor-download-block-crossorigin-expected.txt 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,4 +1,4 @@
-CONSOLE MESSAGE: line 108: The download attribute on anchor was ignored because its href URL has a different security origin.
+CONSOLE MESSAGE: line 107: The download attribute on anchor was ignored because its href URL has a different security origin.
Tests that the download attribute is ignored if the link is cross origin.
It should navigate the subframe instead of downloading the file.
Modified: trunk/LayoutTests/platform/ios/TestExpectations (241277 => 241278)
--- trunk/LayoutTests/platform/ios/TestExpectations 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/platform/ios/TestExpectations 2019-02-11 21:55:14 UTC (rev 241278)
@@ -3210,8 +3210,3 @@
webkit.org/b/153337 pageoverlay/overlay-installation.html [ Pass Failure ]
webkit.org/b/153337 pageoverlay/overlay-large-document-scrolled.html [ Pass Failure ]
webkit.org/b/153337 pageoverlay/overlay-large-document.html [ Pass Failure ]
-
-# FIXME: Unskip the following test once we have the fix for <rdar://problem/45970040>.
-fast/events/touch/ios/touch-events-with-modifiers.html [ Skip ]
-fast/events/touch/ios/mouse-events-with-modifiers.html [ Skip ]
-fast/events/touch/ios/pointer-events-with-modifiers.html [ Skip ]
Modified: trunk/LayoutTests/resources/ui-helper.js (241277 => 241278)
--- trunk/LayoutTests/resources/ui-helper.js 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/LayoutTests/resources/ui-helper.js 2019-02-11 21:55:14 UTC (rev 241278)
@@ -29,12 +29,11 @@
eventSender.mouseUp();
}
- static tapAt(x, y, modifiers=[])
+ static tapAt(x, y)
{
console.assert(this.isIOS());
if (!this.isWebKit2()) {
- console.assert(!modifiers || !modifiers.length);
eventSender.addTouchPoint(x, y);
eventSender.touchStart();
eventSender.releaseTouchPoint(0);
@@ -44,7 +43,7 @@
return new Promise((resolve) => {
testRunner.runUIScript(`
- uiController.singleTapAtPointWithModifiers(${x}, ${y}, ${JSON.stringify(modifiers)}, function() {
+ uiController.singleTapAtPoint(${x}, ${y}, function() {
uiController.uiScriptComplete();
});`, resolve);
});
@@ -566,7 +565,7 @@
return new Promise(resolve => testRunner.runUIScript(`uiController.drawSquareInEditableImage()`, resolve));
}
- static stylusTapAt(x, y, modifiers=[])
+ static stylusTapAt(x, y)
{
if (!this.isWebKit2())
return Promise.resolve();
@@ -573,7 +572,7 @@
return new Promise((resolve) => {
testRunner.runUIScript(`
- uiController.stylusTapAtPointWithModifiers(${x}, ${y}, 2, 1, 0.5, ${JSON.stringify(modifiers)}, function() {
+ uiController.stylusTapAtPoint(${x}, ${y}, 2, 1, 0.5, function() {
uiController.uiScriptComplete();
});`, resolve);
});
Modified: trunk/Source/WebCore/ChangeLog (241277 => 241278)
--- trunk/Source/WebCore/ChangeLog 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebCore/ChangeLog 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,3 +1,21 @@
+2019-02-11 Commit Queue <[email protected]>
+
+ Unreviewed, rolling out r241272 and r241276.
+ https://bugs.webkit.org/show_bug.cgi?id=194514
+
+ Broke the Apple Internal build and the fix requires human
+ intervention :( (Requested by dydz on #webkit).
+
+ Reverted changesets:
+
+ "[iOS] Mouse/Touch/Pointer events are missing modifier keys"
+ https://bugs.webkit.org/show_bug.cgi?id=191446
+ https://trac.webkit.org/changeset/241272
+
+ "Fix internal iOS build after r241272"
+ https://bugs.webkit.org/show_bug.cgi?id=191446
+ https://trac.webkit.org/changeset/241276
+
2019-02-11 Alex Christensen <[email protected]>
Stop using setDefersLoading from WebCore
Modified: trunk/Source/WebCore/platform/ios/PlatformEventFactoryIOS.mm (241277 => 241278)
--- trunk/Source/WebCore/platform/ios/PlatformEventFactoryIOS.mm 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebCore/platform/ios/PlatformEventFactoryIOS.mm 2019-02-11 21:55:14 UTC (rev 241278)
@@ -95,7 +95,6 @@
m_globalPosition = globalPointForEvent(event);
m_button = LeftButton; // This has always been the LeftButton on iOS.
m_clickCount = 1; // This has always been 1 on iOS.
- m_modifiers = modifiersForEvent(event);
}
};
Modified: trunk/Source/WebCore/platform/ios/WebEvent.h (241277 => 241278)
--- trunk/Source/WebCore/platform/ios/WebEvent.h 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebCore/platform/ios/WebEvent.h 2019-02-11 21:55:14 UTC (rev 241278)
@@ -139,13 +139,10 @@
BOOL _wasHandled;
}
-// Deprecated. Remove once UIKit adopts -initWithMouseEventType taking modifiers.
- (WebEvent *)initWithMouseEventType:(WebEventType)type
timeStamp:(CFTimeInterval)timeStamp
location:(CGPoint)point;
-- (WebEvent *)initWithMouseEventType:(WebEventType)type timeStamp:(CFTimeInterval)timeStamp location:(CGPoint)point modifiers:(WebEventFlags)modifiers;
-
- (WebEvent *)initWithScrollWheelEventWithTimeStamp:(CFTimeInterval)timeStamp
location:(CGPoint)point
deltaX:(float)deltaX
Modified: trunk/Source/WebCore/platform/ios/WebEvent.mm (241277 => 241278)
--- trunk/Source/WebCore/platform/ios/WebEvent.mm 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebCore/platform/ios/WebEvent.mm 2019-02-11 21:55:14 UTC (rev 241278)
@@ -49,20 +49,19 @@
@synthesize timestamp = _timestamp;
@synthesize wasHandled = _wasHandled;
-- (WebEvent *)initWithMouseEventType:(WebEventType)type timeStamp:(CFTimeInterval)timeStamp location:(CGPoint)point
+- (WebEvent *)initWithMouseEventType:(WebEventType)type
+ timeStamp:(CFTimeInterval)timeStamp
+ location:(CGPoint)point
{
- return [self initWithMouseEventType:type timeStamp:timeStamp location:point modifiers:0];
-}
-
-- (WebEvent *)initWithMouseEventType:(WebEventType)type timeStamp:(CFTimeInterval)timeStamp location:(CGPoint)point modifiers:(WebEventFlags)modifiers
-{
self = [super init];
if (!self)
return nil;
+
_type = type;
_timestamp = timeStamp;
+
_locationInWindow = point;
- _modifierFlags = modifiers;
+
return self;
}
Modified: trunk/Source/WebKit/ChangeLog (241277 => 241278)
--- trunk/Source/WebKit/ChangeLog 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/ChangeLog 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,3 +1,21 @@
+2019-02-11 Commit Queue <[email protected]>
+
+ Unreviewed, rolling out r241272 and r241276.
+ https://bugs.webkit.org/show_bug.cgi?id=194514
+
+ Broke the Apple Internal build and the fix requires human
+ intervention :( (Requested by dydz on #webkit).
+
+ Reverted changesets:
+
+ "[iOS] Mouse/Touch/Pointer events are missing modifier keys"
+ https://bugs.webkit.org/show_bug.cgi?id=191446
+ https://trac.webkit.org/changeset/241272
+
+ "Fix internal iOS build after r241272"
+ https://bugs.webkit.org/show_bug.cgi?id=191446
+ https://trac.webkit.org/changeset/241276
+
2019-02-11 Alex Christensen <[email protected]>
Fix internal iOS build after r241272
Modified: trunk/Source/WebKit/Platform/spi/ios/UIKitSPI.h (241277 => 241278)
--- trunk/Source/WebKit/Platform/spi/ios/UIKitSPI.h 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/Platform/spi/ios/UIKitSPI.h 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1032,10 +1032,6 @@
#endif // USE(APPLE_INTERNAL_SDK)
-@interface UIGestureRecognizer ()
-@property (nonatomic, readonly, getter=_modifierFlags) UIKeyModifierFlags modifierFlags;
-@end
-
// FIXME: <rdar://problem/47714562>
@interface UIWebTouchEventsGestureRecognizer (Staging_47634092)
@property (nonatomic, readonly) NSMapTable<NSNumber *, UITouch *> *activeTouchesByIdentifier;
Modified: trunk/Source/WebKit/Shared/NativeWebTouchEvent.h (241277 => 241278)
--- trunk/Source/WebKit/Shared/NativeWebTouchEvent.h 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/Shared/NativeWebTouchEvent.h 2019-02-11 21:55:14 UTC (rev 241278)
@@ -23,17 +23,15 @@
* THE POSSIBILITY OF SUCH DAMAGE.
*/
-#pragma once
+#ifndef NativeWebTouchEvent_h
+#define NativeWebTouchEvent_h
+#if ENABLE(TOUCH_EVENTS)
+
#include "WebEvent.h"
-#if ENABLE(TOUCH_EVENTS)
-
#if PLATFORM(IOS_FAMILY)
-#if defined(__OBJC__)
-#include <UIKit/UIKit.h>
struct _UIWebTouchEvent;
-#endif
#elif PLATFORM(GTK)
#include <WebCore/GUniquePtrGtk.h>
#elif USE(LIBWPE)
@@ -40,18 +38,12 @@
#include <wpe/wpe.h>
#endif
-#endif // ENABLE(TOUCH_EVENTS)
-
namespace WebKit {
-#if ENABLE(TOUCH_EVENTS)
-
class NativeWebTouchEvent : public WebTouchEvent {
public:
#if PLATFORM(IOS_FAMILY)
-#if defined(__OBJC__)
- explicit NativeWebTouchEvent(const _UIWebTouchEvent*, UIKeyModifierFlags);
-#endif
+ explicit NativeWebTouchEvent(const _UIWebTouchEvent*);
#elif PLATFORM(GTK)
NativeWebTouchEvent(GdkEvent*, Vector<WebPlatformTouchPoint>&&);
NativeWebTouchEvent(const NativeWebTouchEvent&);
@@ -64,7 +56,7 @@
#endif
private:
-#if PLATFORM(IOS_FAMILY) && defined(__OBJC__)
+#if PLATFORM(IOS_FAMILY)
Vector<WebPlatformTouchPoint> extractWebTouchPoint(const _UIWebTouchEvent*);
#endif
@@ -75,10 +67,8 @@
#endif
};
+} // namespace WebKit
+
#endif // ENABLE(TOUCH_EVENTS)
-#if PLATFORM(IOS_FAMILY) && defined(__OBJC__)
-OptionSet<WebEvent::Modifier> webEventModifierFlags(UIKeyModifierFlags);
-#endif
-
-} // namespace WebKit
+#endif // NativeWebTouchEvent_h
Modified: trunk/Source/WebKit/Shared/ios/NativeWebTouchEventIOS.mm (241277 => 241278)
--- trunk/Source/WebKit/Shared/ios/NativeWebTouchEventIOS.mm 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/Shared/ios/NativeWebTouchEventIOS.mm 2019-02-11 21:55:14 UTC (rev 241278)
@@ -26,9 +26,10 @@
#import "config.h"
#import "NativeWebTouchEvent.h"
-#if PLATFORM(IOS_FAMILY)
+#if PLATFORM(IOS_FAMILY) && ENABLE(TOUCH_EVENTS)
#import "UIKitSPI.h"
+#import "WebEvent.h"
#import <UIKit/UITouch.h>
#import <WebCore/IntPoint.h>
#import <WebCore/WAKAppKitStubs.h>
@@ -35,8 +36,6 @@
namespace WebKit {
-#if ENABLE(TOUCH_EVENTS)
-
static inline WebEvent::Type webEventTypeForUIWebTouchEventType(UIWebTouchEventType type)
{
switch (type) {
@@ -118,10 +117,10 @@
return touchPointList;
}
-NativeWebTouchEvent::NativeWebTouchEvent(const _UIWebTouchEvent* event, UIKeyModifierFlags flags)
+NativeWebTouchEvent::NativeWebTouchEvent(const _UIWebTouchEvent* event)
: WebTouchEvent(
webEventTypeForUIWebTouchEventType(event->type),
- webEventModifierFlags(flags),
+ OptionSet<Modifier> { },
WallTime::fromRawSeconds(event->timestamp),
extractWebTouchPoint(event),
positionForCGPoint(event->locationInDocumentCoordinates),
@@ -136,24 +135,6 @@
{
}
-#endif // ENABLE(TOUCH_EVENTS)
-
-OptionSet<WebEvent::Modifier> webEventModifierFlags(UIKeyModifierFlags flags)
-{
- OptionSet<WebEvent::Modifier> modifiers;
- if (flags & UIKeyModifierShift)
- modifiers.add(WebEvent::Modifier::ShiftKey);
- if (flags & UIKeyModifierControl)
- modifiers.add(WebEvent::Modifier::ControlKey);
- if (flags & UIKeyModifierAlternate)
- modifiers.add(WebEvent::Modifier::AltKey);
- if (flags & UIKeyModifierCommand)
- modifiers.add(WebEvent::Modifier::MetaKey);
- if (flags & UIKeyModifierAlphaShift)
- modifiers.add(WebEvent::Modifier::CapsLockKey);
- return modifiers;
-}
-
} // namespace WebKit
-#endif // PLATFORM(IOS_FAMILY)
+#endif // PLATFORM(IOS_FAMILY) && ENABLE(TOUCH_EVENTS)
Modified: trunk/Source/WebKit/Shared/ios/WebIOSEventFactory.h (241277 => 241278)
--- trunk/Source/WebKit/Shared/ios/WebIOSEventFactory.h 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/Shared/ios/WebIOSEventFactory.h 2019-02-11 21:55:14 UTC (rev 241278)
@@ -23,12 +23,12 @@
* THE POSSIBILITY OF SUCH DAMAGE.
*/
-#pragma once
+#ifndef WebIOSEventFactory_h
+#define WebIOSEventFactory_h
#if PLATFORM(IOS_FAMILY)
#import "WebEvent.h"
-#import <UIKit/UIKit.h>
#import <WebCore/WebEvent.h>
class WebIOSEventFactory {
@@ -35,8 +35,8 @@
public:
static WebKit::WebKeyboardEvent createWebKeyboardEvent(::WebEvent *);
static WebKit::WebMouseEvent createWebMouseEvent(::WebEvent *);
-
- static UIKeyModifierFlags toUIKeyModifierFlags(OptionSet<WebKit::WebEvent::Modifier>);
};
#endif // PLATFORM(IOS_FAMILY)
+
+#endif // WebIOSEventFactory_h
Modified: trunk/Source/WebKit/Shared/ios/WebIOSEventFactory.mm (241277 => 241278)
--- trunk/Source/WebKit/Shared/ios/WebIOSEventFactory.mm 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/Shared/ios/WebIOSEventFactory.mm 2019-02-11 21:55:14 UTC (rev 241278)
@@ -31,22 +31,6 @@
#import <WebCore/KeyEventCodesIOS.h>
#import <WebCore/PlatformEventFactoryIOS.h>
-UIKeyModifierFlags WebIOSEventFactory::toUIKeyModifierFlags(OptionSet<WebKit::WebEvent::Modifier> modifiers)
-{
- UIKeyModifierFlags modifierFlags = 0;
- if (modifiers.contains(WebKit::WebEvent::Modifier::ShiftKey))
- modifierFlags |= UIKeyModifierShift;
- if (modifiers.contains(WebKit::WebEvent::Modifier::ControlKey))
- modifierFlags |= UIKeyModifierControl;
- if (modifiers.contains(WebKit::WebEvent::Modifier::AltKey))
- modifierFlags |= UIKeyModifierAlternate;
- if (modifiers.contains(WebKit::WebEvent::Modifier::MetaKey))
- modifierFlags |= UIKeyModifierCommand;
- if (modifiers.contains(WebKit::WebEvent::Modifier::CapsLockKey))
- modifierFlags |= UIKeyModifierAlphaShift;
- return modifierFlags;
-}
-
static OptionSet<WebKit::WebEvent::Modifier> modifiersForEvent(::WebEvent *event)
{
OptionSet<WebKit::WebEvent::Modifier> modifiers;
Modified: trunk/Source/WebKit/UIProcess/API/Cocoa/WKNavigationAction.mm (241277 => 241278)
--- trunk/Source/WebKit/UIProcess/API/Cocoa/WKNavigationAction.mm 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/UIProcess/API/Cocoa/WKNavigationAction.mm 2019-02-11 21:55:14 UTC (rev 241278)
@@ -36,10 +36,6 @@
#import <WebCore/FloatPoint.h>
#import <wtf/RetainPtr.h>
-#if PLATFORM(IOS_FAMILY)
-#import "WebIOSEventFactory.h"
-#endif
-
@implementation WKNavigationAction
static WKNavigationType toWKNavigationType(WebCore::NavigationType navigationType)
@@ -131,7 +127,6 @@
#endif
#if PLATFORM(MAC)
-
- (NSEventModifierFlags)modifierFlags
{
return WebKit::WebEventFactory::toNSEventModifierFlags(_navigationAction->modifiers());
@@ -141,14 +136,6 @@
{
return WebKit::WebEventFactory::toNSButtonNumber(_navigationAction->mouseButton());
}
-
-#else
-
-- (UIKeyModifierFlags)modifierFlags
-{
- return WebIOSEventFactory::toUIKeyModifierFlags(_navigationAction->modifiers());
-}
-
#endif
#pragma mark WKObject protocol implementation
Modified: trunk/Source/WebKit/UIProcess/API/Cocoa/WKNavigationActionPrivate.h (241277 => 241278)
--- trunk/Source/WebKit/UIProcess/API/Cocoa/WKNavigationActionPrivate.h 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/UIProcess/API/Cocoa/WKNavigationActionPrivate.h 2019-02-11 21:55:14 UTC (rev 241278)
@@ -31,8 +31,6 @@
@class _WKUserInitiatedAction;
#if TARGET_OS_IPHONE
-#include <UIKit/UIKit.h>
-
typedef NS_ENUM(NSInteger, WKSyntheticClickType) {
WKSyntheticClickTypeNoTap,
WKSyntheticClickTypeOneFingerTap,
@@ -55,8 +53,6 @@
#if TARGET_OS_IPHONE
@property (nonatomic, readonly) WKSyntheticClickType _syntheticClickType WK_API_AVAILABLE(ios(10.0));
@property (nonatomic, readonly) CGPoint _clickLocationInRootViewCoordinates WK_API_AVAILABLE(ios(11.0));
-
-@property (nonatomic, readonly) UIKeyModifierFlags modifierFlags WK_API_AVAILABLE(ios(WK_IOS_TBA));
#endif
@property (nonatomic, readonly) BOOL _isRedirect WK_API_AVAILABLE(macosx(10.13), ios(11.0));
Modified: trunk/Source/WebKit/UIProcess/WebPageProxy.h (241277 => 241278)
--- trunk/Source/WebKit/UIProcess/WebPageProxy.h 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/UIProcess/WebPageProxy.h 2019-02-11 21:55:14 UTC (rev 241278)
@@ -80,7 +80,6 @@
#include <WebCore/LayoutSize.h>
#include <WebCore/MediaPlaybackTargetContext.h>
#include <WebCore/MediaProducer.h>
-#include <WebCore/PlatformEvent.h>
#include <WebCore/PlatformScreen.h>
#include <WebCore/PointerID.h>
#include <WebCore/ScrollTypes.h>
@@ -673,7 +672,7 @@
void disableDoubleTapGesturesDuringTapIfNecessary(uint64_t requestID);
void contentSizeCategoryDidChange(const String& contentSizeCategory);
void getSelectionContext(WTF::Function<void(const String&, const String&, const String&, CallbackBase::Error)>&&);
- void handleTwoFingerTapAtPoint(const WebCore::IntPoint&, OptionSet<WebKit::WebEvent::Modifier>, uint64_t requestID);
+ void handleTwoFingerTapAtPoint(const WebCore::IntPoint&, uint64_t requestID);
void handleStylusSingleTapAtPoint(const WebCore::IntPoint&, uint64_t requestID);
void setForceAlwaysUserScalable(bool);
bool forceAlwaysUserScalable() const { return m_forceAlwaysUserScalable; }
@@ -1172,10 +1171,10 @@
void willStartUserTriggeredZooming();
void potentialTapAtPosition(const WebCore::FloatPoint&, uint64_t& requestID);
- void commitPotentialTap(OptionSet<WebKit::WebEvent::Modifier>, uint64_t layerTreeTransactionIdAtLastTouchStart);
+ void commitPotentialTap(uint64_t layerTreeTransactionIdAtLastTouchStart);
void cancelPotentialTap();
void tapHighlightAtPosition(const WebCore::FloatPoint&, uint64_t& requestID);
- void handleTap(const WebCore::FloatPoint&, OptionSet<WebKit::WebEvent::Modifier>, uint64_t layerTreeTransactionIdAtLastTouchStart);
+ void handleTap(const WebCore::FloatPoint&, uint64_t layerTreeTransactionIdAtLastTouchStart);
void inspectorNodeSearchMovedToPosition(const WebCore::FloatPoint&);
void inspectorNodeSearchEndedAtPosition(const WebCore::FloatPoint&);
Modified: trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.h (241277 => 241278)
--- trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.h 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.h 2019-02-11 21:55:14 UTC (rev 241278)
@@ -406,7 +406,7 @@
- (void)_updateChangedSelection;
- (BOOL)_interpretKeyEvent:(::WebEvent *)theEvent isCharEvent:(BOOL)isCharEvent;
- (void)_positionInformationDidChange:(const WebKit::InteractionInformationAtPosition&)info;
-- (void)_attemptClickAtLocation:(CGPoint)location modifierFlags:(UIKeyModifierFlags)modifierFlags;
+- (void)_attemptClickAtLocation:(CGPoint)location;
- (void)_willStartScrollingOrZooming;
- (void)_didScroll;
- (void)_didEndScrollingOrZooming;
Modified: trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm (241277 => 241278)
--- trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1160,11 +1160,6 @@
}
#endif
-inline static UIKeyModifierFlags gestureRecognizerModifierFlags(UIGestureRecognizer *recognizer)
-{
- return [recognizer respondsToSelector:@selector(_modifierFlags)] ? recognizer.modifierFlags : 0;
-}
-
- (void)_webTouchEventsRecognized:(UIWebTouchEventsGestureRecognizer *)gestureRecognizer
{
if (!_page->isValid())
@@ -1177,7 +1172,7 @@
_layerTreeTransactionIdAtLastTouchStart = downcast<WebKit::RemoteLayerTreeDrawingAreaProxy>(*_page->drawingArea()).lastCommittedLayerTreeTransactionID();
#if ENABLE(TOUCH_EVENTS)
- WebKit::NativeWebTouchEvent nativeWebTouchEvent { lastTouchEvent, gestureRecognizerModifierFlags(gestureRecognizer) };
+ WebKit::NativeWebTouchEvent nativeWebTouchEvent(lastTouchEvent);
nativeWebTouchEvent.setCanPreventNativeGestures(!_canSendTouchEventsAsynchronously || [gestureRecognizer isDefaultPrevented]);
#if ENABLE(POINTER_EVENTS)
@@ -2060,7 +2055,7 @@
break;
case UIGestureRecognizerStateEnded:
if (_highlightLongPressCanClick && _positionInformation.isElement) {
- [self _attemptClickAtLocation:gestureRecognizer.startPoint modifierFlags:gestureRecognizerModifierFlags(gestureRecognizer)];
+ [self _attemptClickAtLocation:[gestureRecognizer startPoint]];
[self _finishInteraction];
} else
[self _cancelInteraction];
@@ -2079,7 +2074,7 @@
{
_isTapHighlightIDValid = YES;
_isExpectingFastSingleTapCommit = YES;
- _page->handleTwoFingerTapAtPoint(WebCore::roundedIntPoint(gestureRecognizer.centroid), WebKit::webEventModifierFlags(gestureRecognizerModifierFlags(gestureRecognizer)), ++_latestTapID);
+ _page->handleTwoFingerTapAtPoint(WebCore::roundedIntPoint(gestureRecognizer.centroid), ++_latestTapID);
}
- (void)_stylusSingleTapRecognized:(UITapGestureRecognizer *)gestureRecognizer
@@ -2201,7 +2196,7 @@
}
[_inputPeripheral endEditing];
- _page->commitPotentialTap(WebKit::webEventModifierFlags(gestureRecognizerModifierFlags(gestureRecognizer)), _layerTreeTransactionIdAtLastTouchStart);
+ _page->commitPotentialTap(_layerTreeTransactionIdAtLastTouchStart);
if (!_isExpectingFastSingleTapCommit)
[self _finishInteraction];
@@ -2234,7 +2229,7 @@
_smartMagnificationController->handleResetMagnificationGesture(gestureRecognizer.location);
}
-- (void)_attemptClickAtLocation:(CGPoint)location modifierFlags:(UIKeyModifierFlags)modifierFlags
+- (void)_attemptClickAtLocation:(CGPoint)location
{
if (![self isFirstResponder]) {
if (!_inputViewUpdateDeferrer)
@@ -2243,7 +2238,7 @@
}
[_inputPeripheral endEditing];
- _page->handleTap(location, WebKit::webEventModifierFlags(modifierFlags), _layerTreeTransactionIdAtLastTouchStart);
+ _page->handleTap(location, _layerTreeTransactionIdAtLastTouchStart);
}
- (void)setUpTextSelectionAssistant
@@ -5416,7 +5411,7 @@
- (void)actionSheetAssistant:(WKActionSheetAssistant *)assistant openElementAtLocation:(CGPoint)location
{
- [self _attemptClickAtLocation:location modifierFlags:0];
+ [self _attemptClickAtLocation:location];
}
- (void)actionSheetAssistant:(WKActionSheetAssistant *)assistant shareElementWithURL:(NSURL *)url rect:(CGRect)boundingRect
@@ -6423,22 +6418,6 @@
_page->performDictionaryLookupAtLocation(WebCore::FloatPoint(locationInViewCoordinates));
}
-static WebEventFlags webEventFlagsForUIKeyModifierFlags(UIKeyModifierFlags flags)
-{
- WebEventFlags eventFlags = 0;
- if (flags & UIKeyModifierShift)
- eventFlags |= WebEventFlagMaskLeftShiftKey;
- if (flags & UIKeyModifierControl)
- eventFlags |= WebEventFlagMaskLeftControlKey;
- if (flags & UIKeyModifierAlternate)
- eventFlags |= WebEventFlagMaskLeftOptionKey;
- if (flags & UIKeyModifierCommand)
- eventFlags |= WebEventFlagMaskLeftCommandKey;
- if (flags & UIKeyModifierAlphaShift)
- eventFlags |= WebEventFlagMaskLeftCapsLockKey;
- return eventFlags;
-}
-
- (void)_hoverGestureRecognizerChanged:(UIGestureRecognizer *)gestureRecognizer
{
if (!_page->isValid())
@@ -6460,7 +6439,7 @@
break;
}
- auto event = adoptNS([[::WebEvent alloc] initWithMouseEventType:WebEventMouseMoved timeStamp:timestamp location:point modifiers:webEventFlagsForUIKeyModifierFlags(gestureRecognizerModifierFlags(gestureRecognizer))]);
+ auto event = adoptNS([[::WebEvent alloc] initWithMouseEventType:WebEventMouseMoved timeStamp:timestamp location:point]);
_page->handleMouseEvent(WebKit::NativeWebMouseEvent(event.get()));
}
#endif
Modified: trunk/Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm (241277 => 241278)
--- trunk/Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm 2019-02-11 21:55:14 UTC (rev 241278)
@@ -596,9 +596,9 @@
m_process->send(Messages::WebPage::GetSelectionContext(callbackID), m_pageID);
}
-void WebPageProxy::handleTwoFingerTapAtPoint(const WebCore::IntPoint& point, OptionSet<WebEvent::Modifier> modifiers, uint64_t requestID)
+void WebPageProxy::handleTwoFingerTapAtPoint(const WebCore::IntPoint& point, uint64_t requestID)
{
- process().send(Messages::WebPage::HandleTwoFingerTapAtPoint(point, modifiers, requestID), m_pageID);
+ process().send(Messages::WebPage::HandleTwoFingerTapAtPoint(point, requestID), m_pageID);
}
void WebPageProxy::handleStylusSingleTapAtPoint(const WebCore::IntPoint& point, uint64_t requestID)
@@ -827,9 +827,9 @@
process().send(Messages::WebPage::PotentialTapAtPosition(requestID, position), m_pageID);
}
-void WebPageProxy::commitPotentialTap(OptionSet<WebEvent::Modifier> modifiers, uint64_t layerTreeTransactionIdAtLastTouchStart)
+void WebPageProxy::commitPotentialTap(uint64_t layerTreeTransactionIdAtLastTouchStart)
{
- process().send(Messages::WebPage::CommitPotentialTap(modifiers, layerTreeTransactionIdAtLastTouchStart), m_pageID);
+ process().send(Messages::WebPage::CommitPotentialTap(layerTreeTransactionIdAtLastTouchStart), m_pageID);
}
void WebPageProxy::cancelPotentialTap()
@@ -842,9 +842,9 @@
process().send(Messages::WebPage::TapHighlightAtPosition(requestID, position), m_pageID);
}
-void WebPageProxy::handleTap(const FloatPoint& location, OptionSet<WebEvent::Modifier> modifiers, uint64_t layerTreeTransactionIdAtLastTouchStart)
+void WebPageProxy::handleTap(const FloatPoint& location, uint64_t layerTreeTransactionIdAtLastTouchStart)
{
- process().send(Messages::WebPage::HandleTap(roundedIntPoint(location), modifiers, layerTreeTransactionIdAtLastTouchStart), m_pageID);
+ process().send(Messages::WebPage::HandleTap(roundedIntPoint(location), layerTreeTransactionIdAtLastTouchStart), m_pageID);
}
void WebPageProxy::inspectorNodeSearchMovedToPosition(const WebCore::FloatPoint& position)
Modified: trunk/Source/WebKit/WebProcess/WebPage/WebPage.h (241277 => 241278)
--- trunk/Source/WebKit/WebProcess/WebPage/WebPage.h 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/WebProcess/WebPage/WebPage.h 2019-02-11 21:55:14 UTC (rev 241278)
@@ -614,9 +614,9 @@
bool allowsUserScaling() const;
bool hasStablePageScaleFactor() const { return m_hasStablePageScaleFactor; }
- void handleTap(const WebCore::IntPoint&, OptionSet<WebKit::WebEvent::Modifier>, uint64_t lastLayerTreeTransactionId);
+ void handleTap(const WebCore::IntPoint&, uint64_t lastLayerTreeTransactionId);
void potentialTapAtPosition(uint64_t requestID, const WebCore::FloatPoint&);
- void commitPotentialTap(OptionSet<WebKit::WebEvent::Modifier>, uint64_t lastLayerTreeTransactionId);
+ void commitPotentialTap(uint64_t lastLayerTreeTransactionId);
void commitPotentialTapFailed();
void cancelPotentialTap();
void cancelPotentialTapInFrame(WebFrame&);
@@ -662,7 +662,7 @@
WebCore::IntRect rectForElementAtInteractionLocation();
void updateSelectionAppearance();
void getSelectionContext(CallbackID);
- void handleTwoFingerTapAtPoint(const WebCore::IntPoint&, OptionSet<WebKit::WebEvent::Modifier>, uint64_t requestID);
+ void handleTwoFingerTapAtPoint(const WebCore::IntPoint&, uint64_t requestID);
void handleStylusSingleTapAtPoint(const WebCore::IntPoint&, uint64_t requestID);
void getRectsForGranularityWithSelectionOffset(uint32_t, int32_t, CallbackID);
void getRectsAtSelectionOffsetWithText(int32_t, const String&, CallbackID);
@@ -1185,8 +1185,8 @@
RefPtr<WebCore::Range> rangeForWebSelectionAtPosition(const WebCore::IntPoint&, const WebCore::VisiblePosition&, SelectionFlags&);
void getFocusedElementInformation(FocusedElementInformation&);
void platformInitializeAccessibility();
- void handleSyntheticClick(WebCore::Node* nodeRespondingToClick, const WebCore::FloatPoint& location, OptionSet<WebKit::WebEvent::Modifier>);
- void completeSyntheticClick(WebCore::Node* nodeRespondingToClick, const WebCore::FloatPoint& location, OptionSet<WebKit::WebEvent::Modifier>, WebCore::SyntheticClickType);
+ void handleSyntheticClick(WebCore::Node* nodeRespondingToClick, const WebCore::FloatPoint& location);
+ void completeSyntheticClick(WebCore::Node* nodeRespondingToClick, const WebCore::FloatPoint& location, WebCore::SyntheticClickType);
void sendTapHighlightForNodeIfNecessary(uint64_t requestID, WebCore::Node*);
void resetTextAutosizing();
WebCore::VisiblePosition visiblePositionInFocusedNodeForPoint(const WebCore::Frame&, const WebCore::IntPoint&, bool isInteractingWithFocusedElement);
@@ -1768,7 +1768,6 @@
RefPtr<WebCore::Node> m_pendingSyntheticClickNode;
WebCore::FloatPoint m_pendingSyntheticClickLocation;
WebCore::FloatRect m_previousExposedContentRect;
- OptionSet<WebKit::WebEvent::Modifier> m_pendingSyntheticClickModifiers;
FocusedElementIdentifier m_currentFocusedElementIdentifier { 0 };
Optional<DynamicViewportSizeUpdateID> m_pendingDynamicViewportSizeUpdateID;
double m_lastTransactionPageScaleFactor { 0 };
Modified: trunk/Source/WebKit/WebProcess/WebPage/WebPage.messages.in (241277 => 241278)
--- trunk/Source/WebKit/WebProcess/WebPage/WebPage.messages.in 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/WebProcess/WebPage/WebPage.messages.in 2019-02-11 21:55:14 UTC (rev 241278)
@@ -51,9 +51,9 @@
SetOverrideViewportArguments(Optional<WebCore::ViewportArguments> arguments)
DynamicViewportSizeUpdate(WebCore::FloatSize viewLayoutSize, WebCore::FloatSize maximumUnobscuredSize, WebCore::FloatRect targetExposedContentRect, WebCore::FloatRect targetUnobscuredRect, WebCore::FloatRect targetUnobscuredRectInScrollViewCoordinates, WebCore::RectEdges<float> targetUnobscuredSafeAreaInsets, double scale, int32_t deviceOrientation, uint64_t dynamicViewportSizeUpdateID)
- HandleTap(WebCore::IntPoint point, OptionSet<WebKit::WebEvent::Modifier> modifiers, uint64_t lastLayerTreeTransactionId)
+ HandleTap(WebCore::IntPoint point, uint64_t lastLayerTreeTransactionId)
PotentialTapAtPosition(uint64_t requestID, WebCore::FloatPoint point)
- CommitPotentialTap(OptionSet<WebKit::WebEvent::Modifier> modifiers, uint64_t lastLayerTreeTransactionId)
+ CommitPotentialTap(uint64_t lastLayerTreeTransactionId)
CancelPotentialTap()
TapHighlightAtPosition(uint64_t requestID, WebCore::FloatPoint point)
InspectorNodeSearchMovedToPosition(WebCore::FloatPoint point)
@@ -98,7 +98,7 @@
ContentSizeCategoryDidChange(String contentSizeCategory)
GetSelectionContext(WebKit::CallbackID callbackID)
SetAllowsMediaDocumentInlinePlayback(bool allows)
- HandleTwoFingerTapAtPoint(WebCore::IntPoint point, OptionSet<WebKit::WebEvent::Modifier> modifiers, uint64_t requestID)
+ HandleTwoFingerTapAtPoint(WebCore::IntPoint point, uint64_t requestID)
HandleStylusSingleTapAtPoint(WebCore::IntPoint point, uint64_t requestID)
SetForceAlwaysUserScalable(bool userScalable)
GetRectsForGranularityWithSelectionOffset(uint32_t granularity, int32_t offset, WebKit::CallbackID callbackID)
Modified: trunk/Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm (241277 => 241278)
--- trunk/Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm 2019-02-11 21:55:14 UTC (rev 241278)
@@ -534,7 +534,7 @@
didChangeSelection();
}
-void WebPage::handleSyntheticClick(Node* nodeRespondingToClick, const WebCore::FloatPoint& location, OptionSet<WebEvent::Modifier> modifiers)
+void WebPage::handleSyntheticClick(Node* nodeRespondingToClick, const WebCore::FloatPoint& location)
{
IntPoint roundedAdjustedPoint = roundedIntPoint(location);
Frame& mainframe = m_page->mainFrame();
@@ -543,12 +543,7 @@
WKStartObservingContentChanges();
WKStartObservingDOMTimerScheduling();
- // FIXME: Pass caps lock state.
- bool shiftKey = modifiers.contains(WebEvent::Modifier::ShiftKey);
- bool ctrlKey = modifiers.contains(WebEvent::Modifier::ControlKey);
- bool altKey = modifiers.contains(WebEvent::Modifier::AltKey);
- bool metaKey = modifiers.contains(WebEvent::Modifier::MetaKey);
- mainframe.eventHandler().mouseMoved(PlatformMouseEvent(roundedAdjustedPoint, roundedAdjustedPoint, NoButton, PlatformEvent::MouseMoved, 0, shiftKey, ctrlKey, altKey, metaKey, WallTime::now(), WebCore::ForceAtClick, WebCore::NoTap));
+ mainframe.eventHandler().mouseMoved(PlatformMouseEvent(roundedAdjustedPoint, roundedAdjustedPoint, NoButton, PlatformEvent::MouseMoved, 0, false, false, false, false, WallTime::now(), WebCore::ForceAtClick, WebCore::NoTap));
mainframe.document()->updateStyleIfNeeded();
WKStopObservingDOMTimerScheduling();
@@ -556,7 +551,6 @@
m_pendingSyntheticClickNode = nullptr;
m_pendingSyntheticClickLocation = FloatPoint();
- m_pendingSyntheticClickModifiers = { };
if (m_isClosed)
return;
@@ -566,16 +560,15 @@
// The move event caused new contents to appear. Don't send the click event.
LOG(ContentObservation, "handleSyntheticClick: Observed meaningful visible change -> hover.");
return;
- case WKContentIndeterminateChange: {
+ case WKContentIndeterminateChange:
// Wait for callback to completePendingSyntheticClickForContentChangeObserver() to decide whether to send the click event.
m_pendingSyntheticClickNode = nodeRespondingToClick;
m_pendingSyntheticClickLocation = location;
- m_pendingSyntheticClickModifiers = modifiers;
LOG(ContentObservation, "handleSyntheticClick: Observed some change, but can't decide it yet -> wait.");
return;
- } case WKContentNoChange:
+ case WKContentNoChange:
LOG(ContentObservation, "handleSyntheticClick: No change was observed -> click.");
- completeSyntheticClick(nodeRespondingToClick, location, modifiers, WebCore::OneFingerTap);
+ completeSyntheticClick(nodeRespondingToClick, location, WebCore::OneFingerTap);
return;
}
ASSERT_NOT_REACHED();
@@ -589,16 +582,15 @@
// Only dispatch the click if the document didn't get changed by any timers started by the move event.
if (WKObservedContentChange() == WKContentNoChange) {
LOG(ContentObservation, "No chage was observed -> click.");
- completeSyntheticClick(m_pendingSyntheticClickNode.get(), m_pendingSyntheticClickLocation, m_pendingSyntheticClickModifiers, WebCore::OneFingerTap);
+ completeSyntheticClick(m_pendingSyntheticClickNode.get(), m_pendingSyntheticClickLocation, WebCore::OneFingerTap);
} else
LOG(ContentObservation, "Observed meaningful visible change -> hover.");
m_pendingSyntheticClickNode = nullptr;
m_pendingSyntheticClickLocation = FloatPoint();
- m_pendingSyntheticClickModifiers = { };
}
-void WebPage::completeSyntheticClick(Node* nodeRespondingToClick, const WebCore::FloatPoint& location, OptionSet<WebEvent::Modifier> modifiers, SyntheticClickType syntheticClickType)
+void WebPage::completeSyntheticClick(Node* nodeRespondingToClick, const WebCore::FloatPoint& location, SyntheticClickType syntheticClickType)
{
IntPoint roundedAdjustedPoint = roundedIntPoint(location);
Frame& mainframe = m_page->mainFrame();
@@ -611,17 +603,11 @@
bool tapWasHandled = false;
m_lastInteractionLocation = roundedAdjustedPoint;
- // FIXME: Pass caps lock state.
- bool shiftKey = modifiers.contains(WebEvent::Modifier::ShiftKey);
- bool ctrlKey = modifiers.contains(WebEvent::Modifier::ControlKey);
- bool altKey = modifiers.contains(WebEvent::Modifier::AltKey);
- bool metaKey = modifiers.contains(WebEvent::Modifier::MetaKey);
-
- tapWasHandled |= mainframe.eventHandler().handleMousePressEvent(PlatformMouseEvent(roundedAdjustedPoint, roundedAdjustedPoint, LeftButton, PlatformEvent::MousePressed, 1, shiftKey, ctrlKey, altKey, metaKey, WallTime::now(), WebCore::ForceAtClick, syntheticClickType));
+ tapWasHandled |= mainframe.eventHandler().handleMousePressEvent(PlatformMouseEvent(roundedAdjustedPoint, roundedAdjustedPoint, LeftButton, PlatformEvent::MousePressed, 1, false, false, false, false, WallTime::now(), WebCore::ForceAtClick, syntheticClickType));
if (m_isClosed)
return;
- tapWasHandled |= mainframe.eventHandler().handleMouseReleaseEvent(PlatformMouseEvent(roundedAdjustedPoint, roundedAdjustedPoint, LeftButton, PlatformEvent::MouseReleased, 1, shiftKey, ctrlKey, altKey, metaKey, WallTime::now(), WebCore::ForceAtClick, syntheticClickType));
+ tapWasHandled |= mainframe.eventHandler().handleMouseReleaseEvent(PlatformMouseEvent(roundedAdjustedPoint, roundedAdjustedPoint, LeftButton, PlatformEvent::MouseReleased, 1, false, false, false, false, WallTime::now(), WebCore::ForceAtClick, syntheticClickType));
if (m_isClosed)
return;
@@ -641,7 +627,7 @@
send(Messages::WebPageProxy::DidCompleteSyntheticClick());
}
-void WebPage::handleTap(const IntPoint& point, OptionSet<WebEvent::Modifier> modifiers, uint64_t lastLayerTreeTransactionId)
+void WebPage::handleTap(const IntPoint& point, uint64_t lastLayerTreeTransactionId)
{
FloatPoint adjustedPoint;
Node* nodeRespondingToClick = m_page->mainFrame().nodeRespondingToClickEvents(point, adjustedPoint);
@@ -658,7 +644,7 @@
}
#endif
else
- handleSyntheticClick(nodeRespondingToClick, adjustedPoint, modifiers);
+ handleSyntheticClick(nodeRespondingToClick, adjustedPoint);
}
void WebPage::requestFocusedElementInformation(WebKit::CallbackID callbackID)
@@ -753,7 +739,7 @@
#endif
}
-void WebPage::handleTwoFingerTapAtPoint(const WebCore::IntPoint& point, OptionSet<WebKit::WebEvent::Modifier> modifiers, uint64_t requestID)
+void WebPage::handleTwoFingerTapAtPoint(const WebCore::IntPoint& point, uint64_t requestID)
{
FloatPoint adjustedPoint;
Node* nodeRespondingToClick = m_page->mainFrame().nodeRespondingToClickEvents(point, adjustedPoint);
@@ -769,7 +755,7 @@
send(Messages::WebPageProxy::DidNotHandleTapAsClick(roundedIntPoint(adjustedPoint)));
} else
#endif
- completeSyntheticClick(nodeRespondingToClick, adjustedPoint, modifiers, WebCore::TwoFingerTap);
+ completeSyntheticClick(nodeRespondingToClick, adjustedPoint, WebCore::TwoFingerTap);
}
void WebPage::handleStylusSingleTapAtPoint(const WebCore::IntPoint& point, uint64_t requestID)
@@ -814,7 +800,7 @@
#endif
}
-void WebPage::commitPotentialTap(OptionSet<WebEvent::Modifier> modifiers, uint64_t lastLayerTreeTransactionId)
+void WebPage::commitPotentialTap(uint64_t lastLayerTreeTransactionId)
{
if (!m_potentialTapNode || (!m_potentialTapNode->renderer() && !is<HTMLAreaElement>(m_potentialTapNode.get()))) {
commitPotentialTapFailed();
@@ -838,7 +824,7 @@
commitPotentialTapFailed();
} else
#endif
- handleSyntheticClick(nodeRespondingToClick, adjustedPoint, modifiers);
+ handleSyntheticClick(nodeRespondingToClick, adjustedPoint);
} else
commitPotentialTapFailed();
Modified: trunk/Tools/ChangeLog (241277 => 241278)
--- trunk/Tools/ChangeLog 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Tools/ChangeLog 2019-02-11 21:55:14 UTC (rev 241278)
@@ -1,3 +1,21 @@
+2019-02-11 Commit Queue <[email protected]>
+
+ Unreviewed, rolling out r241272 and r241276.
+ https://bugs.webkit.org/show_bug.cgi?id=194514
+
+ Broke the Apple Internal build and the fix requires human
+ intervention :( (Requested by dydz on #webkit).
+
+ Reverted changesets:
+
+ "[iOS] Mouse/Touch/Pointer events are missing modifier keys"
+ https://bugs.webkit.org/show_bug.cgi?id=191446
+ https://trac.webkit.org/changeset/241272
+
+ "Fix internal iOS build after r241272"
+ https://bugs.webkit.org/show_bug.cgi?id=191446
+ https://trac.webkit.org/changeset/241276
+
2019-02-11 Truitt Savell <[email protected]>
Unreviewed, rolling out r241269.
Modified: trunk/Tools/DumpRenderTree/ios/UIScriptControllerIOS.mm (241277 => 241278)
--- trunk/Tools/DumpRenderTree/ios/UIScriptControllerIOS.mm 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Tools/DumpRenderTree/ios/UIScriptControllerIOS.mm 2019-02-11 21:55:14 UTC (rev 241278)
@@ -115,10 +115,6 @@
{
}
-void UIScriptController::singleTapAtPointWithModifiers(long x, long y, JSValueRef modifierArray, JSValueRef callback)
-{
-}
-
void UIScriptController::doubleTapAtPoint(long x, long y, JSValueRef callback)
{
}
@@ -147,10 +143,6 @@
{
}
-void UIScriptController::stylusTapAtPointWithModifiers(long x, long y, float azimuthAngle, float altitudeAngle, float pressure, JSValueRef modifierArray, JSValueRef callback)
-{
-}
-
void UIScriptController::sendEventStream(JSStringRef eventsJSON, JSValueRef callback)
{
}
Modified: trunk/Tools/TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl (241277 => 241278)
--- trunk/Tools/TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Tools/TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl 2019-02-11 21:55:14 UTC (rev 241278)
@@ -56,7 +56,6 @@
void touchDownAtPoint(long x, long y, long touchCount, object callback);
void liftUpAtPoint(long x, long y, long touchCount, object callback);
void singleTapAtPoint(long x, long y, object callback);
- void singleTapAtPointWithModifiers(long x, long y, object modifierArray, object callback);
void doubleTapAtPoint(long x, long y, object callback);
void dragFromPointToPoint(long startX, long startY, long endX, long endY, double durationSeconds, object callback);
@@ -66,7 +65,6 @@
void stylusMoveToPoint(long x, long y, float azimuthAngle, float altitudeAngle, float pressure, object callback);
void stylusUpAtPoint(long x, long y, object callback);
void stylusTapAtPoint(long x, long y, float azimuthAngle, float altitudeAngle, float pressure, object callback);
- void stylusTapAtPointWithModifiers(long x, long y, float azimuthAngle, float altitudeAngle, float pressure, object modifierArray, object callback);
void enterText(DOMString text);
void typeCharacterUsingHardwareKeyboard(DOMString character, object callback);
Modified: trunk/Tools/TestRunnerShared/UIScriptContext/UIScriptController.cpp (241277 => 241278)
--- trunk/Tools/TestRunnerShared/UIScriptContext/UIScriptController.cpp 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Tools/TestRunnerShared/UIScriptContext/UIScriptController.cpp 2019-02-11 21:55:14 UTC (rev 241278)
@@ -265,10 +265,6 @@
{
}
-void UIScriptController::singleTapAtPointWithModifiers(long x, long y, JSValueRef modifierArray, JSValueRef callback)
-{
-}
-
void UIScriptController::doubleTapAtPoint(long x, long y, JSValueRef)
{
}
@@ -297,10 +293,6 @@
{
}
-void UIScriptController::stylusTapAtPointWithModifiers(long x, long y, float azimuthAngle, float altitudeAngle, float pressure, JSValueRef modifierArray, JSValueRef callback)
-{
-}
-
void UIScriptController::sendEventStream(JSStringRef eventsJSON, JSValueRef callback)
{
}
Modified: trunk/Tools/TestRunnerShared/UIScriptContext/UIScriptController.h (241277 => 241278)
--- trunk/Tools/TestRunnerShared/UIScriptContext/UIScriptController.h 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Tools/TestRunnerShared/UIScriptContext/UIScriptController.h 2019-02-11 21:55:14 UTC (rev 241278)
@@ -78,7 +78,6 @@
void touchDownAtPoint(long x, long y, long touchCount, JSValueRef callback);
void liftUpAtPoint(long x, long y, long touchCount, JSValueRef callback);
void singleTapAtPoint(long x, long y, JSValueRef callback);
- void singleTapAtPointWithModifiers(long x, long y, JSValueRef modifierArray, JSValueRef callback);
void doubleTapAtPoint(long x, long y, JSValueRef callback);
void dragFromPointToPoint(long startX, long startY, long endX, long endY, double durationSeconds, JSValueRef callback);
@@ -86,7 +85,6 @@
void stylusMoveToPoint(long x, long y, float azimuthAngle, float altitudeAngle, float pressure, JSValueRef callback);
void stylusUpAtPoint(long x, long y, JSValueRef callback);
void stylusTapAtPoint(long x, long y, float azimuthAngle, float altitudeAngle, float pressure, JSValueRef callback);
- void stylusTapAtPointWithModifiers(long x, long y, float azimuthAngle, float altitudeAngle, float pressure, JSValueRef modifierArray, JSValueRef callback);
void longPressAtPoint(long x, long y, JSValueRef callback);
Modified: trunk/Tools/WebKitTestRunner/ios/UIScriptControllerIOS.mm (241277 => 241278)
--- trunk/Tools/WebKitTestRunner/ios/UIScriptControllerIOS.mm 2019-02-11 21:47:56 UTC (rev 241277)
+++ trunk/Tools/WebKitTestRunner/ios/UIScriptControllerIOS.mm 2019-02-11 21:55:14 UTC (rev 241278)
@@ -63,45 +63,7 @@
@"height": @(rect.size.height)
};
}
-
-static unsigned arrayLength(JSContextRef context, JSObjectRef array)
-{
- auto lengthString = adopt(JSStringCreateWithUTF8CString("length"));
- if (auto lengthValue = JSObjectGetProperty(context, array, lengthString.get(), nullptr))
- return static_cast<unsigned>(JSValueToNumber(context, lengthValue, nullptr));
- return 0;
-}
-
-static Vector<String> parseModifierArray(JSContextRef context, JSValueRef arrayValue)
-{
- if (!arrayValue)
- return { };
-
- // The value may either be a string with a single modifier or an array of modifiers.
- if (JSValueIsString(context, arrayValue)) {
- auto string = toWTFString(toWK(adopt(JSValueToStringCopy(context, arrayValue, nullptr))));
- return { string };
- }
-
- if (!JSValueIsObject(context, arrayValue))
- return { };
- JSObjectRef array = const_cast<JSObjectRef>(arrayValue);
- unsigned length = arrayLength(context, array);
- Vector<String> modifiers;
- modifiers.reserveInitialCapacity(length);
- for (unsigned i = 0; i < length; ++i) {
- JSValueRef exception = nullptr;
- JSValueRef value = JSObjectGetPropertyAtIndex(context, array, i, &exception);
- if (exception)
- continue;
- auto string = adopt(JSValueToStringCopy(context, value, &exception));
- if (exception)
- continue;
- modifiers.append(toWTFString(toWK(string.get())));
- }
- return modifiers;
-}
-
+
void UIScriptController::checkForOutstandingCallbacks()
{
if (![[HIDEventGenerator sharedHIDEventGenerator] checkForOutstandingCallbacks])
@@ -231,29 +193,12 @@
void UIScriptController::singleTapAtPoint(long x, long y, JSValueRef callback)
{
- singleTapAtPointWithModifiers(x, y, nullptr, callback);
-}
-
-void UIScriptController::singleTapAtPointWithModifiers(long x, long y, JSValueRef modifierArray, JSValueRef callback)
-{
unsigned callbackID = m_context->prepareForAsyncTask(callback, CallbackTypeNonPersistent);
- auto modifierFlags = parseModifierArray(m_context->jsContext(), modifierArray);
- for (auto& modifierFlag : modifierFlags)
- [[HIDEventGenerator sharedHIDEventGenerator] keyDown:modifierFlag];
-
[[HIDEventGenerator sharedHIDEventGenerator] tap:globalToContentCoordinates(TestController::singleton().mainWebView()->platformView(), x, y) completionBlock:^{
if (!m_context)
return;
- for (size_t i = modifierFlags.size(); i; ) {
- --i;
- [[HIDEventGenerator sharedHIDEventGenerator] keyUp:modifierFlags[i]];
- }
- [[HIDEventGenerator sharedHIDEventGenerator] sendMarkerHIDEventWithCompletionBlock:^{
- if (!m_context)
- return;
- m_context->asyncTaskComplete(callbackID);
- }];
+ m_context->asyncTaskComplete(callbackID);
}];
}
@@ -306,33 +251,16 @@
void UIScriptController::stylusTapAtPoint(long x, long y, float azimuthAngle, float altitudeAngle, float pressure, JSValueRef callback)
{
- stylusTapAtPointWithModifiers(x, y, azimuthAngle, altitudeAngle, pressure, nullptr, callback);
-}
-
-void UIScriptController::stylusTapAtPointWithModifiers(long x, long y, float azimuthAngle, float altitudeAngle, float pressure, JSValueRef modifierArray, JSValueRef callback)
-{
unsigned callbackID = m_context->prepareForAsyncTask(callback, CallbackTypeNonPersistent);
- auto modifierFlags = parseModifierArray(m_context->jsContext(), modifierArray);
- for (auto& modifierFlag : modifierFlags)
- [[HIDEventGenerator sharedHIDEventGenerator] keyDown:modifierFlag];
-
auto location = globalToContentCoordinates(TestController::singleton().mainWebView()->platformView(), x, y);
[[HIDEventGenerator sharedHIDEventGenerator] stylusTapAtPoint:location azimuthAngle:azimuthAngle altitudeAngle:altitudeAngle pressure:pressure completionBlock:^{
if (!m_context)
return;
- for (size_t i = modifierFlags.size(); i; ) {
- --i;
- [[HIDEventGenerator sharedHIDEventGenerator] keyUp:modifierFlags[i]];
- }
- [[HIDEventGenerator sharedHIDEventGenerator] sendMarkerHIDEventWithCompletionBlock:^{
- if (!m_context)
- return;
- m_context->asyncTaskComplete(callbackID);
- }];
+ m_context->asyncTaskComplete(callbackID);
}];
}
-
+
void convertCoordinates(NSMutableDictionary *event)
{
if (event[HIDEventTouchesKey]) {
@@ -421,6 +349,44 @@
}];
}
+static unsigned arrayLength(JSContextRef context, JSObjectRef array)
+{
+ auto lengthString = adopt(JSStringCreateWithUTF8CString("length"));
+ if (auto lengthValue = JSObjectGetProperty(context, array, lengthString.get(), nullptr))
+ return static_cast<unsigned>(JSValueToNumber(context, lengthValue, nullptr));
+ return 0;
+}
+
+static Vector<String> parseModifierArray(JSContextRef context, JSValueRef arrayValue)
+{
+ if (!arrayValue)
+ return { };
+
+ // The value may either be a string with a single modifier or an array of modifiers.
+ if (JSValueIsString(context, arrayValue)) {
+ auto string = toWTFString(toWK(adopt(JSValueToStringCopy(context, arrayValue, nullptr))));
+ return { string };
+ }
+
+ if (!JSValueIsObject(context, arrayValue))
+ return { };
+ JSObjectRef array = const_cast<JSObjectRef>(arrayValue);
+ unsigned length = arrayLength(context, array);
+ Vector<String> modifiers;
+ modifiers.reserveInitialCapacity(length);
+ for (unsigned i = 0; i < length; ++i) {
+ JSValueRef exception = nullptr;
+ JSValueRef value = JSObjectGetPropertyAtIndex(context, array, i, &exception);
+ if (exception)
+ continue;
+ auto string = adopt(JSValueToStringCopy(context, value, &exception));
+ if (exception)
+ continue;
+ modifiers.append(toWTFString(toWK(string.get())));
+ }
+ return modifiers;
+}
+
static UIPhysicalKeyboardEvent *createUIPhysicalKeyboardEvent(NSString *hidInputString, NSString *uiEventInputString, UIKeyModifierFlags modifierFlags, UIKeyboardInputFlags inputFlags, bool isKeyDown)
{
auto* keyboardEvent = [getUIPhysicalKeyboardEventClass() _eventWithInput:uiEventInputString inputFlags:inputFlags];