Title: [145588] trunk
Revision
145588
Author
commit-qu...@webkit.org
Date
2013-03-12 14:53:19 -0700 (Tue, 12 Mar 2013)

Log Message

Mac: Incorrect rendering of <audio> controls
https://bugs.webkit.org/show_bug.cgi?id=110913

Patch by Christian Biesinger <cbiesin...@chromium.org> on 2013-03-12
Reviewed by Tony Chang.

Source/WebCore:

Covered by existing tests under media/.

* css/mediaControls.css:
(audio::-webkit-media-controls-timeline-container, video::-webkit-media-controls-timeline-container):
(audio::-webkit-media-controls-timeline, video::-webkit-media-controls-timeline):
The timeline container and the timeline need min-width: 0 so that they can shrink if needed.
* css/mediaControlsQuickTime.css:
(audio::-webkit-media-controls-timeline-container, video::-webkit-media-controls-timeline-container):
(audio::-webkit-media-controls-current-time-display, video::-webkit-media-controls-current-time-display):
(audio::-webkit-media-controls-time-remaining-display, video::-webkit-media-controls-time-remaining-display):
The timeline container also needs flex-start to ensure that it never overlaps
the play/rewind buttons. The current-time and remaining-time displays need min-width: 0 so that the hack
in RenderMediaControls.cpp works correctly - otherwise, RenderFlexibleBox tries to use the preferred width
of the time displays, which is wrong when they try to hide themselves.

LayoutTests:

* platform/mac/media/audio-controls-rendering-expected.txt:
* platform/mac/media/controls-after-reload-expected.txt:
* platform/mac/media/controls-strict-expected.txt:
* platform/mac/media/controls-styling-strict-expected.txt:
* platform/mac/media/controls-without-preload-expected.txt:
* platform/mac/media/video-controls-rendering-expected.txt:
* platform/mac/media/video-display-toggle-expected.txt:
* platform/mac/media/video-no-audio-expected.txt:
* platform/mac/media/video-playing-and-pause-expected.txt:

Modified Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (145587 => 145588)


--- trunk/LayoutTests/ChangeLog	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/LayoutTests/ChangeLog	2013-03-12 21:53:19 UTC (rev 145588)
@@ -1,3 +1,20 @@
+2013-03-12  Christian Biesinger  <cbiesin...@chromium.org>
+
+        Mac: Incorrect rendering of <audio> controls
+        https://bugs.webkit.org/show_bug.cgi?id=110913
+
+        Reviewed by Tony Chang.
+
+        * platform/mac/media/audio-controls-rendering-expected.txt:
+        * platform/mac/media/controls-after-reload-expected.txt:
+        * platform/mac/media/controls-strict-expected.txt:
+        * platform/mac/media/controls-styling-strict-expected.txt:
+        * platform/mac/media/controls-without-preload-expected.txt:
+        * platform/mac/media/video-controls-rendering-expected.txt:
+        * platform/mac/media/video-display-toggle-expected.txt:
+        * platform/mac/media/video-no-audio-expected.txt:
+        * platform/mac/media/video-playing-and-pause-expected.txt:
+
 2013-03-12  Ryosuke Niwa  <rn...@webkit.org>
 
         Some canvas tests only fail on Mac EWS

Modified: trunk/LayoutTests/platform/mac/media/audio-controls-rendering-expected.txt (145587 => 145588)


--- trunk/LayoutTests/platform/mac/media/audio-controls-rendering-expected.txt	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/LayoutTests/platform/mac/media/audio-controls-rendering-expected.txt	2013-03-12 21:53:19 UTC (rev 145588)
@@ -20,23 +20,13 @@
   RenderFlexibleBox {DIV} at (0,0) size 200x25
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
-    RenderFlexibleBox {DIV} at (49,5) size 219x15
-      RenderSlider {INPUT} at (45,2) size 129x13
-        RenderFlexibleBox {DIV} at (0,0) size 129x13
-          RenderBlock {DIV} at (0,2) size 129x9
+    RenderFlexibleBox {DIV} at (49,5) size 126x15
+      RenderSlider {INPUT} at (0,2) size 126x13
+        RenderFlexibleBox {DIV} at (0,0) size 126x13
+          RenderBlock {DIV} at (0,2) size 126x9
             RenderBlock {DIV} at (0,0) size 10x8
-    RenderBlock {DIV} at (268,6) size 25x13
-layer at (57,49) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (231,49) size 45x11
-  RenderFlexibleBox {DIV} at (174,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:07"
-layer at (278,49) size 14x12
+    RenderBlock {DIV} at (175,6) size 25x13
+layer at (185,49) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12
 layer at (8,85) size 320x25
   RenderFlexibleBox {DIV} at (0,0) size 320x25
@@ -45,21 +35,11 @@
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
     RenderFlexibleBox {DIV} at (49,5) size 246x15
-      RenderSlider {INPUT} at (45,2) size 156x13
-        RenderFlexibleBox {DIV} at (0,0) size 156x13
-          RenderBlock {DIV} at (0,2) size 156x9
+      RenderSlider {INPUT} at (0,2) size 246x13
+        RenderFlexibleBox {DIV} at (0,0) size 246x13
+          RenderBlock {DIV} at (0,2) size 246x9
             RenderBlock {DIV} at (0,0) size 10x8
     RenderBlock {DIV} at (295,6) size 25x13
-layer at (57,92) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (258,92) size 45x11
-  RenderFlexibleBox {DIV} at (201,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:07"
 layer at (305,92) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12
 layer at (8,128) size 320x100
@@ -71,20 +51,10 @@
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
     RenderFlexibleBox {DIV} at (49,5) size 246x15
-      RenderSlider {INPUT} at (45,2) size 156x13
-        RenderFlexibleBox {DIV} at (0,0) size 156x13
-          RenderBlock {DIV} at (0,2) size 156x9
+      RenderSlider {INPUT} at (0,2) size 246x13
+        RenderFlexibleBox {DIV} at (0,0) size 246x13
+          RenderBlock {DIV} at (0,2) size 246x9
             RenderBlock {DIV} at (0,0) size 10x8
     RenderBlock {DIV} at (295,6) size 25x13
-layer at (57,210) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (258,210) size 45x11
-  RenderFlexibleBox {DIV} at (201,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:07"
 layer at (305,210) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12

Modified: trunk/LayoutTests/platform/mac/media/controls-after-reload-expected.txt (145587 => 145588)


--- trunk/LayoutTests/platform/mac/media/controls-after-reload-expected.txt	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/LayoutTests/platform/mac/media/controls-after-reload-expected.txt	2013-03-12 21:53:19 UTC (rev 145588)
@@ -16,22 +16,12 @@
   RenderFlexibleBox {DIV} at (0,215) size 320x25
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
-    RenderFlexibleBox {DIV} at (49,5) size 219x15
-      RenderSlider {INPUT} at (45,2) size 129x13
-        RenderFlexibleBox {DIV} at (0,0) size 129x13
-          RenderBlock {DIV} at (0,2) size 129x9
+    RenderFlexibleBox {DIV} at (49,5) size 216x15
+      RenderSlider {INPUT} at (0,2) size 216x13
+        RenderFlexibleBox {DIV} at (0,0) size 216x13
+          RenderBlock {DIV} at (0,2) size 216x9
             RenderBlock {DIV} at (0,0) size 10x8
-    RenderButton {INPUT} at (300,4) size 16x17
-    RenderBlock {DIV} at (268,6) size 25x13
-layer at (57,264) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (231,264) size 45x11
-  RenderFlexibleBox {DIV} at (174,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"
-layer at (278,264) size 14x12
+    RenderButton {INPUT} at (297,4) size 16x17
+    RenderBlock {DIV} at (265,6) size 25x13
+layer at (275,264) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12

Modified: trunk/LayoutTests/platform/mac/media/controls-strict-expected.txt (145587 => 145588)


--- trunk/LayoutTests/platform/mac/media/controls-strict-expected.txt	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/LayoutTests/platform/mac/media/controls-strict-expected.txt	2013-03-12 21:53:19 UTC (rev 145588)
@@ -16,22 +16,12 @@
   RenderFlexibleBox {DIV} at (0,215) size 320x25
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
-    RenderFlexibleBox {DIV} at (49,5) size 219x15
-      RenderSlider {INPUT} at (45,2) size 129x13
-        RenderFlexibleBox {DIV} at (0,0) size 129x13
-          RenderBlock {DIV} at (0,2) size 129x9
+    RenderFlexibleBox {DIV} at (49,5) size 216x15
+      RenderSlider {INPUT} at (0,2) size 216x13
+        RenderFlexibleBox {DIV} at (0,0) size 216x13
+          RenderBlock {DIV} at (0,2) size 216x9
             RenderBlock {DIV} at (0,0) size 10x8
-    RenderButton {INPUT} at (300,4) size 16x17
-    RenderBlock {DIV} at (268,6) size 25x13
-layer at (57,272) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (231,272) size 45x11
-  RenderFlexibleBox {DIV} at (174,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"
-layer at (278,272) size 14x12
+    RenderButton {INPUT} at (297,4) size 16x17
+    RenderBlock {DIV} at (265,6) size 25x13
+layer at (275,272) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12

Modified: trunk/LayoutTests/platform/mac/media/controls-styling-strict-expected.txt (145587 => 145588)


--- trunk/LayoutTests/platform/mac/media/controls-styling-strict-expected.txt	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/LayoutTests/platform/mac/media/controls-styling-strict-expected.txt	2013-03-12 21:53:19 UTC (rev 145588)
@@ -20,24 +20,14 @@
   RenderFlexibleBox {DIV} at (0,215) size 320x25
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
-    RenderFlexibleBox {DIV} at (49,5) size 219x15
-      RenderSlider {INPUT} at (45,2) size 129x13
-        RenderFlexibleBox {DIV} at (0,0) size 129x13
-          RenderBlock {DIV} at (0,2) size 129x9
+    RenderFlexibleBox {DIV} at (49,5) size 216x15
+      RenderSlider {INPUT} at (0,2) size 216x13
+        RenderFlexibleBox {DIV} at (0,0) size 216x13
+          RenderBlock {DIV} at (0,2) size 216x9
             RenderBlock {DIV} at (0,0) size 10x8
-    RenderButton {INPUT} at (300,4) size 16x17
-    RenderBlock {DIV} at (268,6) size 25x13
-layer at (57,272) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (231,272) size 45x11
-  RenderFlexibleBox {DIV} at (174,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"
-layer at (278,272) size 14x12
+    RenderButton {INPUT} at (297,4) size 16x17
+    RenderBlock {DIV} at (265,6) size 25x13
+layer at (275,272) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12
 layer at (332,50) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
@@ -45,22 +35,12 @@
   RenderFlexibleBox {DIV} at (0,215) size 320x25
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
-    RenderFlexibleBox {DIV} at (49,5) size 219x15
-      RenderSlider {INPUT} at (45,2) size 129x13
-        RenderFlexibleBox {DIV} at (0,0) size 129x13
-          RenderBlock {DIV} at (0,2) size 129x9
+    RenderFlexibleBox {DIV} at (49,5) size 216x15
+      RenderSlider {INPUT} at (0,2) size 216x13
+        RenderFlexibleBox {DIV} at (0,0) size 216x13
+          RenderBlock {DIV} at (0,2) size 216x9
             RenderBlock {DIV} at (0,0) size 10x8
-    RenderButton {INPUT} at (300,4) size 16x17
-    RenderBlock {DIV} at (268,6) size 25x13
-layer at (381,272) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (555,272) size 45x11
-  RenderFlexibleBox {DIV} at (174,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"
-layer at (602,272) size 14x12
+    RenderButton {INPUT} at (297,4) size 16x17
+    RenderBlock {DIV} at (265,6) size 25x13
+layer at (599,272) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12

Modified: trunk/LayoutTests/platform/mac/media/controls-without-preload-expected.txt (145587 => 145588)


--- trunk/LayoutTests/platform/mac/media/controls-without-preload-expected.txt	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/LayoutTests/platform/mac/media/controls-without-preload-expected.txt	2013-03-12 21:53:19 UTC (rev 145588)
@@ -16,22 +16,12 @@
   RenderFlexibleBox {DIV} at (0,215) size 320x25
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
-    RenderFlexibleBox {DIV} at (49,5) size 219x15
-      RenderSlider {INPUT} at (45,2) size 129x13
-        RenderFlexibleBox {DIV} at (0,0) size 129x13
-          RenderBlock {DIV} at (0,2) size 129x9
+    RenderFlexibleBox {DIV} at (49,5) size 216x15
+      RenderSlider {INPUT} at (0,2) size 216x13
+        RenderFlexibleBox {DIV} at (0,0) size 216x13
+          RenderBlock {DIV} at (0,2) size 216x9
             RenderBlock {DIV} at (0,0) size 10x8
-    RenderButton {INPUT} at (300,4) size 16x17
-    RenderBlock {DIV} at (268,6) size 25x13
-layer at (57,264) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (231,264) size 45x11
-  RenderFlexibleBox {DIV} at (174,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"
-layer at (278,264) size 14x12
+    RenderButton {INPUT} at (297,4) size 16x17
+    RenderBlock {DIV} at (265,6) size 25x13
+layer at (275,264) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12

Modified: trunk/LayoutTests/platform/mac/media/video-controls-rendering-expected.txt (145587 => 145588)


--- trunk/LayoutTests/platform/mac/media/video-controls-rendering-expected.txt	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/LayoutTests/platform/mac/media/video-controls-rendering-expected.txt	2013-03-12 21:53:19 UTC (rev 145588)
@@ -21,24 +21,14 @@
   RenderFlexibleBox {DIV} at (0,215) size 320x25
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
-    RenderFlexibleBox {DIV} at (49,5) size 219x15
-      RenderSlider {INPUT} at (45,2) size 129x13
-        RenderFlexibleBox {DIV} at (0,0) size 129x13
-          RenderBlock {DIV} at (0,2) size 129x9
+    RenderFlexibleBox {DIV} at (49,5) size 216x15
+      RenderSlider {INPUT} at (0,2) size 216x13
+        RenderFlexibleBox {DIV} at (0,0) size 216x13
+          RenderBlock {DIV} at (0,2) size 216x9
             RenderBlock {DIV} at (0,0) size 10x8
-    RenderButton {INPUT} at (300,4) size 16x17
-    RenderBlock {DIV} at (268,6) size 25x13
-layer at (57,264) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (231,264) size 45x11
-  RenderFlexibleBox {DIV} at (174,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"
-layer at (278,264) size 14x12
+    RenderButton {INPUT} at (297,4) size 16x17
+    RenderBlock {DIV} at (265,6) size 25x13
+layer at (275,264) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12
 layer at (8,282) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
@@ -46,24 +36,14 @@
   RenderFlexibleBox {DIV} at (0,215) size 320x25
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
-    RenderFlexibleBox {DIV} at (49,5) size 219x15
-      RenderSlider {INPUT} at (45,2) size 129x13
-        RenderFlexibleBox {DIV} at (0,0) size 129x13
-          RenderBlock {DIV} at (0,2) size 129x9
+    RenderFlexibleBox {DIV} at (49,5) size 216x15
+      RenderSlider {INPUT} at (0,2) size 216x13
+        RenderFlexibleBox {DIV} at (0,0) size 216x13
+          RenderBlock {DIV} at (0,2) size 216x9
             RenderBlock {DIV} at (0,0) size 10x8
-    RenderButton {INPUT} at (300,4) size 16x17
-    RenderBlock {DIV} at (268,6) size 25x13
-layer at (57,504) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (231,504) size 45x11
-  RenderFlexibleBox {DIV} at (174,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"
-layer at (278,504) size 14x12
+    RenderButton {INPUT} at (297,4) size 16x17
+    RenderBlock {DIV} at (265,6) size 25x13
+layer at (275,504) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12
 layer at (8,522) size 320x240
   RenderVideo {VIDEO} at (8,522) size 320x240
@@ -73,22 +53,12 @@
   RenderFlexibleBox {DIV} at (0,215) size 320x25
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
-    RenderFlexibleBox {DIV} at (49,5) size 219x15
-      RenderSlider {INPUT} at (45,2) size 129x13
-        RenderFlexibleBox {DIV} at (0,0) size 129x13
-          RenderBlock {DIV} at (0,2) size 129x9
+    RenderFlexibleBox {DIV} at (49,5) size 216x15
+      RenderSlider {INPUT} at (0,2) size 216x13
+        RenderFlexibleBox {DIV} at (0,0) size 216x13
+          RenderBlock {DIV} at (0,2) size 216x9
             RenderBlock {DIV} at (0,0) size 10x8
-    RenderButton {INPUT} at (300,4) size 16x17
-    RenderBlock {DIV} at (268,6) size 25x13
-layer at (57,744) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (231,744) size 45x11
-  RenderFlexibleBox {DIV} at (174,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"
-layer at (278,744) size 14x12
+    RenderButton {INPUT} at (297,4) size 16x17
+    RenderBlock {DIV} at (265,6) size 25x13
+layer at (275,744) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12

Modified: trunk/LayoutTests/platform/mac/media/video-display-toggle-expected.txt (145587 => 145588)


--- trunk/LayoutTests/platform/mac/media/video-display-toggle-expected.txt	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/LayoutTests/platform/mac/media/video-display-toggle-expected.txt	2013-03-12 21:53:19 UTC (rev 145588)
@@ -15,22 +15,12 @@
   RenderFlexibleBox {DIV} at (0,215) size 320x25
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
-    RenderFlexibleBox {DIV} at (49,5) size 219x15
-      RenderSlider {INPUT} at (45,2) size 129x13
-        RenderFlexibleBox {DIV} at (0,0) size 129x13
-          RenderBlock {DIV} at (0,2) size 129x9
+    RenderFlexibleBox {DIV} at (49,5) size 216x15
+      RenderSlider {INPUT} at (0,2) size 216x13
+        RenderFlexibleBox {DIV} at (0,0) size 216x13
+          RenderBlock {DIV} at (0,2) size 216x9
             RenderBlock {DIV} at (0,0) size 10x8
-    RenderButton {INPUT} at (300,4) size 16x17
-    RenderBlock {DIV} at (268,6) size 25x13
-layer at (57,248) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (231,248) size 45x11
-  RenderFlexibleBox {DIV} at (174,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"
-layer at (278,248) size 14x12
+    RenderButton {INPUT} at (297,4) size 16x17
+    RenderBlock {DIV} at (265,6) size 25x13
+layer at (275,248) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12

Modified: trunk/LayoutTests/platform/mac/media/video-no-audio-expected.txt (145587 => 145588)


--- trunk/LayoutTests/platform/mac/media/video-no-audio-expected.txt	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/LayoutTests/platform/mac/media/video-no-audio-expected.txt	2013-03-12 21:53:19 UTC (rev 145588)
@@ -17,19 +17,9 @@
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
     RenderFlexibleBox {DIV} at (49,5) size 273x15
-      RenderSlider {INPUT} at (45,2) size 183x13
-        RenderFlexibleBox {DIV} at (0,0) size 183x13
-          RenderBlock {DIV} at (0,2) size 183x9
+      RenderSlider {INPUT} at (0,2) size 273x13
+        RenderFlexibleBox {DIV} at (0,0) size 273x13
+          RenderBlock {DIV} at (0,2) size 273x9
             RenderBlock {DIV} at (0,0) size 10x8
     RenderButton {INPUT} at (329,4) size 16x17
     RenderBlock {DIV} at (322,12) size 0x1
-layer at (57,312) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (285,312) size 45x11
-  RenderFlexibleBox {DIV} at (228,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:09"

Modified: trunk/LayoutTests/platform/mac/media/video-playing-and-pause-expected.txt (145587 => 145588)


--- trunk/LayoutTests/platform/mac/media/video-playing-and-pause-expected.txt	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/LayoutTests/platform/mac/media/video-playing-and-pause-expected.txt	2013-03-12 21:53:19 UTC (rev 145588)
@@ -17,22 +17,12 @@
   RenderFlexibleBox {DIV} at (0,215) size 320x25
     RenderButton {INPUT} at (6,3) size 18x18
     RenderButton {INPUT} at (32,4) size 16x17
-    RenderFlexibleBox {DIV} at (49,5) size 219x15
-      RenderSlider {INPUT} at (45,2) size 129x13
-        RenderFlexibleBox {DIV} at (0,0) size 129x13
-          RenderBlock {DIV} at (0,2) size 129x9
+    RenderFlexibleBox {DIV} at (49,5) size 216x15
+      RenderSlider {INPUT} at (0,2) size 216x13
+        RenderFlexibleBox {DIV} at (0,0) size 216x13
+          RenderBlock {DIV} at (0,2) size 216x9
             RenderBlock {DIV} at (0,0) size 10x8
-    RenderButton {INPUT} at (300,4) size 16x17
-    RenderBlock {DIV} at (268,6) size 25x13
-layer at (57,290) size 45x11
-  RenderFlexibleBox {DIV} at (0,2) size 45x11 [color=#FFFFFF]
-    RenderBlock (anonymous) at (9,0) size 27x11
-      RenderText {#text} at (0,0) size 26x11
-        text run at (0,0) width 26: "00:00"
-layer at (231,290) size 45x11
-  RenderFlexibleBox {DIV} at (174,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"
-layer at (278,290) size 14x12
+    RenderButton {INPUT} at (297,4) size 16x17
+    RenderBlock {DIV} at (265,6) size 25x13
+layer at (275,290) size 14x12
   RenderButton zI: 1 {INPUT} at (2,0) size 14x12

Modified: trunk/Source/WebCore/ChangeLog (145587 => 145588)


--- trunk/Source/WebCore/ChangeLog	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/Source/WebCore/ChangeLog	2013-03-12 21:53:19 UTC (rev 145588)
@@ -1,3 +1,25 @@
+2013-03-12  Christian Biesinger  <cbiesin...@chromium.org>
+
+        Mac: Incorrect rendering of <audio> controls
+        https://bugs.webkit.org/show_bug.cgi?id=110913
+
+        Reviewed by Tony Chang.
+
+        Covered by existing tests under media/.
+
+        * css/mediaControls.css:
+        (audio::-webkit-media-controls-timeline-container, video::-webkit-media-controls-timeline-container):
+        (audio::-webkit-media-controls-timeline, video::-webkit-media-controls-timeline):
+        The timeline container and the timeline need min-width: 0 so that they can shrink if needed.
+        * css/mediaControlsQuickTime.css:
+        (audio::-webkit-media-controls-timeline-container, video::-webkit-media-controls-timeline-container):
+        (audio::-webkit-media-controls-current-time-display, video::-webkit-media-controls-current-time-display):
+        (audio::-webkit-media-controls-time-remaining-display, video::-webkit-media-controls-time-remaining-display):
+        The timeline container also needs flex-start to ensure that it never overlaps
+        the play/rewind buttons. The current-time and remaining-time displays need min-width: 0 so that the hack
+        in RenderMediaControls.cpp works correctly - otherwise, RenderFlexibleBox tries to use the preferred width
+        of the time displays, which is wrong when they try to hide themselves.
+
 2013-03-12  Alexey Proskuryakov  <a...@apple.com>
 
         Improve logging in ResourceHandleMac.mm

Modified: trunk/Source/WebCore/css/mediaControls.css (145587 => 145588)


--- trunk/Source/WebCore/css/mediaControls.css	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/Source/WebCore/css/mediaControls.css	2013-03-12 21:53:19 UTC (rev 145588)
@@ -104,6 +104,7 @@
     -webkit-flex: 1 1;
     -webkit-user-select: none;
     height: 16px;
+    min-width: 0;
 }
 
 audio::-webkit-media-controls-current-time-display, video::-webkit-media-controls-current-time-display {
@@ -124,6 +125,7 @@
     border: initial;
     color: inherit;
     margin: initial;
+    min-width: 0;
 }
 
 audio::-webkit-media-controls-volume-slider, video::-webkit-media-controls-volume-slider {

Modified: trunk/Source/WebCore/css/mediaControlsQuickTime.css (145587 => 145588)


--- trunk/Source/WebCore/css/mediaControlsQuickTime.css	2013-03-12 21:51:39 UTC (rev 145587)
+++ trunk/Source/WebCore/css/mediaControlsQuickTime.css	2013-03-12 21:53:19 UTC (rev 145588)
@@ -65,7 +65,7 @@
     -webkit-appearance: none;
     -webkit-flex-direction: row;
     -webkit-align-items: center;
-    -webkit-justify-content: center;
+    -webkit-justify-content: flex-start;
     -webkit-flex: 1 1;
     text-align: right;
     height: auto;
@@ -82,6 +82,7 @@
     font-size: 9px;
     overflow: hidden;
     width: 45px;
+    min-width: 0; /* needed due to flexbox */
     color: white;
     text-shadow: black 0px 1px 1px;
 
@@ -104,6 +105,7 @@
     font-size: 9px;
     overflow: hidden;
     width: 45px;
+    min-width: 0; /* needed due to flexbox */
     color: white;
     text-shadow: black 0px 1px 1px;
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to