Title: [175268] trunk
Revision
175268
Author
[email protected]
Date
2014-10-28 12:37:22 -0700 (Tue, 28 Oct 2014)

Log Message

REGRESSION(r171593) [Mac] Media controls create a large (and unnecessary) backing store
https://bugs.webkit.org/show_bug.cgi?id=137757

Reviewed by Eric Carlson.

Source/WebCore:

In r171593, a <div> was added to the media controls which is only ever used on iOS. Instead
of creating and adding this <div> in mediaControlsApple.js (which is used on OS X), this
<div> should be created and added in mediaControlsiOS.js, which requires overloading
Controller.addControls.

* Modules/mediacontrols/mediaControlsApple.css:
(audio::-webkit-media-controls-panel.hidden): Drive-by fix: allow the panel itself to be hidden.
(video::-webkit-media-controls-panel-composited-parent): Deleted.
* Modules/mediacontrols/mediaControlsApple.js:
(Controller.prototype.createControls): Remove the composited parent.
(Controller.prototype.addControls): Ditto.
* Modules/mediacontrols/mediaControlsiOS.js:
(ControllerIOS.prototype.createControls): Create the composited parent.
(ControllerIOS.prototype.addControls): Copied from (previous) apple.js.

LayoutTests:

* platform/mac-mavericks/media/audio-controls-rendering-expected.png:
* platform/mac-mavericks/media/audio-controls-rendering-expected.txt:
* platform/mac-mavericks/media/controls-strict-expected.txt:
* platform/mac-mavericks/media/controls-without-preload-expected.txt: Copied from LayoutTests/platform/mac/media/controls-without-preload-expected.txt.
* platform/mac-mavericks/media/video-controls-rendering-expected.txt:
* platform/mac-mavericks/media/video-display-toggle-expected.txt:
* platform/mac-mavericks/media/video-empty-source-expected.txt: Copied from LayoutTests/platform/mac/media/video-empty-source-expected.txt.
* platform/mac-mavericks/media/video-no-audio-expected.png:
* platform/mac-mavericks/media/video-no-audio-expected.txt:
* platform/mac-mavericks/media/video-volume-slider-expected.txt:
* platform/mac-mavericks/media/video-zoom-controls-expected.png:
* platform/mac-mavericks/media/video-zoom-controls-expected.txt:
* platform/mac/fast/hidpi/video-controls-in-hidpi-expected.txt:
* platform/mac/fast/layers/video-layer-expected.txt:
* platform/mac/media/audio-controls-rendering-expected.png:
* platform/mac/media/audio-controls-rendering-expected.txt:
* platform/mac/media/controls-after-reload-expected.png:
* platform/mac/media/controls-after-reload-expected.txt:
* platform/mac/media/controls-strict-expected.png:
* platform/mac/media/controls-strict-expected.txt:
* platform/mac/media/controls-without-preload-expected.png:
* platform/mac/media/controls-without-preload-expected.txt:
* platform/mac/media/media-controls-clone-expected.png:
* platform/mac/media/media-controls-clone-expected.txt:
* platform/mac/media/video-controls-rendering-expected.png:
* platform/mac/media/video-controls-rendering-expected.txt:
* platform/mac/media/video-display-toggle-expected.png:
* platform/mac/media/video-display-toggle-expected.txt:
* platform/mac/media/video-empty-source-expected.png:
* platform/mac/media/video-empty-source-expected.txt:
* platform/mac/media/video-no-audio-expected.png:
* platform/mac/media/video-no-audio-expected.txt:
* platform/mac/media/video-volume-slider-expected.png:
* platform/mac/media/video-volume-slider-expected.txt:
* platform/mac/media/video-zoom-controls-expected.png:
* platform/mac/media/video-zoom-controls-expected.txt:

Modified Paths

Added Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (175267 => 175268)


--- trunk/LayoutTests/ChangeLog	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/ChangeLog	2014-10-28 19:37:22 UTC (rev 175268)
@@ -1,3 +1,47 @@
+2014-10-28  Jer Noble  <[email protected]>
+
+        REGRESSION(r171593) [Mac] Media controls create a large (and unnecessary) backing store
+        https://bugs.webkit.org/show_bug.cgi?id=137757
+
+        Reviewed by Eric Carlson.
+
+        * platform/mac-mavericks/media/audio-controls-rendering-expected.png:
+        * platform/mac-mavericks/media/audio-controls-rendering-expected.txt:
+        * platform/mac-mavericks/media/controls-strict-expected.txt:
+        * platform/mac-mavericks/media/controls-without-preload-expected.txt: Copied from LayoutTests/platform/mac/media/controls-without-preload-expected.txt.
+        * platform/mac-mavericks/media/video-controls-rendering-expected.txt:
+        * platform/mac-mavericks/media/video-display-toggle-expected.txt:
+        * platform/mac-mavericks/media/video-empty-source-expected.txt: Copied from LayoutTests/platform/mac/media/video-empty-source-expected.txt.
+        * platform/mac-mavericks/media/video-no-audio-expected.png:
+        * platform/mac-mavericks/media/video-no-audio-expected.txt:
+        * platform/mac-mavericks/media/video-volume-slider-expected.txt:
+        * platform/mac-mavericks/media/video-zoom-controls-expected.png:
+        * platform/mac-mavericks/media/video-zoom-controls-expected.txt:
+        * platform/mac/fast/hidpi/video-controls-in-hidpi-expected.txt:
+        * platform/mac/fast/layers/video-layer-expected.txt:
+        * platform/mac/media/audio-controls-rendering-expected.png:
+        * platform/mac/media/audio-controls-rendering-expected.txt:
+        * platform/mac/media/controls-after-reload-expected.png:
+        * platform/mac/media/controls-after-reload-expected.txt:
+        * platform/mac/media/controls-strict-expected.png:
+        * platform/mac/media/controls-strict-expected.txt:
+        * platform/mac/media/controls-without-preload-expected.png:
+        * platform/mac/media/controls-without-preload-expected.txt:
+        * platform/mac/media/media-controls-clone-expected.png:
+        * platform/mac/media/media-controls-clone-expected.txt:
+        * platform/mac/media/video-controls-rendering-expected.png:
+        * platform/mac/media/video-controls-rendering-expected.txt:
+        * platform/mac/media/video-display-toggle-expected.png:
+        * platform/mac/media/video-display-toggle-expected.txt:
+        * platform/mac/media/video-empty-source-expected.png:
+        * platform/mac/media/video-empty-source-expected.txt:
+        * platform/mac/media/video-no-audio-expected.png:
+        * platform/mac/media/video-no-audio-expected.txt:
+        * platform/mac/media/video-volume-slider-expected.png:
+        * platform/mac/media/video-volume-slider-expected.txt:
+        * platform/mac/media/video-zoom-controls-expected.png:
+        * platform/mac/media/video-zoom-controls-expected.txt:
+
 2014-10-28  Alexey Proskuryakov  <[email protected]>
 
         text-combine needs to center glyphs within the vertical area.

Modified: trunk/LayoutTests/platform/mac/fast/hidpi/video-controls-in-hidpi-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac/fast/hidpi/video-controls-in-hidpi-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/fast/hidpi/video-controls-in-hidpi-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -13,9 +13,7 @@
 layer at (8,26) size 300x150
   RenderFlexibleBox {DIV} at (0,0) size 300x150
 layer at (8,151) size 300x25
-  RenderBlock {DIV} at (0,125) size 300x25
-layer at (8,151) size 300x25
-  RenderFlexibleBox {DIV} at (0,0) size 300x25
+  RenderFlexibleBox {DIV} at (0,125) size 300x25
 layer at (14,156) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,156) size 16x16

Modified: trunk/LayoutTests/platform/mac/fast/layers/video-layer-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac/fast/layers/video-layer-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/fast/layers/video-layer-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -18,9 +18,7 @@
 layer at (59,111) size 300x150
   RenderFlexibleBox {DIV} at (1,1) size 300x150
 layer at (59,236) size 300x25
-  RenderBlock {DIV} at (0,125) size 300x25
-layer at (59,236) size 300x25
-  RenderFlexibleBox {DIV} at (0,0) size 300x25
+  RenderFlexibleBox {DIV} at (0,125) size 300x25
 layer at (65,241) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (91,241) size 16x16

Modified: trunk/LayoutTests/platform/mac/media/audio-controls-rendering-expected.png


(Binary files differ)

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


--- trunk/LayoutTests/platform/mac/media/audio-controls-rendering-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/media/audio-controls-rendering-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -16,7 +16,6 @@
         RenderBR {BR} at (0,86) size 0x18
 layer at (8,42) size 200x25
   RenderFlexibleBox {DIV} at (0,0) size 200x25
-    RenderBlock {DIV} at (0,0) size 200x25
 layer at (8,42) size 200x25
   RenderFlexibleBox {DIV} at (0,0) size 200x25
 layer at (14,47) size 16x16
@@ -55,7 +54,6 @@
   RenderButton {BUTTON} at (3,3) size 16x16 [color=#FFFFFF]
 layer at (8,85) size 320x25
   RenderFlexibleBox {DIV} at (0,0) size 320x25
-    RenderBlock {DIV} at (0,0) size 320x25
 layer at (8,85) size 320x25
   RenderFlexibleBox {DIV} at (0,0) size 320x25
 layer at (14,90) size 16x16
@@ -96,9 +94,8 @@
   RenderMedia {AUDIO} at (8,128) size 320x100 [bgcolor=#0000FF]
 layer at (8,128) size 320x100
   RenderFlexibleBox {DIV} at (0,0) size 320x100
-    RenderBlock {DIV} at (0,75) size 320x25
 layer at (8,203) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,75) size 320x25
 layer at (14,208) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,208) size 16x16

Modified: trunk/LayoutTests/platform/mac/media/controls-after-reload-expected.png


(Binary files differ)

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


--- trunk/LayoutTests/platform/mac/media/controls-after-reload-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/media/controls-after-reload-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -13,9 +13,7 @@
 layer at (8,42) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,257) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,257) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,262) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,262) size 16x16
@@ -24,14 +22,14 @@
   RenderFlexibleBox {DIV} at (49,7) size 217x12
 layer at (57,265) size 45x11
   RenderFlexibleBox {DIV} at (0,0) 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"
+    RenderBlock (anonymous) at (10,0) size 25x11
+      RenderText {#text} at (0,0) size 25x11
+        text run at (0,0) width 25: "00:00"
 layer at (229,265) size 45x11
   RenderFlexibleBox {DIV} at (172,0) 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"
+    RenderBlock (anonymous) at (8,0) size 29x11
+      RenderText {#text} at (0,0) size 29x11
+        text run at (0,0) width 29: "-00:06"
 layer at (104,266) size 123x9
   RenderFlexibleBox {DIV} at (47,1) size 123x9
     RenderSlider {INPUT} at (0,0) size 123x9 [color=#909090] [bgcolor=#4A4A4A]

Modified: trunk/LayoutTests/platform/mac/media/controls-strict-expected.png


(Binary files differ)

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


--- trunk/LayoutTests/platform/mac/media/controls-strict-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/media/controls-strict-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -13,9 +13,7 @@
 layer at (8,50) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,265) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,265) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,270) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,270) size 16x16

Modified: trunk/LayoutTests/platform/mac/media/controls-without-preload-expected.png


(Binary files differ)

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


--- trunk/LayoutTests/platform/mac/media/controls-without-preload-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/media/controls-without-preload-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -13,9 +13,7 @@
 layer at (8,42) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,257) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,257) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,262) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,262) size 16x16
@@ -24,14 +22,14 @@
   RenderFlexibleBox {DIV} at (49,7) size 217x12
 layer at (57,265) size 45x11
   RenderFlexibleBox {DIV} at (0,0) 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"
+    RenderBlock (anonymous) at (10,0) size 25x11
+      RenderText {#text} at (0,0) size 25x11
+        text run at (0,0) width 25: "00:00"
 layer at (229,265) size 45x11
   RenderFlexibleBox {DIV} at (172,0) 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"
+    RenderBlock (anonymous) at (8,0) size 29x11
+      RenderText {#text} at (0,0) size 29x11
+        text run at (0,0) width 29: "-00:06"
 layer at (104,266) size 123x9
   RenderFlexibleBox {DIV} at (47,1) size 123x9
     RenderSlider {INPUT} at (0,0) size 123x9 [color=#909090] [bgcolor=#4A4A4A]

Modified: trunk/LayoutTests/platform/mac/media/media-controls-clone-expected.png


(Binary files differ)

Modified: trunk/LayoutTests/platform/mac/media/media-controls-clone-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac/media/media-controls-clone-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/media/media-controls-clone-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -14,9 +14,7 @@
 layer at (8,8) size 300x150
   RenderFlexibleBox {DIV} at (0,0) size 300x150
 layer at (8,133) size 300x25
-  RenderBlock {DIV} at (0,125) size 300x25
-layer at (8,133) size 300x25
-  RenderFlexibleBox {DIV} at (0,0) size 300x25
+  RenderFlexibleBox {DIV} at (0,125) size 300x25
 layer at (14,138) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,138) size 16x16
@@ -27,7 +25,6 @@
   RenderFlexibleBox {DIV} at (2,0) size 110x9
 layer at (308,133) size 200x25
   RenderFlexibleBox {DIV} at (0,0) size 200x25
-    RenderBlock {DIV} at (0,0) size 200x25
 layer at (308,133) size 200x25
   RenderFlexibleBox {DIV} at (0,0) size 200x25
 layer at (314,138) size 16x16
@@ -41,9 +38,7 @@
 layer at (8,162) size 300x150
   RenderFlexibleBox {DIV} at (0,0) size 300x150
 layer at (8,287) size 300x25
-  RenderBlock {DIV} at (0,125) size 300x25
-layer at (8,287) size 300x25
-  RenderFlexibleBox {DIV} at (0,0) size 300x25
+  RenderFlexibleBox {DIV} at (0,125) size 300x25
 layer at (14,292) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,292) size 16x16
@@ -54,7 +49,6 @@
   RenderFlexibleBox {DIV} at (2,0) size 110x9
 layer at (308,287) size 200x25
   RenderFlexibleBox {DIV} at (0,0) size 200x25
-    RenderBlock {DIV} at (0,0) size 200x25
 layer at (308,287) size 200x25
   RenderFlexibleBox {DIV} at (0,0) size 200x25
 layer at (314,292) size 16x16

Modified: trunk/LayoutTests/platform/mac/media/video-controls-rendering-expected.png


(Binary files differ)

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


--- trunk/LayoutTests/platform/mac/media/video-controls-rendering-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/media/video-controls-rendering-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -18,9 +18,7 @@
 layer at (8,42) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,257) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,257) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,262) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,262) size 16x16
@@ -60,9 +58,7 @@
 layer at (8,282) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,497) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,497) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,502) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,502) size 16x16
@@ -104,9 +100,7 @@
 layer at (8,522) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,737) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,737) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,742) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,742) size 16x16

Modified: trunk/LayoutTests/platform/mac/media/video-display-toggle-expected.png


(Binary files differ)

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


--- trunk/LayoutTests/platform/mac/media/video-display-toggle-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/media/video-display-toggle-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -12,9 +12,7 @@
 layer at (8,26) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,241) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,241) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,246) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,246) size 16x16

Modified: trunk/LayoutTests/platform/mac/media/video-empty-source-expected.png


(Binary files differ)

Modified: trunk/LayoutTests/platform/mac/media/video-empty-source-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac/media/video-empty-source-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/media/video-empty-source-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -13,9 +13,7 @@
 layer at (9,43) size 300x150
   RenderFlexibleBox {DIV} at (1,1) size 300x150
 layer at (9,168) size 300x25
-  RenderBlock {DIV} at (0,125) size 300x25
-layer at (9,168) size 300x25
-  RenderFlexibleBox {DIV} at (0,0) size 300x25
+  RenderFlexibleBox {DIV} at (0,125) size 300x25
 layer at (58,169) size 138x25
   RenderBlock {DIV} at (49,0) size 138x26 [color=#FFFFFF]
     RenderText {#text} at (12,7) size 22x11

Modified: trunk/LayoutTests/platform/mac/media/video-no-audio-expected.png


(Binary files differ)

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


--- trunk/LayoutTests/platform/mac/media/video-no-audio-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/media/video-no-audio-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -13,9 +13,7 @@
 layer at (8,42) size 352x288
   RenderFlexibleBox {DIV} at (0,0) size 352x288
 layer at (8,305) size 352x25
-  RenderBlock {DIV} at (0,263) size 352x25
-layer at (8,305) size 352x25
-  RenderFlexibleBox {DIV} at (0,0) size 352x25
+  RenderFlexibleBox {DIV} at (0,263) size 352x25
 layer at (14,310) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,310) size 16x16

Modified: trunk/LayoutTests/platform/mac/media/video-volume-slider-expected.png


(Binary files differ)

Modified: trunk/LayoutTests/platform/mac/media/video-volume-slider-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac/media/video-volume-slider-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/media/video-volume-slider-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -18,9 +18,7 @@
 layer at (8,62) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,277) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,277) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,282) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,282) size 16x16

Modified: trunk/LayoutTests/platform/mac/media/video-zoom-controls-expected.png


(Binary files differ)

Modified: trunk/LayoutTests/platform/mac/media/video-zoom-controls-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac/media/video-zoom-controls-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac/media/video-zoom-controls-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -11,9 +11,7 @@
 layer at (57,85) size 240x180
   RenderFlexibleBox {DIV} at (0,0) size 240x180
 layer at (57,228) size 240x37
-  RenderBlock {DIV} at (0,142) size 240x38
-layer at (57,228) size 240x38
-  RenderFlexibleBox {DIV} at (0,0) size 240x38
+  RenderFlexibleBox {DIV} at (0,142) size 240x38
 layer at (66,234) size 24x24
   RenderButton {BUTTON} at (9,6) size 24x25 [color=#FFFFFF]
 layer at (105,235) size 24x24
@@ -50,9 +48,7 @@
 layer at (57,310) size 240x180
   RenderFlexibleBox {DIV} at (0,0) size 240x180
 layer at (57,453) size 240x37
-  RenderBlock {DIV} at (0,142) size 240x38
-layer at (57,453) size 240x38
-  RenderFlexibleBox {DIV} at (0,0) size 240x38
+  RenderFlexibleBox {DIV} at (0,142) size 240x38
 layer at (66,459) size 24x24
   RenderButton {BUTTON} at (9,6) size 24x25 [color=#FFFFFF]
 layer at (105,460) size 24x24

Modified: trunk/LayoutTests/platform/mac-mavericks/media/audio-controls-rendering-expected.png


(Binary files differ)

Modified: trunk/LayoutTests/platform/mac-mavericks/media/audio-controls-rendering-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac-mavericks/media/audio-controls-rendering-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac-mavericks/media/audio-controls-rendering-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -16,7 +16,6 @@
         RenderBR {BR} at (0,86) size 0x18
 layer at (8,42) size 200x25
   RenderFlexibleBox {DIV} at (0,0) size 200x25
-    RenderBlock {DIV} at (0,0) size 200x25
 layer at (8,42) size 200x25
   RenderFlexibleBox {DIV} at (0,0) size 200x25
 layer at (14,47) size 16x16
@@ -55,7 +54,6 @@
   RenderButton {BUTTON} at (3,3) size 16x16 [color=#FFFFFF]
 layer at (8,85) size 320x25
   RenderFlexibleBox {DIV} at (0,0) size 320x25
-    RenderBlock {DIV} at (0,0) size 320x25
 layer at (8,85) size 320x25
   RenderFlexibleBox {DIV} at (0,0) size 320x25
 layer at (14,90) size 16x16
@@ -96,9 +94,8 @@
   RenderMedia {AUDIO} at (8,128) size 320x100 [bgcolor=#0000FF]
 layer at (8,128) size 320x100
   RenderFlexibleBox {DIV} at (0,0) size 320x100
-    RenderBlock {DIV} at (0,75) size 320x25
 layer at (8,203) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,75) size 320x25
 layer at (14,208) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,208) size 16x16

Modified: trunk/LayoutTests/platform/mac-mavericks/media/controls-strict-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac-mavericks/media/controls-strict-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac-mavericks/media/controls-strict-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -13,9 +13,7 @@
 layer at (8,50) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,265) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,265) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,270) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,270) size 16x16

Copied: trunk/LayoutTests/platform/mac-mavericks/media/controls-without-preload-expected.txt (from rev 175267, trunk/LayoutTests/platform/mac/media/controls-without-preload-expected.txt) (0 => 175268)


--- trunk/LayoutTests/platform/mac-mavericks/media/controls-without-preload-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/platform/mac-mavericks/media/controls-without-preload-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -0,0 +1,52 @@
+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 312x18
+          text run at (0,0) width 312: "The controls should not depend on preload value."
+      RenderBlock (anonymous) at (0,34) size 784x240
+        RenderText {#text} at (0,0) size 0x0
+layer at (8,42) size 320x240
+  RenderVideo {VIDEO} at (0,0) size 320x240
+layer at (8,42) size 320x240
+  RenderFlexibleBox {DIV} at (0,0) size 320x240
+layer at (8,257) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
+layer at (14,262) size 16x16
+  RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
+layer at (40,262) size 16x16
+  RenderButton {BUTTON} at (32,5) size 16x16 [color=#FFFFFF]
+layer at (57,265) size 217x11
+  RenderFlexibleBox {DIV} at (49,7) size 217x12
+layer at (57,265) size 45x11
+  RenderFlexibleBox {DIV} at (0,0) 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 (229,265) size 45x11
+  RenderFlexibleBox {DIV} at (172,0) 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 (104,266) size 123x9
+  RenderFlexibleBox {DIV} at (47,1) size 123x9
+    RenderSlider {INPUT} at (0,0) size 123x9 [color=#909090] [bgcolor=#4A4A4A]
+      RenderFlexibleBox {DIV} at (0,0) size 123x9
+        RenderBlock {DIV} at (0,1) size 123x7
+layer at (104,267) size 6x6
+  RenderBlock {DIV} at (0,0) size 6x6 [bgcolor=#FFFFFF]
+layer at (274,259) size 22x22
+  RenderFlexibleBox {DIV} at (266,2) size 22x22
+layer at (274,259) size 2x22
+  RenderFlexibleBox {DIV} at (0,0) size 2x22 [border: (1px solid #000000F3)]
+    RenderSlider {INPUT} at (-7,6) size 2x10 [color=#909090] [border: (1px solid #000000DF)]
+      RenderFlexibleBox {DIV} at (1,1) size 0x8
+        RenderBlock {DIV} at (0,0) size 0x8
+layer at (260,266) size 8x8
+  RenderBlock {DIV} at (-8,0) size 8x8
+layer at (277,262) size 16x16
+  RenderButton {BUTTON} at (3,3) size 16x16 [color=#FFFFFF]
+layer at (305,262) size 16x16
+  RenderButton {BUTTON} at (297,5) size 16x16 [color=#FFFFFF]

Modified: trunk/LayoutTests/platform/mac-mavericks/media/video-controls-rendering-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac-mavericks/media/video-controls-rendering-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac-mavericks/media/video-controls-rendering-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -18,9 +18,7 @@
 layer at (8,42) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,257) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,257) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,262) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,262) size 16x16
@@ -60,9 +58,7 @@
 layer at (8,282) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,497) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,497) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,502) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,502) size 16x16
@@ -104,9 +100,7 @@
 layer at (8,522) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,737) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,737) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,742) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,742) size 16x16

Modified: trunk/LayoutTests/platform/mac-mavericks/media/video-display-toggle-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac-mavericks/media/video-display-toggle-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac-mavericks/media/video-display-toggle-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -12,9 +12,7 @@
 layer at (8,26) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,241) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,241) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,246) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,246) size 16x16

Copied: trunk/LayoutTests/platform/mac-mavericks/media/video-empty-source-expected.txt (from rev 175267, trunk/LayoutTests/platform/mac/media/video-empty-source-expected.txt) (0 => 175268)


--- trunk/LayoutTests/platform/mac-mavericks/media/video-empty-source-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/platform/mac-mavericks/media/video-empty-source-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -0,0 +1,28 @@
+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 430x18
+          text run at (0,0) width 430: "Slider drawing with no source. The controls should render correctly."
+      RenderBlock (anonymous) at (0,34) size 784x152
+        RenderText {#text} at (0,0) size 0x0
+layer at (8,42) size 302x152
+  RenderVideo {VIDEO} at (0,0) size 302x152 [border: (1px solid #000000)]
+layer at (9,43) size 300x150
+  RenderFlexibleBox {DIV} at (1,1) size 300x150
+layer at (9,168) size 300x25
+  RenderFlexibleBox {DIV} at (0,125) size 300x25
+layer at (58,169) size 138x25
+  RenderBlock {DIV} at (49,0) size 138x26 [color=#FFFFFF]
+    RenderText {#text} at (12,7) size 22x11
+      text run at (12,7) width 22: "Error"
+layer at (15,173) size 16x16
+  RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
+layer at (41,173) size 16x16
+  RenderButton {BUTTON} at (32,5) size 16x16 [color=#FFFFFF]
+layer at (196,177) size 113x9
+  RenderFlexibleBox {DIV} at (186,8) size 114x10
+layer at (198,177) size 110x9
+  RenderFlexibleBox {DIV} at (2,0) size 110x9

Modified: trunk/LayoutTests/platform/mac-mavericks/media/video-no-audio-expected.png


(Binary files differ)

Modified: trunk/LayoutTests/platform/mac-mavericks/media/video-no-audio-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac-mavericks/media/video-no-audio-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac-mavericks/media/video-no-audio-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -13,9 +13,7 @@
 layer at (8,42) size 352x288
   RenderFlexibleBox {DIV} at (0,0) size 352x288
 layer at (8,305) size 352x25
-  RenderBlock {DIV} at (0,263) size 352x25
-layer at (8,305) size 352x25
-  RenderFlexibleBox {DIV} at (0,0) size 352x25
+  RenderFlexibleBox {DIV} at (0,263) size 352x25
 layer at (14,310) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,310) size 16x16

Modified: trunk/LayoutTests/platform/mac-mavericks/media/video-volume-slider-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac-mavericks/media/video-volume-slider-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac-mavericks/media/video-volume-slider-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -18,9 +18,7 @@
 layer at (8,62) size 320x240
   RenderFlexibleBox {DIV} at (0,0) size 320x240
 layer at (8,277) size 320x25
-  RenderBlock {DIV} at (0,215) size 320x25
-layer at (8,277) size 320x25
-  RenderFlexibleBox {DIV} at (0,0) size 320x25
+  RenderFlexibleBox {DIV} at (0,215) size 320x25
 layer at (14,282) size 16x16
   RenderButton {BUTTON} at (6,4) size 16x17 [color=#FFFFFF]
 layer at (40,282) size 16x16

Modified: trunk/LayoutTests/platform/mac-mavericks/media/video-zoom-controls-expected.png


(Binary files differ)

Modified: trunk/LayoutTests/platform/mac-mavericks/media/video-zoom-controls-expected.txt (175267 => 175268)


--- trunk/LayoutTests/platform/mac-mavericks/media/video-zoom-controls-expected.txt	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/LayoutTests/platform/mac-mavericks/media/video-zoom-controls-expected.txt	2014-10-28 19:37:22 UTC (rev 175268)
@@ -11,9 +11,7 @@
 layer at (57,85) size 240x180
   RenderFlexibleBox {DIV} at (0,0) size 240x180
 layer at (57,228) size 240x37
-  RenderBlock {DIV} at (0,142) size 240x38
-layer at (57,228) size 240x38
-  RenderFlexibleBox {DIV} at (0,0) size 240x38
+  RenderFlexibleBox {DIV} at (0,142) size 240x38
 layer at (66,234) size 24x24
   RenderButton {BUTTON} at (9,6) size 24x25 [color=#FFFFFF]
 layer at (105,235) size 24x24
@@ -50,9 +48,7 @@
 layer at (57,310) size 240x180
   RenderFlexibleBox {DIV} at (0,0) size 240x180
 layer at (57,453) size 240x37
-  RenderBlock {DIV} at (0,142) size 240x38
-layer at (57,453) size 240x38
-  RenderFlexibleBox {DIV} at (0,0) size 240x38
+  RenderFlexibleBox {DIV} at (0,142) size 240x38
 layer at (66,459) size 24x24
   RenderButton {BUTTON} at (9,6) size 24x25 [color=#FFFFFF]
 layer at (105,460) size 24x24

Modified: trunk/Source/WebCore/ChangeLog (175267 => 175268)


--- trunk/Source/WebCore/ChangeLog	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/Source/WebCore/ChangeLog	2014-10-28 19:37:22 UTC (rev 175268)
@@ -1,3 +1,25 @@
+2014-10-28  Jer Noble  <[email protected]>
+
+        REGRESSION(r171593) [Mac] Media controls create a large (and unnecessary) backing store
+        https://bugs.webkit.org/show_bug.cgi?id=137757
+
+        Reviewed by Eric Carlson.
+
+        In r171593, a <div> was added to the media controls which is only ever used on iOS. Instead
+        of creating and adding this <div> in mediaControlsApple.js (which is used on OS X), this 
+        <div> should be created and added in mediaControlsiOS.js, which requires overloading
+        Controller.addControls.
+
+        * Modules/mediacontrols/mediaControlsApple.css:
+        (audio::-webkit-media-controls-panel.hidden): Drive-by fix: allow the panel itself to be hidden.
+        (video::-webkit-media-controls-panel-composited-parent): Deleted.
+        * Modules/mediacontrols/mediaControlsApple.js:
+        (Controller.prototype.createControls): Remove the composited parent.
+        (Controller.prototype.addControls): Ditto.
+        * Modules/mediacontrols/mediaControlsiOS.js:
+        (ControllerIOS.prototype.createControls): Create the composited parent.
+        (ControllerIOS.prototype.addControls): Copied from (previous) apple.js.
+
 2014-10-28  Chris Dumez  <[email protected]>
 
         Move "Number" CSS properties to the new StyleBuilder

Modified: trunk/Source/WebCore/Modules/mediacontrols/mediaControlsApple.css (175267 => 175268)


--- trunk/Source/WebCore/Modules/mediacontrols/mediaControlsApple.css	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/Source/WebCore/Modules/mediacontrols/mediaControlsApple.css	2014-10-28 19:37:22 UTC (rev 175268)
@@ -64,11 +64,6 @@
     -webkit-flex: 1 1 auto;
 }
 
-video::-webkit-media-controls-panel-composited-parent {
-    -webkit-transform: translateZ(0);
-    width: 100%;
-}
-
 video::-webkit-media-controls-panel,
 audio::-webkit-media-controls-panel {
     box-sizing: border-box;
@@ -537,6 +532,11 @@
     opacity: 1;
 }
 
+video::-webkit-media-controls-panel.hidden,
+audio::-webkit-media-controls-panel.hidden {
+    display: none;
+}
+
 video::-webkit-media-controls-panel .hidden,
 audio::-webkit-media-controls-panel .hidden {
     display: none;

Modified: trunk/Source/WebCore/Modules/mediacontrols/mediaControlsApple.js (175267 => 175268)


--- trunk/Source/WebCore/Modules/mediacontrols/mediaControlsApple.js	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/Source/WebCore/Modules/mediacontrols/mediaControlsApple.js	2014-10-28 19:37:22 UTC (rev 175268)
@@ -282,9 +282,6 @@
 
     createControls: function()
     {
-        var panelCompositedParent = this.controls.panelCompositedParent = document.createElement('div');
-        panelCompositedParent.setAttribute('pseudo', '-webkit-media-controls-panel-composited-parent');
-
         var panel = this.controls.panel = document.createElement('div');
         panel.setAttribute('pseudo', '-webkit-media-controls-panel');
         panel.setAttribute('aria-label', (this.isAudio() ? this.UIString('Audio Playback') : this.UIString('Video Playback')));
@@ -1052,8 +1049,7 @@
 
     addControls: function()
     {
-        this.base.appendChild(this.controls.panelCompositedParent);
-        this.controls.panelCompositedParent.appendChild(this.controls.panel);
+        this.base.appendChild(this.controls.panel);
         this.setNeedsTimelineMetricsUpdate();
     },
 

Modified: trunk/Source/WebCore/Modules/mediacontrols/mediaControlsiOS.js (175267 => 175268)


--- trunk/Source/WebCore/Modules/mediacontrols/mediaControlsiOS.js	2014-10-28 19:12:37 UTC (rev 175267)
+++ trunk/Source/WebCore/Modules/mediacontrols/mediaControlsiOS.js	2014-10-28 19:37:22 UTC (rev 175268)
@@ -136,6 +136,10 @@
     createControls: function() {
         Controller.prototype.createControls.call(this);
 
+        var panelCompositedParent = this.controls.panelCompositedParent = document.createElement('div');
+        panelCompositedParent.setAttribute('pseudo', '-webkit-media-controls-panel-composited-parent');
+
+
         var wirelessPlaybackStatus = this.controls.wirelessPlaybackStatus = document.createElement('div');
         wirelessPlaybackStatus.setAttribute('pseudo', '-webkit-media-controls-wireless-playback-status');
         wirelessPlaybackStatus.classList.add(this.ClassNames.hidden);
@@ -218,6 +222,12 @@
         this.updateShouldListenForPlaybackTargetAvailabilityEvent();
     },
 
+    addControls: function() {
+        this.base.appendChild(this.controls.panelCompositedParent);
+        this.controls.panelCompositedParent.appendChild(this.controls.panel);
+        this.setNeedsTimelineMetricsUpdate();
+    },
+
     updateControls: function() {
         if (this.shouldHaveStartPlaybackButton())
             this.setControlsType(ControllerIOS.StartPlaybackControls);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to