| <script src="../../../resources/js-test-pre.js"></script> |
| <script src="../resources/media-controls-loader.js" type="text/javascript"></script> |
| <body> |
| <script type="text/javascript"> |
| |
| description("Testing the visibility of <code>MediaControls</code> when one of its buttons fires a focus event."); |
| |
| const mediaControls = new MediaControls({ layoutTraits: LayoutTraits.macOS }); |
| |
| shouldBeFalse("mediaControls.faded"); |
| mediaControls.faded = true; |
| shouldBeTrue("mediaControls.faded"); |
| mediaControls.element.dispatchEvent(new Event("focusin")); |
| shouldBeFalse("mediaControls.faded"); |
| |
| debug(""); |
| |
| </script> |
| <script src="../../../resources/js-test-post.js"></script> |
| </body> |