Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
2011-02-15 Jer Noble <jer.noble@apple.com>
Reviewed by Darin Adler. Built-in HTML5 <audio> (and sometimes <video>) UI doesn't update playhead location or time displays https://bugs.webkit.org/show_bug.cgi?id=46142 Added a repaint test which ensures the timeline controls repaint in an audio-only MediaDocument. Since the change also affects in-page audio, also added a repaint test for those cases as well. Other platforms will need to have results generated. * media/audio-repaint.html: Added. * media/media-document-audio-repaint-expected.txt: Added. * media/media-document-audio-repaint.html: Added. * platform/mac/media/audio-repaint-expected.checksum: Added. * platform/mac/media/audio-repaint-expected.png: Added. * platform/mac/media/audio-repaint-expected.txt: Added. * platform/mac/media/media-document-audio-repaint-expected.checksum: Added. * platform/mac/media/media-document-audio-repaint-expected.png: Added. 2011-02-15 Jer Noble <jer.noble@apple.com> Reviewed by Darin Adler. Built-in HTML5 <audio> (and sometimes <video>) UI doesn't update playhead location or time displays https://bugs.webkit.org/show_bug.cgi?id=46142 Push a LayoutStateMaintainer in RenderMedia::layout() before calling layout() on the container elements. This is necessary because, during layout(), the child renderers query the current LayoutState to determine where they will be repainting. If a new LayoutState is not pushed here, child renderers will attempt to repaint relative to their grandparent's origin instead of their parents', and repaint operations will fail. * rendering/RenderMedia.cpp: (WebCore::RenderMedia::layout): Canonical link: https://commits.webkit.org/69241@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@79318 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- Loading branch information
Showing
with
184 additions
and 9 deletions.
- +21 −0 LayoutTests/ChangeLog
- +48 −0 LayoutTests/media/audio-repaint-expected.txt
- +19 −0 LayoutTests/media/audio-repaint.html
- +41 −0 LayoutTests/media/media-document-audio-repaint-expected.txt
- +20 −0 LayoutTests/media/media-document-audio-repaint.html
- +1 −0 LayoutTests/platform/mac/media/audio-repaint-expected.checksum
- BIN LayoutTests/platform/mac/media/audio-repaint-expected.png
- +1 −0 LayoutTests/platform/mac/media/media-document-audio-repaint-expected.checksum
- BIN LayoutTests/platform/mac/media/media-document-audio-repaint-expected.png
- +16 −0 Source/WebCore/ChangeLog
- +17 −9 Source/WebCore/rendering/RenderMedia.cpp
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -0,0 +1,48 @@ | ||
layer at (0,0) size 800x600 | ||
RenderView at (0,0) size 800x600 | ||
layer at (0,0) size 800x600 | ||
RenderBlock {HTML} at (0,0) size 800x600 | ||
RenderBody {BODY} at (8,8) size 784x584 | ||
RenderBlock {P} at (0,0) size 784x18 | ||
RenderText {#text} at (0,0) size 741x18 | ||
text run at (0,0) width 651: "This tests that in a standalone media document with audio content, the media element repaints correctly " | ||
text run at (651,0) width 90: "while playing." | ||
RenderBlock (anonymous) at (0,34) size 784x154 | ||
RenderMedia {AUDIO} at (0,0) size 200x25 | ||
RenderBR {BR} at (200,25) size 0x0 | ||
RenderBR {BR} at (200,75) size 0x0 | ||
RenderBR {BR} at (200,154) size 0x0 | ||
layer at (8,67) size 200x25 | ||
RenderMedia {AUDIO} at (0,25) size 200x25 | ||
layer at (8,67) size 200x25 | ||
RenderBlock (relative positioned) {DIV} at (0,0) size 200x25 | ||
layer at (8,67) size 200x25 | ||
RenderFlexibleBox (positioned) {DIV} at (0,0) size 200x25 | ||
RenderButton {INPUT} at (6,3) size 18x18 | ||
RenderButton {INPUT} at (32,4) size 16x16 | ||
RenderFlexibleBox {DIV} at (49,1) size 126x22 | ||
RenderSlider {INPUT} at (0,5) size 126x13 | ||
RenderBlock {DIV} at (18,2) size 10x8 | ||
RenderButton {INPUT} at (177,6) size 14x12 | ||
layer at (8,42) size 200x25 | ||
RenderBlock (relative positioned) {DIV} at (0,0) size 200x25 | ||
layer at (8,42) size 200x25 | ||
RenderFlexibleBox (positioned) {DIV} at (0,0) size 200x25 | ||
RenderButton {INPUT} at (6,3) size 18x18 | ||
RenderButton {INPUT} at (32,4) size 16x16 | ||
RenderFlexibleBox {DIV} at (49,1) size 126x22 | ||
RenderSlider {INPUT} at (0,5) size 126x13 | ||
RenderBlock {DIV} at (18,2) size 10x8 | ||
RenderButton {INPUT} at (177,6) size 14x12 | ||
layer at (8,144) size 200x25 | ||
RenderMedia {AUDIO} at (0,102) size 200x25 | ||
layer at (8,144) size 200x25 | ||
RenderBlock (relative positioned) {DIV} at (0,0) size 200x25 | ||
layer at (8,144) size 200x25 | ||
RenderFlexibleBox (positioned) {DIV} at (0,0) size 200x25 | ||
RenderButton {INPUT} at (6,3) size 18x18 | ||
RenderButton {INPUT} at (32,4) size 16x16 | ||
RenderFlexibleBox {DIV} at (49,1) size 126x22 | ||
RenderSlider {INPUT} at (0,5) size 126x13 | ||
RenderBlock {DIV} at (18,2) size 10x8 | ||
RenderButton {INPUT} at (177,6) size 14x12 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -0,0 +1,19 @@ | ||
<p> | ||
This tests that in a standalone media document with audio content, the media element repaints correctly | ||
while playing. | ||
</p> | ||
<audio controls autoplay src="content/test.wav"></audio><br/> | ||
<audio controls autoplay src="content/test.wav" style="margin-bottom:25px; -webkit-box-reflect:below;"></audio><br/> | ||
<audio controls autoplay src="content/test.wav" style="margin:27px 0; -webkit-transform: rotate(15deg);"></audio><br> | ||
<script> | ||
if (window.layoutTestController) | ||
layoutTestController.waitUntilDone(); | ||
|
||
if (window.layoutTestController) | ||
layoutTestController.display(); | ||
|
||
setTimeout(function() { | ||
if (window.layoutTestController) | ||
layoutTestController.notifyDone(); | ||
}, 1500); | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -0,0 +1,41 @@ | ||
layer at (0,0) size 800x600 | ||
RenderView at (0,0) size 800x600 | ||
layer at (0,0) size 800x600 | ||
RenderBlock {HTML} at (0,0) size 800x600 | ||
RenderBody {BODY} at (8,8) size 784x584 | ||
RenderBlock {P} at (0,0) size 784x18 | ||
RenderText {#text} at (0,0) size 741x18 | ||
text run at (0,0) width 651: "This tests that in a standalone media document with audio content, the media element repaints correctly " | ||
text run at (651,0) width 90: "while playing." | ||
RenderBlock (anonymous) at (0,34) size 784x334 | ||
RenderText {#text} at (0,0) size 0x0 | ||
RenderText {#text} at (0,0) size 0x0 | ||
layer at (8,42) size 384x334 | ||
RenderPartObject {IFRAME} at (0,0) size 384x334 [border: (2px inset #000000)] | ||
layer at (0,0) size 380x330 | ||
RenderView at (0,0) size 380x330 | ||
layer at (0,0) size 380x330 | ||
RenderBlock {HTML} at (0,0) size 380x330 | ||
RenderBody {BODY} at (8,8) size 364x314 [bgcolor=#262626] | ||
layer at (40,164) size 300x1 | ||
RenderVideo {VIDEO} at (40,164) size 300x1 | ||
layer at (40,164) size 300x1 | ||
RenderBlock (relative positioned) {DIV} at (0,0) size 300x1 | ||
layer at (40,165) size 300x25 | ||
RenderFlexibleBox (positioned) {DIV} at (0,1) size 300x25 | ||
RenderButton {INPUT} at (6,3) size 18x18 | ||
RenderButton {INPUT} at (32,4) size 16x16 | ||
RenderFlexibleBox {DIV} at (49,5) size 226x15 | ||
RenderSlider {INPUT} at (45,2) size 136x13 | ||
RenderBlock {DIV} at (23,2) size 10x8 | ||
RenderButton {INPUT} at (277,6) size 14x12 | ||
layer at (89,172) size 45x11 | ||
RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF] | ||
RenderBlock (anonymous) at (9,0) size 26x11 | ||
RenderText {#text} at (0,0) size 26x11 | ||
text run at (0,0) width 26: "00:01" | ||
layer at (270,172) size 45x11 | ||
RenderFlexibleBox {DIV} at (181,2) size 45x11 [color=#FFFFFF] | ||
RenderBlock (anonymous) at (7,0) size 31x11 | ||
RenderText {#text} at (0,0) size 31x11 | ||
text run at (0,0) width 31: "-00:06" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -0,0 +1,20 @@ | ||
<p> | ||
This tests that in a standalone media document with audio content, the media element repaints correctly | ||
while playing. | ||
</p> | ||
<iframe src="content/test.wav" width=380 height=330 onload="frameLoaded()"></iframe> | ||
<script> | ||
if (window.layoutTestController) | ||
layoutTestController.waitUntilDone(); | ||
|
||
function frameLoaded() | ||
{ | ||
if (window.layoutTestController) | ||
layoutTestController.display(); | ||
|
||
setTimeout(function() { | ||
if (window.layoutTestController) | ||
layoutTestController.notifyDone(); | ||
}, 1500); | ||
} | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -0,0 +1 @@ | ||
6b05a8d77b8da28f5dca1e2800b1738e |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -0,0 +1 @@ | ||
9d3b8f0d93b62576cfeb140f2c2d62e8 |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters