OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <title>Overflow menu children appear in correct order.</title> | 2 <title>Overflow menu children appear in correct order.</title> |
3 <script src="../resources/testharness.js"></script> | 3 <script src="../resources/testharness.js"></script> |
4 <script src="../resources/testharnessreport.js"></script> | 4 <script src="../resources/testharnessreport.js"></script> |
5 <script src="media-controls.js"></script> | 5 <script src="media-controls.js"></script> |
6 <script src="media-file.js"></script> | 6 <script src="media-file.js"></script> |
7 <script src="overflow-menu.js"></script> | 7 <script src="overflow-menu.js"></script> |
8 | 8 |
9 <!--Padding ensures the overflow menu is visible for the tests. --> | 9 <!--Padding ensures the overflow menu is visible for the tests. --> |
10 <body style="padding-top: 200px; padding-left: 100px"> | 10 <body style="padding-top: 200px; padding-left: 100px"> |
11 <video controls></video> | 11 <video controls></video> |
12 <script> | 12 <script> |
13 async_test(function(t) { | 13 async_test(function(t) { |
| 14 if (window.internals) |
| 15 window.internals.runtimeFlags.mediaControlsDownloadButtonEnabled = true; |
14 // Set up video | 16 // Set up video |
15 var video = document.querySelector("video"); | 17 var video = document.querySelector("video"); |
16 video.src = findMediaFile("video", "content/test"); | 18 video.src = findMediaFile("video", "content/test"); |
17 video.setAttribute("width", "60"); | 19 video.setAttribute("width", "60"); |
18 // Add captions | 20 // Add captions |
19 var track = video.addTextTrack("captions"); | 21 var track = video.addTextTrack("captions"); |
20 // Pretend we have a cast device | 22 // Pretend we have a cast device |
21 internals.mediaPlayerRemoteRouteAvailabilityChanged(video, true); | 23 internals.mediaPlayerRemoteRouteAvailabilityChanged(video, true); |
22 | 24 |
23 video.onloadeddata = t.step_func_done(function() { | 25 video.onloadeddata = t.step_func_done(function() { |
(...skipping 12 matching lines...) Expand all Loading... |
36 assert_equals(internals.shadowPseudoId(innerButton), overflowButtonsCSS[i]
); | 38 assert_equals(internals.shadowPseudoId(innerButton), overflowButtonsCSS[i]
); |
37 // Items should be visible | 39 // Items should be visible |
38 assert_not_equals(getComputedStyle(child).display, "none"); | 40 assert_not_equals(getComputedStyle(child).display, "none"); |
39 // Buttons shouldn't be visible | 41 // Buttons shouldn't be visible |
40 assert_equals(getComputedStyle(innerButton).display, "none"); | 42 assert_equals(getComputedStyle(innerButton).display, "none"); |
41 } | 43 } |
42 }); | 44 }); |
43 }); | 45 }); |
44 </script> | 46 </script> |
45 </body> | 47 </body> |
OLD | NEW |