Created
March 30, 2010 15:09
-
-
Save ghinch/349174 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Test Media</title> | |
<script type="text/javascript" src="http://yui.yahooapis.com/combo?3.1.0pr5/build/yui/yui-min.js"></script> | |
</head> | |
<body> | |
<video width="640" height="480" controls autoplay> | |
<source type="video/mp4" src="video.mp4"> | |
<source type="video/ogg" src="video.ogg"> | |
</video> | |
<script type="text/javascript"> | |
//<!-- | |
YUI().use('node', 'event', function (Y) { | |
var v = Y.one('video'), | |
vEl = document.getElementsByTagName('video')[0]; | |
v.after('timeupdate', function () { | |
// Does not fire | |
console.log('yui3 node timeup'); | |
}); | |
Y.after('timeupdate', function () { | |
// Does not fire | |
console.log('yui3 event timeup'); | |
}, v); | |
vEl.addEventListener('timeupdate', function (e) { | |
// Fires | |
console.log('browser event timeup'); | |
}, true); | |
//--> | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment