blob: 56e86e99b3e65dac84401f9cf4fc8877b38be33e [file] [log] [blame]
<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>