blob: 1b43b73733a5c72124fe8f94a9306690ca84b86a [file] [log] [blame]
<!DOCTYPE html>
<html>
<head>
<script>
window.addEventListener('load', event => {
let context = new AudioContext();
let node = context.createBufferSource();
node.connect(context.destination);
let video = document.querySelector('video');
Promise.all([context.resume(), video.play()]).then(() => {
window.webkit.messageHandlers.testHandler.postMessage('playing');
}, () => {
window.webkit.messageHandlers.testHandler.postMessage('not playing');
});
});
</script>
</head>
<video src="video-with-audio.mp4"></video>
</html>