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

Unified Diff: third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-event-properties.html

Issue 1760183002: Fixed missing pointerTypes for touch events. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed line-lengths, added a bug ref. Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-event-properties.html
diff --git a/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-event-properties.html b/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-event-properties.html
index 0b0f11893c3a800ea3375feee917b0c1ec26d26e..9ebfd50569539b207663d1b98c143ad28759daae 100644
--- a/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-event-properties.html
+++ b/third_party/WebKit/LayoutTests/fast/events/pointerevents/touch-pointer-event-properties.html
@@ -22,7 +22,7 @@ async_test(function() {
test(function() {
assert_between_inclusive(event.pointerId, 1, POINTER_PROPERTIES.length);
var pp = POINTER_PROPERTIES[event.pointerId-1];
- for ( var i in pp )
+ for (var i in pp)
assert_equals(event[i], pp[i], "" + i);
}, "Pointer event properties for pointer " + event.pointerId + " on " + event.type);
}
@@ -34,19 +34,22 @@ async_test(function() {
var x = target0.offsetLeft + 2;
var y = target0.offsetTop + 2;
- for ( var i = 0 ; i < POINTER_PROPERTIES.length ; ++i ) {
+ for (var i = 0 ; i < POINTER_PROPERTIES.length; ++i) {
var pp = POINTER_PROPERTIES[i];
- eventSender.addTouchPoint(x + i, y + i, pp["width"], pp["height"], pp["pressure"], pp["tiltX"], pp["tiltY"], pp["pointerType"]);
+ if (i != POINTER_PROPERTIES.length-1)
+ eventSender.addTouchPoint(x + i, y + i, pp["width"], pp["height"], pp["pressure"], pp["tiltX"], pp["tiltY"], pp["pointerType"]);
+ else // Test default pointerType
+ eventSender.addTouchPoint(x + i, y + i, pp["width"], pp["height"], pp["pressure"], pp["tiltX"], pp["tiltY"]);
}
eventSender.touchStart();
- for ( var i = 0 ; i < POINTER_PROPERTIES.length ; ++i ) {
+ for (var i = 0 ; i < POINTER_PROPERTIES.length; ++i) {
var pp = POINTER_PROPERTIES[i];
eventSender.updateTouchPoint(i, x + i + 20, y + i + 20);
}
eventSender.touchMove();
- for ( var i = 0 ; i < POINTER_PROPERTIES.length ; ++i )
+ for (var i = 0 ; i < POINTER_PROPERTIES.length ; ++i)
eventSender.releaseTouchPoint(i);
eventSender.touchEnd();

Powered by Google App Engine
This is Rietveld 408576698