Skip to content

Commit

Permalink
Release v4.12.9
Browse files Browse the repository at this point in the history
  • Loading branch information
jrivera committed Jun 15, 2015
1 parent 463ba4e commit 1bc8efc
Show file tree
Hide file tree
Showing 13 changed files with 452 additions and 373 deletions.
7 changes: 5 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,14 @@ CHANGELOG
=========

## HEAD (Unreleased)
* @imbcmdth updated currentSrc to return src instead of blob urls in html5 tech. Fixes #2232 ([view](https://github.com/videojs/video.js/pull/2232))
* @imbcmdth fixed async currentSrc behavior ([view](https://github.com/videojs/video.js/pull/2256))
_(none)_

--------------------

## 4.12.9 (2015-06-15)
* @imbcmdth updated currentSrc to return src instead of blob urls in html5 tech. Fixes #2232 ([view](https://github.com/videojs/video.js/pull/2232))
* @imbcmdth fixed async currentSrc behavior ([view](https://github.com/videojs/video.js/pull/2256))

## 4.12.8 (2015-06-05)
* @dmlap add the seekable property ([view](https://github.com/videojs/video.js/pull/2207))
* @dmlap fix seekable export ([view](https://github.com/videojs/video.js/pull/2227))
Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "video.js",
"description": "An HTML5 and Flash video player with a common API and skin for both.",
"version": "4.12.8",
"version": "4.12.9",
"main": [
"dist/video-js/video.js",
"dist/video-js/video-js.css",
Expand Down
2 changes: 1 addition & 1 deletion component.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "video.js",
"description": "An HTML5 and Flash video player with a common API and skin for both.",
"version": "4.12.8",
"version": "4.12.9",
"keywords": [
"videojs",
"html5",
Expand Down
2 changes: 1 addition & 1 deletion dist/video-js/video-js.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*!
Video.js Default Styles (http://videojs.com)
Version 4.12.8
Version 4.12.9
Create your own skin at http://designer.videojs.com
*/
/* SKIN
Expand Down
2 changes: 1 addition & 1 deletion dist/video-js/video-js.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

46 changes: 42 additions & 4 deletions dist/video-js/video.dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ vjs.ACCESS_PROTOCOL = ('https:' == document.location.protocol ? 'https://' : 'ht
* Full player version
* @type {string}
*/
vjs['VERSION'] = '4.12.8';
vjs['VERSION'] = '4.12.9';

/**
* Global Player instance options, surfaced from vjs.Player.prototype.options_
Expand Down Expand Up @@ -4931,7 +4931,12 @@ vjs.Player.prototype.load = function(){
* @return {String} The current source
*/
vjs.Player.prototype.currentSrc = function(){
return this.techGet('currentSrc') || this.cache_.src || '';
var techSrc = this.techGet('currentSrc');

if (techSrc === undefined) {
return this.cache_.src || '';
}
return techSrc;
};

/**
Expand Down Expand Up @@ -6589,6 +6594,8 @@ vjs.MediaTechController = vjs.Component.extend({
this.emulateTextTracks();
}

this.on('loadstart', this.updateCurrentSource_);

this.initTextTrackListeners();
}
});
Expand Down Expand Up @@ -6721,6 +6728,24 @@ vjs.MediaTechController.prototype.onTap = function(){
this.player().userActive(!this.player().userActive());
};

/**
* Set currentSource_ asynchronously to simulate the media element's
* asynchronous execution of the `resource selection algorithm`
*
* currentSource_ is set either as the first loadstart event OR
* in a timeout to make sure it is set asynchronously before anything else
* but before other loadstart handlers have had a chance to execute
*/
vjs.MediaTechController.prototype.updateCurrentSource_ = function () {
// We could have been called with a 0-ms setTimeout OR via loadstart (which ever
// happens first) so we should clear the timeout to be a good citizen
this.clearTimeout(this.updateSourceTimer_);

if (this.pendingSource_) {
this.currentSource_ = this.pendingSource_;
}
};

/* Fallbacks for unsupported event types
================================================================================ */
// Manually trigger progress events based on changes to the buffered amount
Expand Down Expand Up @@ -6979,6 +7004,8 @@ vjs.MediaTechController.prototype['featuresNativeTextTracks'] = false;
*
*/
vjs.MediaTechController.withSourceHandlers = function(Tech){
Tech.prototype.currentSource_ = {src: ''};

/**
* Register a source handler
* Source handlers are scripts for handling specific formats.
Expand Down Expand Up @@ -7063,7 +7090,12 @@ vjs.MediaTechController.withSourceHandlers = function(Tech){
this.disposeSourceHandler();
this.off('dispose', this.disposeSourceHandler);

this.currentSource_ = source;
// Schedule currentSource_ to be set asynchronously
if (source && source.src !== '') {
this.pendingSource_ = source;
this.updateSourceTimer_ = this.setTimeout(vjs.bind(this, this.updateCurrentSource_), 0);
}

this.sourceHandler_ = sh.handleSource(source, this);
this.on('dispose', this.disposeSourceHandler);

Expand Down Expand Up @@ -7415,7 +7447,13 @@ vjs.Html5.prototype.setSrc = function(src) {
};

vjs.Html5.prototype.load = function(){ this.el_.load(); };
vjs.Html5.prototype.currentSrc = function(){ return this.el_.currentSrc; };
vjs.Html5.prototype.currentSrc = function(){
if (this.currentSource_) {
return this.currentSource_.src;
} else {
return this.el_.currentSrc;
}
};

vjs.Html5.prototype.poster = function(){ return this.el_.poster; };
vjs.Html5.prototype.setPoster = function(val){ this.el_.poster = val; };
Expand Down
Loading

0 comments on commit 1bc8efc

Please sign in to comment.