blob: de4ca5bca4629b8e8398a2f59ecd3b0c4c34829b [file] [log] [blame]
This tests that the "webkitpresentationmodechanged" event is fired only once when the browser switches back to inline from the picture-in-picture mode.
RUN(video.src = findMediaFile("video", "content/test"))
EVENT(canplaythrough)
RUN(video.play())
RUN(video.webkitSetPresentationMode("picture-in-picture"))
EVENT(webkitpresentationmodechanged)
EXPECTED (internals.isChangingPresentationMode(video) == 'false') OK
EXPECTED (video.webkitPresentationMode == 'picture-in-picture') OK
RUN(video.webkitSetPresentationMode("inline"))
EVENT(webkitpresentationmodechanged)
EXPECTED (video.webkitPresentationMode == 'inline') OK
END OF TEST