shaka-player 4.9.2-caf3 → 4.9.2-caf4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/locales.js +31 -31
- package/dist/shaka-player.compiled.debug.js +7 -6
- package/dist/shaka-player.compiled.debug.map +3 -3
- package/dist/shaka-player.compiled.js +56 -54
- package/dist/shaka-player.compiled.map +3 -3
- package/dist/shaka-player.ui.debug.js +10 -9
- package/dist/shaka-player.ui.debug.map +3 -3
- package/dist/shaka-player.ui.js +53 -51
- package/dist/shaka-player.ui.map +3 -3
- package/lib/media/media_source_engine.js +19 -1
- package/lib/player.js +1 -1
- package/package.json +1 -1
package/dist/locales.js
CHANGED
|
@@ -732,48 +732,48 @@ shaka.ui.Locales.addTo = function(localization) {
|
|
|
732
732
|
* @const
|
|
733
733
|
*/
|
|
734
734
|
shaka.ui.Locales.Ids = {
|
|
735
|
+
RECENTER_VR: 'RECENTER_VR',
|
|
736
|
+
REWIND: 'REWIND',
|
|
737
|
+
AUTO_QUALITY: 'AUTO_QUALITY',
|
|
735
738
|
UNRECOGNIZED_LANGUAGE: 'UNRECOGNIZED_LANGUAGE',
|
|
739
|
+
NOT_APPLICABLE: 'NOT_APPLICABLE',
|
|
740
|
+
MORE_SETTINGS: 'MORE_SETTINGS',
|
|
736
741
|
SURROUND: 'SURROUND',
|
|
737
|
-
EXIT_FULL_SCREEN: 'EXIT_FULL_SCREEN',
|
|
738
|
-
SKIP_TO_LIVE: 'SKIP_TO_LIVE',
|
|
739
742
|
REPLAY: 'REPLAY',
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
PAUSE: 'PAUSE',
|
|
744
|
-
UNDETERMINED_LANGUAGE: 'UNDETERMINED_LANGUAGE',
|
|
745
|
-
FULL_SCREEN: 'FULL_SCREEN',
|
|
746
|
-
VOLUME: 'VOLUME',
|
|
747
|
-
STATISTICS: 'STATISTICS',
|
|
748
|
-
REWIND: 'REWIND',
|
|
749
|
-
LIVE: 'LIVE',
|
|
750
|
-
PLAYBACK_RATE: 'PLAYBACK_RATE',
|
|
751
|
-
TOGGLE_STEREOSCOPIC: 'TOGGLE_STEREOSCOPIC',
|
|
752
|
-
EXIT_PICTURE_IN_PICTURE: 'EXIT_PICTURE_IN_PICTURE',
|
|
753
|
-
AIRPLAY: 'AIRPLAY',
|
|
754
|
-
UNMUTE: 'UNMUTE',
|
|
755
|
-
CAST: 'CAST',
|
|
743
|
+
AD_DURATION: 'AD_DURATION',
|
|
744
|
+
LOOP: 'LOOP',
|
|
745
|
+
PLAY: 'PLAY',
|
|
756
746
|
MUTE: 'MUTE',
|
|
747
|
+
OFF: 'OFF',
|
|
748
|
+
LIVE: 'LIVE',
|
|
749
|
+
AD_PROGRESS: 'AD_PROGRESS',
|
|
757
750
|
SEEK: 'SEEK',
|
|
751
|
+
VOLUME: 'VOLUME',
|
|
758
752
|
QUALITY: 'QUALITY',
|
|
759
|
-
|
|
753
|
+
EXIT_LOOP_MODE: 'EXIT_LOOP_MODE',
|
|
754
|
+
AIRPLAY: 'AIRPLAY',
|
|
760
755
|
RESOLUTION: 'RESOLUTION',
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
MULTIPLE_LANGUAGES: 'MULTIPLE_LANGUAGES',
|
|
756
|
+
CAST: 'CAST',
|
|
757
|
+
PICTURE_IN_PICTURE: 'PICTURE_IN_PICTURE',
|
|
758
|
+
UNMUTE: 'UNMUTE',
|
|
765
759
|
LANGUAGE: 'LANGUAGE',
|
|
766
|
-
|
|
767
|
-
SUBTITLE_FORCED: 'SUBTITLE_FORCED',
|
|
768
|
-
ENTER_PICTURE_IN_PICTURE: 'ENTER_PICTURE_IN_PICTURE',
|
|
769
|
-
EXIT_LOOP_MODE: 'EXIT_LOOP_MODE',
|
|
770
|
-
LOOP: 'LOOP',
|
|
771
|
-
PLAY: 'PLAY',
|
|
760
|
+
EXIT_PICTURE_IN_PICTURE: 'EXIT_PICTURE_IN_PICTURE',
|
|
772
761
|
ON: 'ON',
|
|
762
|
+
SUBTITLE_FORCED: 'SUBTITLE_FORCED',
|
|
763
|
+
CAPTIONS: 'CAPTIONS',
|
|
773
764
|
FAST_FORWARD: 'FAST_FORWARD',
|
|
774
|
-
AD_DURATION: 'AD_DURATION',
|
|
775
765
|
BACK: 'BACK',
|
|
776
766
|
AD_TIME: 'AD_TIME',
|
|
767
|
+
FULL_SCREEN: 'FULL_SCREEN',
|
|
768
|
+
TOGGLE_STEREOSCOPIC: 'TOGGLE_STEREOSCOPIC',
|
|
769
|
+
UNDETERMINED_LANGUAGE: 'UNDETERMINED_LANGUAGE',
|
|
770
|
+
MULTIPLE_LANGUAGES: 'MULTIPLE_LANGUAGES',
|
|
777
771
|
ENTER_LOOP_MODE: 'ENTER_LOOP_MODE',
|
|
778
|
-
|
|
772
|
+
EXIT_FULL_SCREEN: 'EXIT_FULL_SCREEN',
|
|
773
|
+
PAUSE: 'PAUSE',
|
|
774
|
+
SKIP_TO_LIVE: 'SKIP_TO_LIVE',
|
|
775
|
+
SKIP_AD: 'SKIP_AD',
|
|
776
|
+
STATISTICS: 'STATISTICS',
|
|
777
|
+
PLAYBACK_RATE: 'PLAYBACK_RATE',
|
|
778
|
+
ENTER_PICTURE_IN_PICTURE: 'ENTER_PICTURE_IN_PICTURE',
|
|
779
779
|
};
|
|
@@ -744,15 +744,16 @@ b={};a=$jscomp.makeIterator(a);for(var c=a.next();!c.done;c=a.next()){c=c.value;
|
|
|
744
744
|
shaka.media.MediaSourceEngine.prototype.doDestroy_=function(){var a=this,b,c,d,e,f,g,h,k,l,m;return $jscomp.asyncExecutePromiseGeneratorProgram(function(n){if(1==n.nextAddress){b=shaka.util.Functional;c=[];for(d in a.queues_)for(e=a.queues_[d],f=e[0],a.queues_[d]=e.slice(0,1),f&&c.push(f.p.catch(b.noop)),g=$jscomp.makeIterator(e.slice(1)),h=g.next();!h.done;h=g.next())k=h.value,k.p.reject(shaka.util.Destroyer.destroyedError());a.textEngine_&&c.push(a.textEngine_.destroy());a.textDisplayer_&&c.push(a.textDisplayer_.destroy());
|
|
745
745
|
for(l in a.transmuxers_)c.push(a.transmuxers_[l].destroy());return n.yield(Promise.all(c),2)}a.eventManager_&&(a.eventManager_.release(),a.eventManager_=null);a.video_&&(a.video_.removeAttribute("src"),a.video_.load(),a.video_=null);a.config_=null;a.mediaSource_=null;a.textEngine_=null;a.textDisplayer_=null;a.sourceBuffers_={};a.transmuxers_={};a.captionParser_=null;if(goog.DEBUG)for(m in a.queues_)goog.asserts.assert(0==a.queues_[m].length,m+" queue should be empty after destroy!");a.queues_={};
|
|
746
746
|
a.lcevcDec_=null;a.tsParser_=null;n.jumpToEnd()})};shaka.media.MediaSourceEngine.prototype.open=function(){return this.mediaSourceOpen_};
|
|
747
|
-
shaka.media.MediaSourceEngine.prototype.init=function(a,b,c,d){b=void 0===b?!1:b;c=void 0===c?shaka.media.ManifestParser.UNKNOWN:c;d=void 0===d?!1:d;var e=this,f,g,h,k,l;return $jscomp.asyncExecutePromiseGeneratorProgram(function(m){switch(m.nextAddress){case 1:return f=shaka.util.ManifestParserUtils.ContentType,m.yield(e.mediaSourceOpen_,2);case 2:e.
|
|
748
|
-
shaka.media.ManifestParser.HLS&&!e.ignoreManifestTimestampsInSegmentsMode_,e.tsParser_=null,g=$jscomp.makeIterator(a.keys()),h=g.next();case
|
|
747
|
+
shaka.media.MediaSourceEngine.prototype.init=function(a,b,c,d){b=void 0===b?!1:b;c=void 0===c?shaka.media.ManifestParser.UNKNOWN:c;d=void 0===d?!1:d;var e=this,f,g,h,k,l;return $jscomp.asyncExecutePromiseGeneratorProgram(function(m){switch(m.nextAddress){case 1:return f=shaka.util.ManifestParserUtils.ContentType,m.yield(e.mediaSourceOpen_,2);case 2:if(!e.ended()&&!e.closed()){m.jumpTo(3);break}shaka.log.alwaysError("Expected MediaSource to be open during init(); reopening the media source.");e.mediaSourceOpen_=
|
|
748
|
+
new shaka.util.PublicPromise;e.mediaSource_=e.createMediaSource(e.mediaSourceOpen_);return m.yield(e.mediaSourceOpen_,3);case 3:e.sequenceMode_=b,e.manifestType_=c,e.ignoreManifestTimestampsInSegmentsMode_=d,e.attemptTimestampOffsetCalculation_=!e.sequenceMode_&&e.manifestType_==shaka.media.ManifestParser.HLS&&!e.ignoreManifestTimestampsInSegmentsMode_,e.tsParser_=null,g=$jscomp.makeIterator(a.keys()),h=g.next();case 5:if(h.done){m.jumpTo(0);break}k=h.value;l=a.get(k);return m.yield(e.initSourceBuffer_(k,
|
|
749
|
+
l,l.codecs),8);case 8:e.needSplitMuxedContent_?(e.queues_[f.AUDIO]=[],e.queues_[f.VIDEO]=[]):e.queues_[k]=[],h=g.next(),m.jumpTo(5)}})};
|
|
749
750
|
shaka.media.MediaSourceEngine.prototype.initSourceBuffer_=function(a,b,c){var d=this,e,f,g,h,k,l,m,n,p,q,r,t;return $jscomp.asyncExecutePromiseGeneratorProgram(function(w){switch(w.nextAddress){case 1:return e=shaka.util.ManifestParserUtils.ContentType,f=goog.asserts,g=f.assert,w.yield(shaka.media.MediaSourceEngine.isStreamSupported(b,a),2);case 2:g.call(f,w.yieldResult,"Type negotiation should happen before MediaSourceEngine.init!");h=shaka.util.MimeUtils.getFullType(b.mimeType,c);if(a==e.TEXT){d.reinitText(h,
|
|
750
751
|
d.sequenceMode_,b.external);w.jumpTo(0);break}k=d.config_.forceTransmux;if(!shaka.media.Capabilities.isTypeSupported(h)||!d.sequenceMode_&&shaka.util.MimeUtils.RAW_FORMATS.includes(h))k=!0;l=shaka.util.MimeUtils.getFullTypeWithAllCodecs(b.mimeType,c);if(!k){w.jumpTo(4);break}m=shaka.util.ManifestParserUtils.guessCodecsSafe(e.AUDIO,(c||"").split(","));n=shaka.util.ManifestParserUtils.guessCodecsSafe(e.VIDEO,(c||"").split(","));if(!m||!n){w.jumpTo(5);break}d.needSplitMuxedContent_=!0;return w.yield(d.initSourceBuffer_(e.AUDIO,
|
|
751
752
|
b,m),6);case 6:return w.yield(d.initSourceBuffer_(e.VIDEO,b,n),7);case 7:return w.return();case 5:if(p=shaka.transmuxer.TransmuxerEngine.findTransmuxer(l))q=p(),d.transmuxers_[a]=q,h=q.convertCodecs(a,l);case 4:r=d.addExtraFeaturesToMimeType_(h);d.destroyer_.ensureNotDestroyed();try{t=d.mediaSource_.addSourceBuffer(r)}catch(u){throw new shaka.util.Error(shaka.util.Error.Severity.CRITICAL,shaka.util.Error.Category.MEDIA,shaka.util.Error.Code.MEDIA_SOURCE_OPERATION_THREW,u,"The mediaSource_ status was "+
|
|
752
753
|
d.mediaSource_.readyState+" expected 'open'",null);}d.sequenceMode_&&(t.mode=shaka.media.MediaSourceEngine.SourceBufferMode_.SEQUENCE);d.eventManager_.listen(t,"error",function(){return d.onError_(a)});d.eventManager_.listen(t,"updateend",function(){return d.onUpdateEnd_(a)});d.sourceBuffers_[a]=t;d.sourceBufferTypes_[a]=h;d.expectedEncryption_[a]=!!b.drmInfos.length;w.jumpToEnd()}})};shaka.media.MediaSourceEngine.prototype.configure=function(a){this.config_=a;this.textEngine_&&this.textEngine_.setModifyCueCallback(a.modifyCueCallback)};
|
|
753
754
|
shaka.media.MediaSourceEngine.prototype.isStreamingAllowed=function(){return this.streamingAllowed_};shaka.media.MediaSourceEngine.prototype.reinitText=function(a,b,c){this.textEngine_||(this.textEngine_=new shaka.text.TextEngine(this.textDisplayer_),this.textEngine_.setModifyCueCallback(this.config_.modifyCueCallback));this.textEngine_.initParser(a,b,c||this.segmentRelativeVttTiming_,this.manifestType_)};
|
|
754
|
-
shaka.media.MediaSourceEngine.prototype.ended=function(){return this.reloadingMediaSource_?!1:this.mediaSource_?"ended"==this.mediaSource_.readyState:!0};shaka.media.MediaSourceEngine.prototype.
|
|
755
|
-
shaka.media.MediaSourceEngine.prototype.bufferEnd=function(a){return this.reloadingMediaSource_?null:a==shaka.util.ManifestParserUtils.ContentType.TEXT?this.textEngine_.bufferEnd():shaka.media.TimeRangesUtils.bufferEnd(this.getBuffered_(a))};
|
|
755
|
+
shaka.media.MediaSourceEngine.prototype.ended=function(){return this.reloadingMediaSource_?!1:this.mediaSource_?"ended"==this.mediaSource_.readyState:!0};shaka.media.MediaSourceEngine.prototype.closed=function(){return this.reloadingMediaSource_?!1:this.mediaSource_?"closed"==this.mediaSource_.readyState:!0};
|
|
756
|
+
shaka.media.MediaSourceEngine.prototype.bufferStart=function(a){return this.reloadingMediaSource_||!Object.keys(this.sourceBuffers_).length?null:a==shaka.util.ManifestParserUtils.ContentType.TEXT?this.textEngine_.bufferStart():shaka.media.TimeRangesUtils.bufferStart(this.getBuffered_(a))};shaka.media.MediaSourceEngine.prototype.bufferEnd=function(a){return this.reloadingMediaSource_?null:a==shaka.util.ManifestParserUtils.ContentType.TEXT?this.textEngine_.bufferEnd():shaka.media.TimeRangesUtils.bufferEnd(this.getBuffered_(a))};
|
|
756
757
|
shaka.media.MediaSourceEngine.prototype.isBuffered=function(a,b){if(this.reloadingMediaSource_)return!1;if(a==shaka.util.ManifestParserUtils.ContentType.TEXT)return this.textEngine_.isBuffered(b);a=this.getBuffered_(a);return shaka.media.TimeRangesUtils.isBuffered(a,b)};
|
|
757
758
|
shaka.media.MediaSourceEngine.prototype.bufferedAheadOf=function(a,b){if(this.reloadingMediaSource_)return 0;if(a==shaka.util.ManifestParserUtils.ContentType.TEXT)return this.textEngine_.bufferedAheadOf(b);a=this.getBuffered_(a);return shaka.media.TimeRangesUtils.bufferedAheadOf(a,b)};
|
|
758
759
|
shaka.media.MediaSourceEngine.prototype.getBufferedInfo=function(){var a=shaka.util.ManifestParserUtils.ContentType,b=shaka.media.TimeRangesUtils;a={total:this.reloadingMediaSource_?[]:b.getBufferedInfo(this.video_.buffered),audio:this.reloadingMediaSource_?[]:b.getBufferedInfo(this.getBuffered_(a.AUDIO)),video:this.reloadingMediaSource_?[]:b.getBufferedInfo(this.getBuffered_(a.VIDEO)),text:[]};if(this.textEngine_){b=this.textEngine_.bufferStart();var c=this.textEngine_.bufferEnd();null!=b&&null!=
|
|
@@ -775,7 +776,7 @@ shaka.media.MediaSourceEngine.prototype.setStreamProperties=function(a,b,c,d,e,f
|
|
|
775
776
|
m.push(k.enqueueOperation_(l.AUDIO,function(){return k.abort_(l.AUDIO)},null)));e||(m.push(k.enqueueOperation_(a,function(){return k.setTimestampOffset_(a,b)},null)),k.needSplitMuxedContent_&&m.push(k.enqueueOperation_(l.AUDIO,function(){return k.setTimestampOffset_(l.AUDIO,b)},null)));m.push(k.enqueueOperation_(a,function(){return k.setAppendWindow_(a,c,d)},null));k.needSplitMuxedContent_&&m.push(k.enqueueOperation_(l.AUDIO,function(){return k.setAppendWindow_(l.AUDIO,c,d)},null));return p.yield(Promise.all(m),
|
|
776
777
|
0)})};
|
|
777
778
|
shaka.media.MediaSourceEngine.prototype.resync=function(a,b){var c=this,d;return $jscomp.asyncExecutePromiseGeneratorProgram(function(e){if(1==e.nextAddress){d=shaka.util.ManifestParserUtils.ContentType;if(a==d.TEXT)return e.return();a==d.VIDEO&&(c.textSequenceModeOffset_=new shaka.util.PublicPromise);c.enqueueOperation_(a,function(){return c.abort_(a)},null);c.needSplitMuxedContent_&&c.enqueueOperation_(d.AUDIO,function(){return c.abort_(d.AUDIO)},null);return e.yield(c.enqueueOperation_(a,function(){return c.setTimestampOffset_(a,
|
|
778
|
-
b)},null),2)}return c.needSplitMuxedContent_?e.yield(c.enqueueOperation_(d.AUDIO,function(){return c.setTimestampOffset_(d.AUDIO,b)},null),0):e.jumpTo(0)})};shaka.media.MediaSourceEngine.prototype.endOfStream=function(a){var b=this;return $jscomp.asyncExecutePromiseGeneratorProgram(function(c){return c.yield(b.enqueueBlockingOperation_(function(){b.ended()||
|
|
779
|
+
b)},null),2)}return c.needSplitMuxedContent_?e.yield(c.enqueueOperation_(d.AUDIO,function(){return c.setTimestampOffset_(d.AUDIO,b)},null),0):e.jumpTo(0)})};shaka.media.MediaSourceEngine.prototype.endOfStream=function(a){var b=this;return $jscomp.asyncExecutePromiseGeneratorProgram(function(c){return c.yield(b.enqueueBlockingOperation_(function(){b.ended()||b.closed()||(a?b.mediaSource_.endOfStream(a):b.mediaSource_.endOfStream())}),0)})};
|
|
779
780
|
shaka.media.MediaSourceEngine.prototype.setDuration=function(a){var b=this;return $jscomp.asyncExecutePromiseGeneratorProgram(function(c){return c.yield(b.enqueueBlockingOperation_(function(){if(a<b.mediaSource_.duration)for(var d in b.sourceBuffers_){var e={start:function(){},p:new shaka.util.PublicPromise,uri:null};b.queues_[d].unshift(e)}b.mediaSource_.duration=a;b.lastDuration_=a}),0)})};shaka.media.MediaSourceEngine.prototype.getDuration=function(){return this.mediaSource_.duration};
|
|
780
781
|
shaka.media.MediaSourceEngine.prototype.append_=function(a,b,c){a==shaka.util.ManifestParserUtils.ContentType.VIDEO&&this.lcevcDec_&&this.lcevcDec_.appendBuffer(b,c);this.sourceBuffers_[a].appendBuffer(b)};shaka.media.MediaSourceEngine.prototype.remove_=function(a,b,c){if(c<=b)this.onUpdateEnd_(a);else this.sourceBuffers_[a].remove(b,c)};
|
|
781
782
|
shaka.media.MediaSourceEngine.prototype.abort_=function(a){var b=this.sourceBuffers_[a].appendWindowStart,c=this.sourceBuffers_[a].appendWindowEnd;this.sourceBuffers_[a].abort();this.sourceBuffers_[a].appendWindowStart=b;this.sourceBuffers_[a].appendWindowEnd=c;this.onUpdateEnd_(a)};shaka.media.MediaSourceEngine.prototype.flush_=function(a){goog.asserts.assert(0==this.video_.buffered.length,"MediaSourceEngine.flush_ should only be used after clearing all data!");this.video_.currentTime-=.001;this.onUpdateEnd_(a)};
|
|
@@ -1441,7 +1442,7 @@ goog.exportProperty(shaka.Player.prototype,"resetConfiguration",shaka.Player.pro
|
|
|
1441
1442
|
goog.exportProperty(shaka.Player.prototype,"releaseAllMutexes",shaka.Player.prototype.releaseAllMutexes);goog.exportProperty(shaka.Player.prototype,"preload",shaka.Player.prototype.preload);goog.exportProperty(shaka.Player.prototype,"detachAndSavePreload",shaka.Player.prototype.detachAndSavePreload);goog.exportProperty(shaka.Player.prototype,"unloadAndSavePreload",shaka.Player.prototype.unloadAndSavePreload);goog.exportProperty(shaka.Player.prototype,"load",shaka.Player.prototype.load);
|
|
1442
1443
|
goog.exportProperty(shaka.Player.prototype,"updateStartTime",shaka.Player.prototype.updateStartTime);goog.exportProperty(shaka.Player.prototype,"unload",shaka.Player.prototype.unload);goog.exportProperty(shaka.Player.prototype,"detach",shaka.Player.prototype.detach);goog.exportProperty(shaka.Player.prototype,"attachCanvas",shaka.Player.prototype.attachCanvas);goog.exportProperty(shaka.Player.prototype,"attach",shaka.Player.prototype.attach);goog.exportProperty(shaka.Player,"probeSupport",shaka.Player.probeSupport);
|
|
1443
1444
|
goog.exportProperty(shaka.Player,"isBrowserSupported",shaka.Player.isBrowserSupported);goog.exportProperty(shaka.Player,"setAdManagerFactory",shaka.Player.setAdManagerFactory);goog.exportProperty(shaka.Player,"registerSupportPlugin",shaka.Player.registerSupportPlugin);goog.exportProperty(shaka.Player.prototype,"destroy",shaka.Player.prototype.destroy);shaka.Player.LoadMode={DESTROYED:0,NOT_LOADED:1,MEDIA_SOURCE:2,SRC_EQUALS:3};goog.exportProperty(shaka.Player,"LoadMode",shaka.Player.LoadMode);
|
|
1444
|
-
shaka.Player.TYPICAL_BUFFERING_THRESHOLD_=.5;shaka.Player.version="v4.9.2-
|
|
1445
|
+
shaka.Player.TYPICAL_BUFFERING_THRESHOLD_=.5;shaka.Player.version="v4.9.2-caf4-debug";goog.exportProperty(shaka.Player,"version",shaka.Player.version);shaka.Deprecate.init(shaka.Player.version);shaka.Player.supportPlugins_={};shaka.Player.adManagerFactory_=null;shaka.Player.TextTrackLabel="Shaka Player TextTrack";shaka.ads={};shaka.ads.AdsStats=function(){this.loadTimes_=[];this.skipped_=this.playedCompletely_=this.started_=0};shaka.ads.AdsStats.prototype.addLoadTime=function(a){this.loadTimes_.push(a)};shaka.ads.AdsStats.prototype.incrementStarted=function(){this.started_++};shaka.ads.AdsStats.prototype.incrementPlayedCompletely=function(){this.playedCompletely_++};shaka.ads.AdsStats.prototype.incrementSkipped=function(){this.skipped_++};
|
|
1445
1446
|
shaka.ads.AdsStats.prototype.getBlob=function(){return{loadTimes:this.loadTimes_,started:this.started_,playedCompletely:this.playedCompletely_,skipped:this.skipped_}};shaka.ads.ClientSideAd=function(a,b,c){var d=this;this.ad_=a;this.manager_=b;this.video_=c;this.isPaused_=!1;this.volume_=this.manager_.getVolume();this.eventManager_=new shaka.util.EventManager;this.eventManager_.listen(this.manager_,google.ima.AdEvent.Type.PAUSED,function(){d.isPaused_=!0});this.eventManager_.listen(this.manager_,google.ima.AdEvent.Type.RESUMED,function(){d.isPaused_=!1})};shaka.ads.ClientSideAd.prototype.getDuration=function(){return this.ad_.getDuration()};
|
|
1446
1447
|
shaka.ads.ClientSideAd.prototype.getMinSuggestedDuration=function(){return this.ad_.getMinSuggestedDuration()};shaka.ads.ClientSideAd.prototype.getRemainingTime=function(){return this.manager_.getRemainingTime()};shaka.ads.ClientSideAd.prototype.isPaused=function(){return this.isPaused_};shaka.ads.ClientSideAd.prototype.isSkippable=function(){return 0<=this.ad_.getSkipTimeOffset()};
|
|
1447
1448
|
shaka.ads.ClientSideAd.prototype.getTimeUntilSkippable=function(){var a=this.ad_.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};shaka.ads.ClientSideAd.prototype.canSkipNow=function(){return this.manager_.getAdSkippableState()};shaka.ads.ClientSideAd.prototype.skip=function(){return this.manager_.skip()};shaka.ads.ClientSideAd.prototype.setPaused=function(a){this.isPaused_=a};shaka.ads.ClientSideAd.prototype.pause=function(){return this.manager_.pause()};
|