Index: LayoutTests/media/video-controls-visibility-multimodal-mouse-after-touch.html |
diff --git a/LayoutTests/media/video-controls-always-visible-when-control-hovered.html b/LayoutTests/media/video-controls-visibility-multimodal-mouse-after-touch.html |
similarity index 60% |
copy from LayoutTests/media/video-controls-always-visible-when-control-hovered.html |
copy to LayoutTests/media/video-controls-visibility-multimodal-mouse-after-touch.html |
index 68162418d20aad1b36112dd10f7aec668bd6bc40..56179954bc7899d7b894114e9c53917e48fc9d2a 100644 |
--- a/LayoutTests/media/video-controls-always-visible-when-control-hovered.html |
+++ b/LayoutTests/media/video-controls-visibility-multimodal-mouse-after-touch.html |
@@ -20,29 +20,28 @@ function runTest() |
if (!window.testRunner) |
return; |
- // Click the play button. |
- var playCoords = mediaControlsButtonCoordinates(video, "play-button"); |
- var clickX = playCoords[0]; |
- var clickY = playCoords[1]; |
- eventSender.mouseMoveTo(clickX, clickY); |
- eventSender.mouseDown(); |
- eventSender.mouseUp(); |
+ // Tap (touch input) the play button. |
+ var coords = mediaControlsButtonCoordinates(video, "play-button"); |
+ eventSender.gestureTapDown(coords[0], coords[1]); |
+ eventSender.gestureShowPress(coords[0], coords[1]); |
+ eventSender.gestureTap(coords[0], coords[1]); |
testExpected("video.paused", false); |
+ // And then hover the control with the mouse. |
+ eventSender.mouseMoveTo(coords[0], coords[1]); |
+ |
+ // And the controls should remain visible. |
runAfterHideMediaControlsTimerFired(function() |
{ |
controls = mediaControlsButton(video, "panel"); |
testExpected("getComputedStyle(controls).opacity", 1); |
- |
- consoleWrite(""); |
endTest(); |
}, video); |
} |
</script> |
<body> |
- <p>Test video element control visibility after click on control. After the click |
- the mouse does not move, so the control is still hovered and it should |
- remain visible.</p> |
+ <p>Test video element control visibility with multimodal input. The controls |
+ should remain visible if the last input event was a mouse move over them.</p> |
<p>This test only runs in DRT!</p> |
<video id="no-video-media" controls loop oncanplaythrough="runTest()"></video> |