Created
July 21, 2015 01:36
-
-
Save MeoMix/3283dea94a4be6ca9b43 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
// Send a message to YouTube's iframe to figure out what the current time is of the video element inside of the iframe. | |
requestCurrentTimeHighPrecision: function() { | |
var iframePort = this.get('iframePort'); | |
iframePort.postMessage('getCurrentTimeHighPrecision'); | |
} | |
_onYouTubeIFrameMessage: function(message) { | |
if (!_.isUndefined(message.currentTimeHighPrecision)) { | |
this.trigger('receive:currentTimeHighPrecision', this, message); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment