videojs_rails 4.12.8 → 4.12.9
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d7844e04433a4dc9a759199cadd70274072341ca
|
4
|
+
data.tar.gz: 1b3bafb8f19fda714b252fa4ffad6ce55ffe616a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c4a28dcf3155328c69538590c5bd804f0c730cd54fc8734f185b78eb29bf1cc0f9b95523ab62ce7bba4fdc05f659202db23521ac112a2804dc8f6c4a6e0b3b8c
|
7
|
+
data.tar.gz: d7bce6cca74210ce229c10a6f46bab097a8302ff885fd72a3bd9833ed9ab5fbfca57a3d31bb1a446156fe199d1684d2ba830ffd9cf634eeea79b5d531cfcc724
|
@@ -80,7 +80,7 @@ vjs.ACCESS_PROTOCOL = ('https:' == document.location.protocol ? 'https://' : 'ht
|
|
80
80
|
* Full player version
|
81
81
|
* @type {string}
|
82
82
|
*/
|
83
|
-
vjs['VERSION'] = '4.12.
|
83
|
+
vjs['VERSION'] = '4.12.9';
|
84
84
|
|
85
85
|
/**
|
86
86
|
* Global Player instance options, surfaced from vjs.Player.prototype.options_
|
@@ -4931,7 +4931,12 @@ vjs.Player.prototype.load = function(){
|
|
4931
4931
|
* @return {String} The current source
|
4932
4932
|
*/
|
4933
4933
|
vjs.Player.prototype.currentSrc = function(){
|
4934
|
-
|
4934
|
+
var techSrc = this.techGet('currentSrc');
|
4935
|
+
|
4936
|
+
if (techSrc === undefined) {
|
4937
|
+
return this.cache_.src || '';
|
4938
|
+
}
|
4939
|
+
return techSrc;
|
4935
4940
|
};
|
4936
4941
|
|
4937
4942
|
/**
|
@@ -6589,6 +6594,8 @@ vjs.MediaTechController = vjs.Component.extend({
|
|
6589
6594
|
this.emulateTextTracks();
|
6590
6595
|
}
|
6591
6596
|
|
6597
|
+
this.on('loadstart', this.updateCurrentSource_);
|
6598
|
+
|
6592
6599
|
this.initTextTrackListeners();
|
6593
6600
|
}
|
6594
6601
|
});
|
@@ -6721,6 +6728,24 @@ vjs.MediaTechController.prototype.onTap = function(){
|
|
6721
6728
|
this.player().userActive(!this.player().userActive());
|
6722
6729
|
};
|
6723
6730
|
|
6731
|
+
/**
|
6732
|
+
* Set currentSource_ asynchronously to simulate the media element's
|
6733
|
+
* asynchronous execution of the `resource selection algorithm`
|
6734
|
+
*
|
6735
|
+
* currentSource_ is set either as the first loadstart event OR
|
6736
|
+
* in a timeout to make sure it is set asynchronously before anything else
|
6737
|
+
* but before other loadstart handlers have had a chance to execute
|
6738
|
+
*/
|
6739
|
+
vjs.MediaTechController.prototype.updateCurrentSource_ = function () {
|
6740
|
+
// We could have been called with a 0-ms setTimeout OR via loadstart (which ever
|
6741
|
+
// happens first) so we should clear the timeout to be a good citizen
|
6742
|
+
this.clearTimeout(this.updateSourceTimer_);
|
6743
|
+
|
6744
|
+
if (this.pendingSource_) {
|
6745
|
+
this.currentSource_ = this.pendingSource_;
|
6746
|
+
}
|
6747
|
+
};
|
6748
|
+
|
6724
6749
|
/* Fallbacks for unsupported event types
|
6725
6750
|
================================================================================ */
|
6726
6751
|
// Manually trigger progress events based on changes to the buffered amount
|
@@ -6979,6 +7004,8 @@ vjs.MediaTechController.prototype['featuresNativeTextTracks'] = false;
|
|
6979
7004
|
*
|
6980
7005
|
*/
|
6981
7006
|
vjs.MediaTechController.withSourceHandlers = function(Tech){
|
7007
|
+
Tech.prototype.currentSource_ = {src: ''};
|
7008
|
+
|
6982
7009
|
/**
|
6983
7010
|
* Register a source handler
|
6984
7011
|
* Source handlers are scripts for handling specific formats.
|
@@ -7063,7 +7090,12 @@ vjs.MediaTechController.withSourceHandlers = function(Tech){
|
|
7063
7090
|
this.disposeSourceHandler();
|
7064
7091
|
this.off('dispose', this.disposeSourceHandler);
|
7065
7092
|
|
7066
|
-
|
7093
|
+
// Schedule currentSource_ to be set asynchronously
|
7094
|
+
if (source && source.src !== '') {
|
7095
|
+
this.pendingSource_ = source;
|
7096
|
+
this.updateSourceTimer_ = this.setTimeout(vjs.bind(this, this.updateCurrentSource_), 0);
|
7097
|
+
}
|
7098
|
+
|
7067
7099
|
this.sourceHandler_ = sh.handleSource(source, this);
|
7068
7100
|
this.on('dispose', this.disposeSourceHandler);
|
7069
7101
|
|
@@ -7415,7 +7447,13 @@ vjs.Html5.prototype.setSrc = function(src) {
|
|
7415
7447
|
};
|
7416
7448
|
|
7417
7449
|
vjs.Html5.prototype.load = function(){ this.el_.load(); };
|
7418
|
-
vjs.Html5.prototype.currentSrc = function(){
|
7450
|
+
vjs.Html5.prototype.currentSrc = function(){
|
7451
|
+
if (this.currentSource_) {
|
7452
|
+
return this.currentSource_.src;
|
7453
|
+
} else {
|
7454
|
+
return this.el_.currentSrc;
|
7455
|
+
}
|
7456
|
+
};
|
7419
7457
|
|
7420
7458
|
vjs.Html5.prototype.poster = function(){ return this.el_.poster; };
|
7421
7459
|
vjs.Html5.prototype.setPoster = function(val){ this.el_.poster = val; };
|