Commit d91faace authored by jer.noble@apple.com's avatar jer.noble@apple.com

Media Element: scrubbing in full-screen mode breaks playback.

https://bugs.webkit.org/show_bug.cgi?id=75650

Reviewed by John Sullivan.

Source/WebCore:

Test: fullscreen/video-controls-timeline.html

Only begin scrubbing if the panel itself is the mousedown event target.

* html/shadow/MediaControlElements.cpp:
(WebCore::MediaControlPanelElement::defaultEventHandler):

LayoutTests:

* fullscreen/video-controls-timeline-expected.txt: Added.
* fullscreen/video-controls-timeline.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@104303 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent bfc36932
2012-01-05 Jer Noble <jer.noble@apple.com>
Media Element: scrubbing in full-screen mode breaks playback.
https://bugs.webkit.org/show_bug.cgi?id=75650
Reviewed by John Sullivan.
* fullscreen/video-controls-timeline-expected.txt: Added.
* fullscreen/video-controls-timeline.html: Added.
2012-01-06 Jer Noble <jer.noble@apple.com>
Add new (failing) test to Chromium test_expectations. Fix tracked by
This tests that the video element's timeline controls are draggable in full screen. Press any key to continue.
EVENT(canplaythrough)
EVENT(webkitfullscreenchange)
EVENT(mousedown)
EVENT(mouseup)
END OF TEST
<body>
<p>This tests that the video element's timeline controls are draggable in full screen. Press any key to continue.</p>
<video id="video" width="300" controls></video>
<script src="full-screen-test.js"></script>
<script src="../media/media-controls.js"></script>
<script src="../media/media-file.js"></script>
<script>
var video = document.getElementById('video');
var timeline;
waitForEvent(document, 'webkitfullscreenchange', function() {
if (window.internals) {
timeline = mediaControlsElement(internals.shadowRoot(video).firstChild, '-webkit-media-controls-timeline');
var box = internals.boundingBox(timeline);
eventSender.mouseMoveTo(box.left + 5, box.top + 5);
waitForEvent(timeline, 'mousedown');
eventSender.mouseDown();
waitForEventAndEnd(timeline, 'mouseup');
eventSender.mouseUp();
}
else
logResult(false, "window.internals == undefined");
});
waitForEvent(video, 'canplaythrough', function() {
runWithKeyDown(function(){video.webkitRequestFullScreen()});
});
video.src = findMediaFile('video', '../media/content/test');
</script>
</body>
2012-01-05 Jer Noble <jer.noble@apple.com>
Media Element: scrubbing in full-screen mode breaks playback.
https://bugs.webkit.org/show_bug.cgi?id=75650
Reviewed by John Sullivan.
Test: fullscreen/video-controls-timeline.html
Only begin scrubbing if the panel itself is the mousedown event target.
* html/shadow/MediaControlElements.cpp:
(WebCore::MediaControlPanelElement::defaultEventHandler):
2012-01-05 Jer Noble <jer.noble@apple.com>
REGRESSION (r90797): Full screen video HUD cannot be dragged horizontally
......@@ -236,12 +236,12 @@ void MediaControlPanelElement::defaultEventHandler(Event* event)
if (event->isMouseEvent()) {
LayoutPoint location = static_cast<MouseEvent*>(event)->absoluteLocation();
if (event->type() == eventNames().mousedownEvent) {
if (event->type() == eventNames().mousedownEvent && event->target() == this) {
startDrag(location);
event->setDefaultHandled();
} else if (event->type() == eventNames().mousemoveEvent)
} else if (event->type() == eventNames().mousemoveEvent && m_isBeingDragged)
continueDrag(location);
else if (event->type() == eventNames().mouseupEvent) {
else if (event->type() == eventNames().mouseupEvent && m_isBeingDragged) {
continueDrag(location);
endDrag();
event->setDefaultHandled();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment