| Index: LayoutTests/fast/events/touch/resources/touch-hover-active-tests.js
|
| diff --git a/LayoutTests/fast/events/touch/resources/touch-hover-active-tests.js b/LayoutTests/fast/events/touch/resources/touch-hover-active-tests.js
|
| index 324adc75012fc2187b12170bf9b1d0101ce95e54..7371112b69f92a5c8cec4a26a2558111e7fa035a 100644
|
| --- a/LayoutTests/fast/events/touch/resources/touch-hover-active-tests.js
|
| +++ b/LayoutTests/fast/events/touch/resources/touch-hover-active-tests.js
|
| @@ -26,3 +26,23 @@ function shouldBeDefault(e) { shouldBeEqualToString(e, "default"); }
|
| function shouldBeOnlyActive(e) { shouldBeEqualToString(e, "active"); }
|
| function shouldBeOnlyHovered(e) { shouldBeEqualToString(e, "hovered"); }
|
| function shouldBeHoveredAndActive(e) { shouldBeEqualToString(e, "hoveredAndActive"); }
|
| +
|
| +function hasEarlyShowPress(e, elementLocation, shouldBeActivated)
|
| +{
|
| + debug("Verify hover, active aren't initially set.");
|
| + shouldBeDefault(e);
|
| +
|
| + eventSender.gestureTapDown(elementLocation.x, elementLocation.y);
|
| + if (shouldBeActivated) {
|
| + debug("tapDown on element should activate.");
|
| + shouldBeHoveredAndActive(e);
|
| + } else {
|
| + debug("tapdown on element should not activate.");
|
| + shouldBeDefault(e);
|
| + }
|
| +
|
| + debug("showPress on element should " + (shouldBeActivated ? "keep hover and active." : "activate."));
|
| + eventSender.gestureShowPress(elementLocation.x, elementLocation.y);
|
| + shouldBeHoveredAndActive(e);
|
| + eventSender.gestureTapCancel(elementLocation.x, elementLocation.y);
|
| +}
|
|
|