Title: [217949] trunk
- Revision
- 217949
- Author
- [email protected]
- Date
- 2017-06-08 15:03:00 -0700 (Thu, 08 Jun 2017)
Log Message
[iOS] Buttons in top-left and bottom media controls bar are positioned too high
https://bugs.webkit.org/show_bug.cgi?id=173111
<rdar://problem/32650615>
Patch by Antoine Quint <[email protected]> on 2017-06-08
Reviewed by Jon Lee.
Source/WebCore:
Test: media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding.html
Since we use flex box to vertically center buttons in a buttons container, there is no
need to offset the button due to padding in the y-axis.
* Modules/modern-media-controls/controls/buttons-container.css:
(.ios .buttons-container button):
LayoutTests:
Add a test that checks that the appropriate styles as set in buttons-container.css
are applied to a button in a buttons container on iOS.
* media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding-expected.txt: Added.
* media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding.html: Added.
* platform/ios-simulator/TestExpectations:
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (217948 => 217949)
--- trunk/LayoutTests/ChangeLog 2017-06-08 21:47:39 UTC (rev 217948)
+++ trunk/LayoutTests/ChangeLog 2017-06-08 22:03:00 UTC (rev 217949)
@@ -1,3 +1,18 @@
+2017-06-08 Antoine Quint <[email protected]>
+
+ [iOS] Buttons in top-left and bottom media controls bar are positioned too high
+ https://bugs.webkit.org/show_bug.cgi?id=173111
+ <rdar://problem/32650615>
+
+ Reviewed by Jon Lee.
+
+ Add a test that checks that the appropriate styles as set in buttons-container.css
+ are applied to a button in a buttons container on iOS.
+
+ * media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding-expected.txt: Added.
+ * media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding.html: Added.
+ * platform/ios-simulator/TestExpectations:
+
2017-06-08 Youenn Fablet <[email protected]>
getUserMedia should not be prompted again if user denied access
Added: trunk/LayoutTests/media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding-expected.txt (0 => 217949)
--- trunk/LayoutTests/media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding-expected.txt (rev 0)
+++ trunk/LayoutTests/media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding-expected.txt 2017-06-08 22:03:00 UTC (rev 217949)
@@ -0,0 +1,12 @@
+Testing that buttons on iOS have extra padding and remain centered.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS mediaControls.querySelector('button.fullscreen') instanceof HTMLButtonElement became true
+PASS getComputedStyle(mediaControls.querySelector('button.fullscreen')).padding is "8px"
+PASS getComputedStyle(mediaControls.querySelector('button.fullscreen')).transform is "matrix(1, 0, 0, 1, -8, 0)"
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
Added: trunk/LayoutTests/media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding.html (0 => 217949)
--- trunk/LayoutTests/media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding.html (rev 0)
+++ trunk/LayoutTests/media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding.html 2017-06-08 22:03:00 UTC (rev 217949)
@@ -0,0 +1,21 @@
+<!DOCTYPE html>
+<script src=""
+<body>
+<video src="" style="width: 320px; height: 240px;" controls autoplay></video>
+<script type="text/_javascript_">
+
+window.jsTestIsAsync = true;
+
+description("Testing that buttons on iOS have extra padding and remain centered.");
+
+const mediaControls = window.internals.shadowRoot(document.querySelector("video")).lastElementChild;
+
+shouldBecomeEqual("mediaControls.querySelector('button.fullscreen') instanceof HTMLButtonElement", "true", () => {
+ shouldBeEqualToString("getComputedStyle(mediaControls.querySelector('button.fullscreen')).padding", "8px");
+ shouldBeEqualToString("getComputedStyle(mediaControls.querySelector('button.fullscreen')).transform", "matrix(1, 0, 0, 1, -8, 0)");
+ finishJSTest();
+});
+
+</script>
+<script src=""
+</body>
Modified: trunk/LayoutTests/platform/ios-simulator/TestExpectations (217948 => 217949)
--- trunk/LayoutTests/platform/ios-simulator/TestExpectations 2017-06-08 21:47:39 UTC (rev 217948)
+++ trunk/LayoutTests/platform/ios-simulator/TestExpectations 2017-06-08 22:03:00 UTC (rev 217949)
@@ -77,6 +77,9 @@
media/modern-media-controls/controls-visibility-support/controls-visibility-support-fullscreen-on-parent-element.html [ Skip ]
media/modern-media-controls/controls-visibility-support/controls-visibility-support-fullscreen-on-video.html [ Skip ]
+# These tests specifically test iOS-only media controls features
+media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding.html [ Pass ]
+
webkit.org/b/172965 media/track/track-cue-overlap-snap-to-lines-not-set.html [ Failure ]
webkit.org/b/156718 storage/websql/alter-to-info-table.html [ Failure ]
Modified: trunk/Source/WebCore/ChangeLog (217948 => 217949)
--- trunk/Source/WebCore/ChangeLog 2017-06-08 21:47:39 UTC (rev 217948)
+++ trunk/Source/WebCore/ChangeLog 2017-06-08 22:03:00 UTC (rev 217949)
@@ -1,3 +1,19 @@
+2017-06-08 Antoine Quint <[email protected]>
+
+ [iOS] Buttons in top-left and bottom media controls bar are positioned too high
+ https://bugs.webkit.org/show_bug.cgi?id=173111
+ <rdar://problem/32650615>
+
+ Reviewed by Jon Lee.
+
+ Test: media/modern-media-controls/ios-inline-media-controls/ios-inline-media-controls-button-padding.html
+
+ Since we use flex box to vertically center buttons in a buttons container, there is no
+ need to offset the button due to padding in the y-axis.
+
+ * Modules/modern-media-controls/controls/buttons-container.css:
+ (.ios .buttons-container button):
+
2017-06-08 Jeremy Jones <[email protected]>
Implement additional AVPlayerController interfaces for minTime and maxTime.
Modified: trunk/Source/WebCore/Modules/modern-media-controls/controls/buttons-container.css (217948 => 217949)
--- trunk/Source/WebCore/Modules/modern-media-controls/controls/buttons-container.css 2017-06-08 21:47:39 UTC (rev 217948)
+++ trunk/Source/WebCore/Modules/modern-media-controls/controls/buttons-container.css 2017-06-08 22:03:00 UTC (rev 217949)
@@ -33,6 +33,6 @@
/* Increase the touch region for buttons in containers on iOS */
.ios .buttons-container button {
padding: 8px;
- transform: translate(-8px, -8px);
+ transform: translateX(-8px);
box-sizing: content-box;
}
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes