Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(53)

Side by Side Diff: LayoutTests/fullscreen/video-controls-override.html

Issue 662243003: Use ::-internal-media-controls* instead of ::-webkit-media-controls* (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: introduce PseudoInternalCustomElement Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <body> 1 <body>
2 <p>This tests that the video element's "controls" attribute is overridden in full screen mode, and that the controls are correctly hidden upon exiting full screen. Press any key to continue.</p> 2 <p>This tests that the video element's "controls" attribute is overridden in full screen mode, and that the controls are correctly hidden upon exiting full screen. Press any key to continue.</p>
3 <video id="video" width="300"></video> 3 <video id="video" width="300"></video>
4 <script src="full-screen-test.js"></script> 4 <script src="full-screen-test.js"></script>
5 <script src="../media/media-controls.js"></script> 5 <script src="../media/media-controls.js"></script>
6 <script> 6 <script>
7 var callback; 7 var callback;
8 var shadowRoot; 8 var shadowRoot;
9 var panel; 9 var panel;
10 10
11 var fullscreenChanged = function(event) 11 var fullscreenChanged = function(event)
12 { 12 {
13 if (callback) 13 if (callback)
14 callback(event) 14 callback(event)
15 }; 15 };
16 waitForEvent(document, 'webkitfullscreenchange', fullscreenChanged); 16 waitForEvent(document, 'webkitfullscreenchange', fullscreenChanged);
17 17
18 var video = document.getElementById('video'); 18 var video = document.getElementById('video');
19 19
20 var videoEnteredFullScreen = function() { 20 var videoEnteredFullScreen = function() {
21 if (window.internals) { 21 if (window.internals) {
22 testExpected("shadowRoot = internals.shadowRoot(video)", null, " !="); 22 testExpected("shadowRoot = internals.shadowRoot(video)", null, " !=");
23 testExpected("panel = mediaControlsElement(shadowRoot.firstChild , '-webkit-media-controls-panel')", null, "!="); 23 testExpected("panel = mediaControlsElement(shadowRoot.firstChild , '-internal-media-controls-panel')", null, "!=");
24 testExpected("internals.shadowPseudoId(panel)", "-webkit-media-c ontrols-panel"); 24 testExpected("internals.shadowPseudoId(panel)", "-internal-media -controls-panel");
25 testExpected("document.defaultView.getComputedStyle(panel)['disp lay']", 'none', "!="); 25 testExpected("document.defaultView.getComputedStyle(panel)['disp lay']", 'none', "!=");
26 testExpected("document.defaultView.getComputedStyle(panel)['heig ht']", '20px', ">="); 26 testExpected("document.defaultView.getComputedStyle(panel)['heig ht']", '20px', ">=");
27 } 27 }
28 else 28 else
29 logResult(false, "window.internals == undefined"); 29 logResult(false, "window.internals == undefined");
30 30
31 callback = cancelledFullScreen; 31 callback = cancelledFullScreen;
32 document.webkitCancelFullScreen(); 32 document.webkitCancelFullScreen();
33 }; 33 };
34 34
35 var cancelledFullScreen = function() { 35 var cancelledFullScreen = function() {
36 if (window.testRunner) 36 if (window.testRunner)
37 testExpected("document.defaultView.getComputedStyle(panel)['disp lay']", 'none'); 37 testExpected("document.defaultView.getComputedStyle(panel)['disp lay']", 'none');
38 else 38 else
39 logResult(false, "window.testRunner == undefined"); 39 logResult(false, "window.testRunner == undefined");
40 40
41 endTest(); 41 endTest();
42 }; 42 };
43 43
44 callback = videoEnteredFullScreen; 44 callback = videoEnteredFullScreen;
45 runWithKeyDown(function(){video.webkitRequestFullScreen()}); 45 runWithKeyDown(function(){video.webkitRequestFullScreen()});
46 </script> 46 </script>
47 </body> 47 </body>
OLDNEW
« no previous file with comments | « LayoutTests/fullscreen/video-controls-drag.html ('k') | LayoutTests/fullscreen/video-controls-override-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698