Introduce an Enclosure Element for Chromium video controls.
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 12 Jun 2012 05:40:04 +0000 (05:40 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 12 Jun 2012 05:40:04 +0000 (05:40 +0000)
commite6b912df3efe868b8445581af97a14c8f199b1fa
tree1595ff6a225fa9ad90a11abb68a8e607106038e8
parent7c3b6fbca0e60224e313d91c42c09430fccc7fc8
Introduce an Enclosure Element for Chromium video controls.
https://bugs.webkit.org/show_bug.cgi?id=87683

Patch by Silvia Pfeiffer <silviapf@chromium.org> on 2012-06-11
Reviewed by Eric Carlson.

Source/WebCore:

Updated tests.

The Chrome video controls are receiving a visual update. A new enclosure div is required
to provide for a offset space from the video's boundaries. The visual update itself is in
a separate patch.

* css/mediaControlsChromium.css:
(video::-webkit-media-controls-enclosure):
Introduce CSS for enclosure div so it doesn't show yet.
* html/shadow/MediaControlRootElementChromium.cpp:
(WebCore::MediaControlChromiumEnclosureElement::MediaControlChromiumEnclosureElement):
Definition of the new enclosure element.
(WebCore::MediaControlChromiumEnclosureElement::create):
Definition of a create operator for the new enclosure element.
(WebCore::MediaControlChromiumEnclosureElement::shadowPseudoId):
Definition of the shadowPseudoId of -webkit-media-controls-enclosure for the enclosure div.
(WebCore::MediaControlRootElementChromium::MediaControlRootElementChromium):
Initialize member element for enclosure div.
(WebCore::MediaControlRootElementChromium::create):
Instantiate enclosure div and add into DOM between controls and panel elements.
(WebCore::MediaControlRootElementChromium::setMediaController):
Set media controller for enclosure div.
(WebCore::MediaControlRootElementChromium::createTextTrackDisplay):
Insert text track display container to enclosure rather than panel.
* html/shadow/MediaControlRootElementChromium.h:
(WebCore):
(MediaControlChromiumEnclosureElement):
(WebCore::MediaControlChromiumEnclosureElement::setMediaController):
(WebCore::MediaControlChromiumEnclosureElement::mediaController):
(WebCore::MediaControlChromiumEnclosureElement::isMediaControlElement):
Add declaration of the new enclosure element and its member functions.
(MediaControlRootElementChromium):
Add member variable to controls root element to hold the enclosure element.

LayoutTests:

Change fullscreen/video-controls-override.html, media/media-controls-invalid-url.html and
media/track/track-cue-rendering-snap-to-lines-not-set.html to deal with the new enclosure
div in Chromium controls and use the mediaControlsElement() helper function to find elements
inside the controls.
Fail video controls tests in test expectations.

* fullscreen/video-controls-override-expected.txt: Updated.
* fullscreen/video-controls-override.html: Use mediaControlsElement helper function.
* media/media-controls-invalid-url.html: Use mediaControlsElement helper function.
* media/track/track-cue-rendering-snap-to-lines-not-set.html: Height is provided by enclosure element.
* platform/chromium/TestExpectations: Fail video controls tests.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@120040 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/fullscreen/video-controls-override-expected.txt
LayoutTests/fullscreen/video-controls-override.html
LayoutTests/media/media-controls-invalid-url.html
LayoutTests/media/track/track-cue-rendering-snap-to-lines-not-set.html
LayoutTests/platform/chromium/TestExpectations
Source/WebCore/ChangeLog
Source/WebCore/css/mediaControlsChromium.css
Source/WebCore/html/shadow/MediaControlRootElementChromium.cpp
Source/WebCore/html/shadow/MediaControlRootElementChromium.h