shaka-player 3.1.7 → 3.1.8
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/.github/workflows/release-please.yaml +3 -1
- package/CHANGELOG.md +9 -0
- package/build/generateTsDefs.py +2 -0
- package/dist/controls.css +2 -2
- package/dist/controls.css.map +1 -1
- package/dist/locales.js +30 -30
- package/dist/shaka-player.compiled.d.ts +2 -0
- package/dist/shaka-player.compiled.debug.d.ts +2 -0
- package/dist/shaka-player.compiled.debug.js +1 -1
- package/dist/shaka-player.compiled.js +4 -4
- package/dist/shaka-player.ui.d.ts +2 -0
- package/dist/shaka-player.ui.debug.d.ts +2 -0
- package/dist/shaka-player.ui.debug.js +3 -3
- package/dist/shaka-player.ui.debug.map +2 -2
- package/dist/shaka-player.ui.js +6 -6
- package/dist/shaka-player.ui.map +2 -2
- package/lib/player.js +1 -1
- package/package.json +1 -1
- package/ui/less/ad_controls.less +2 -2
- package/ui/less/buttons.less +1 -1
- package/ui/less/containers.less +4 -4
- package/ui/less/range_elements.less +2 -2
- package/ui/seek_bar.js +2 -1
package/dist/shaka-player.ui.js
CHANGED
|
@@ -91,8 +91,8 @@ q.Ae=function(a){var b=this;this.g.clear();a=t(a);for(var c=a.next();!c.done;c=a
|
|
|
91
91
|
q.ba=function(a,b,c){a=Nb(a);void 0===c&&(c=Xb);var d=this.h.get(a)||new Map;b.forEach(function(e,f){d.has(f)&&c!=Xb||d.set(f,e)});this.h.set(a,d);Wb(this);this.dispatchEvent(new N("locale-updated"));return this};q.xg=function(a){for(var b=t(a.keys()),c=b.next();!c.done;c=b.next())c=c.value,a.set(c,this.resolve(c))};q.resolve=function(a){var b=this.i.get(a);if(b)return b;a=(new Map).set("locales",Array.from(this.g)).set("missing",a);this.dispatchEvent(new N("unknown-localization",a));return""};
|
|
92
92
|
function Wb(a){for(var b=a.h,c=a.j,d=a.g,e=new Set,f={},g=t(d),h=g.next();!h.done;f={Qb:f.Qb},h=g.next()){f.Qb=h.value;e.add(f.Qb);e.add(Sb(f.Qb));h=fb(b.keys(),function(l){return function(m){var n=l.Qb,p=Sb(m),r=Sb(n);return m!=p&&n!=r&&p==r}}(f));h.sort();var k=t(h);for(h=k.next();!h.done;h=k.next())e.add(h.value);h=fb(b.keys(),function(l){return function(m){return Sb(m)==l.Qb}}(f));h.sort();k=t(h);for(h=k.next();!h.done;h=k.next())e.add(h.value)}e.add(c);c=[];e=t(e);for(h=e.next();!h.done;h=e.next())(h=
|
|
93
93
|
b.get(h.value))&&c.push(h);c.reverse();a.i.clear();b=t(c);for(h=b.next();!h.done;h=b.next())h.value.forEach(function(l,m){a.i.set(m,l)});b=a.i.keys();e=new Set;c=t(a.g);for(h=c.next();!h.done;h=c.next())h=a.h.get(h.value)||new Map,Yb(h,b,e);0<e.size&&(d=(new Map).set("locales",Array.from(d)).set("missing",Array.from(e)),a.dispatchEvent(new N("missing-localizations",d)))}function Yb(a,b,c){b=t(b);for(var d=b.next();!d.done;d=b.next())d=d.value,a.get(d)||c.add(d)}M("shaka.ui.Localization",Vb);
|
|
94
|
-
Vb.prototype.resolve=Vb.prototype.resolve;Vb.prototype.resolveDictionary=Vb.prototype.xg;Vb.prototype.insert=Vb.prototype.ba;Vb.prototype.changeLocale=Vb.prototype.Ae;Vb.prototype.release=Vb.prototype.release;var Xb=1;Vb.ConflictResolution={USE_OLD:0,USE_NEW:Xb};Vb.UNKNOWN_LOCALES="unknown-locales";Vb.UNKNOWN_LOCALIZATION="unknown-localization";Vb.MISSING_LOCALIZATIONS="missing-localizations";Vb.LOCALE_CHANGED="locale-changed";Vb.LOCALE_UPDATED="locale-updated";var Zb={
|
|
95
|
-
|
|
94
|
+
Vb.prototype.resolve=Vb.prototype.resolve;Vb.prototype.resolveDictionary=Vb.prototype.xg;Vb.prototype.insert=Vb.prototype.ba;Vb.prototype.changeLocale=Vb.prototype.Ae;Vb.prototype.release=Vb.prototype.release;var Xb=1;Vb.ConflictResolution={USE_OLD:0,USE_NEW:Xb};Vb.UNKNOWN_LOCALES="unknown-locales";Vb.UNKNOWN_LOCALIZATION="unknown-localization";Vb.MISSING_LOCALIZATIONS="missing-localizations";Vb.LOCALE_CHANGED="locale-changed";Vb.LOCALE_UPDATED="locale-updated";var Zb={Yg:"EXIT_LOOP_MODE",nf:"SUBTITLE_FORCED",Jg:"AD_DURATION",uh:"PICTURE_IN_PICTURE",Vg:"ENTER_PICTURE_IN_PICTURE",sh:"PAUSE",Nh:"UNDETERMINED_LANGUAGE",Ph:"UNRECOGNIZED_LANGUAGE",Lg:"AIRPLAY",jh:"MORE_SETTINGS",Xg:"EXIT_FULL_SCREEN",dh:"FULL_SCREEN",bh:"FAST_FORWARD",vh:"PLAY",eh:"LANGUAGE",xh:"REPLAY",kh:"MULTIPLE_LANGUAGES",Ug:"ENTER_LOOP_MODE",wh:"PLAYBACK_RATE",ph:"ON",fh:"LOOP",BACK:"BACK",Eh:"SKIP_TO_LIVE",yh:"RESOLUTION",Oh:"UNMUTE",Sg:"CAST",Ch:"SEEK",Dh:"SKIP_AD",we:"LIVE",Zg:"EXIT_PICTURE_IN_PICTURE",
|
|
95
|
+
AD_PROGRESS:"AD_PROGRESS",lh:"MUTE",Ng:"AUTO_QUALITY",nh:"NOT_APPLICABLE",Rh:"VOLUME",Ah:"REWIND",oh:"OFF",Kg:"AD_TIME",Rg:"CAPTIONS"};function $b(a){this.i=Math.exp(Math.log(.5)/a);this.h=this.g=0}$b.prototype.sample=function(a,b){var c=Math.pow(this.i,a);c=b*(1-c)+c*this.g;isNaN(c)||(this.g=c,this.h+=a)};function ac(a){return a.g/(1-Math.pow(a.i,a.h))};function bc(){this.h=new $b(2);this.i=new $b(5);this.g=0}bc.prototype.sample=function(a,b){if(!(16E3>b)){var c=8E3*b/a,d=a/1E3;this.g+=b;this.h.sample(d,c);this.i.sample(d,c)}};bc.prototype.getBandwidthEstimate=function(a){return 128E3>this.g?a:Math.min(ac(this.h),ac(this.i))};function cc(){}function dc(a,b){if(!a&&!b)return!0;if(!a||!b||a.byteLength!=b.byteLength)return!1;if(ec(a)==ec(b)&&(a.byteOffset||0)==(b.byteOffset||0))return!0;for(var c=fc(a),d=fc(b),e=0;e<a.byteLength;e++)if(c[e]!=d[e])return!1;return!0}function ec(a){return a instanceof ArrayBuffer?a:a.buffer}function gc(a){return a instanceof ArrayBuffer?a:0==a.byteOffset&&a.byteLength==a.buffer.byteLength?a.buffer:(new Uint8Array(a)).buffer}
|
|
96
96
|
function fc(a,b,c){c=void 0===c?Infinity:c;return hc(a,void 0===b?0:b,c,Uint8Array)}function ic(a,b,c){c=void 0===c?Infinity:c;return hc(a,void 0===b?0:b,c,DataView)}function hc(a,b,c,d){var e=(a.byteOffset||0)+a.byteLength;b=Math.max(0,Math.min((a.byteOffset||0)+b,e));return new d(ec(a),b,Math.min(b+Math.max(c,0),e)-b)}M("shaka.util.BufferUtils",cc);cc.toDataView=ic;cc.toUint8=fc;cc.toArrayBuffer=gc;cc.equal=dc;function jc(a){this.h=a;this.g=void 0}jc.prototype.value=function(){void 0==this.g&&(this.g=this.h());return this.g};function kc(){}function lc(a){if(!a)return"";a=fc(a);239==a[0]&&187==a[1]&&191==a[2]&&(a=a.subarray(3));a=(new TextDecoder).decode(a);a.includes("\ufffd")&&Na('Decoded string contains an "unknown character" codepoint. That probably means the UTF8 encoding was incorrect!');return a}function mc(a,b,c){if(!a)return"";if(!c&&0!=a.byteLength%2)throw new Q(2,2,2004);c=Math.floor(a.byteLength/2);var d=new Uint16Array(c);a=ic(a);for(var e=0;e<c;e++)d[e]=a.getUint16(2*e,b);return nc.value()(d)}
|
|
97
97
|
function oc(a){function b(d){return c.byteLength<=d||32<=c[d]&&126>=c[d]}if(!a)return"";var c=fc(a);if(239==c[0]&&187==c[1]&&191==c[2])return lc(c);if(254==c[0]&&255==c[1])return mc(c.subarray(2),!1);if(255==c[0]&&254==c[1])return mc(c.subarray(2),!0);if(0==c[0]&&0==c[2])return mc(a,!1);if(0==c[1]&&0==c[3])return mc(a,!0);if(b(0)&&b(1)&&b(2)&&b(3))return lc(a);throw new Q(2,2,2003);}function qc(a){var b=new TextEncoder;return gc(b.encode(a))}
|
|
98
98
|
function rc(a,b){for(var c=new ArrayBuffer(2*a.length),d=new DataView(c),e=0;e<a.length;++e)d.setUint16(2*e,a.charCodeAt(e),b);return c}M("shaka.util.StringUtils",kc);kc.resetFromCharCode=function(){nc.g=void 0};kc.toUTF16=rc;kc.toUTF8=qc;kc.fromBytesAutoDetect=oc;kc.fromUTF16=mc;kc.fromUTF8=lc;
|
|
@@ -450,11 +450,11 @@ V.probeSupport=function(a){a=void 0===a?!0:a;var b,c,d,e,f,g;return J(function(h
|
|
|
450
450
|
Fc()?!!ii[p]:Gc(l[p]);c=k;k={};p=t('video/mp4; codecs="avc1.42E01E",video/mp4; codecs="avc3.42E01E",video/mp4; codecs="hev1.1.6.L93.90",video/mp4; codecs="hvc1.1.6.L93.90",video/mp4; codecs="hev1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="hvc1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="vp9",video/mp4; codecs="vp09.00.10.08",video/mp4; codecs="av01.0.01M.08",audio/mp4; codecs="mp4a.40.2",audio/mp4; codecs="ac-3",audio/mp4; codecs="ec-3",audio/mp4; codecs="opus",audio/mp4; codecs="flac",video/webm; codecs="vp8",video/webm; codecs="vp9",video/webm; codecs="vp09.00.10.08",audio/webm; codecs="vorbis",audio/webm; codecs="opus",video/mp2t; codecs="avc1.42E01E",video/mp2t; codecs="avc3.42E01E",video/mp2t; codecs="hvc1.1.6.L93.90",video/mp2t; codecs="mp4a.40.2",video/mp2t; codecs="ac-3",video/mp2t; codecs="ec-3",text/vtt,application/mp4; codecs="wvtt",application/ttml+xml,application/mp4; codecs="stpp"'.split(","));
|
|
451
451
|
for(l=p.next();!l.done;l=p.next())l=l.value,k[l]=Fc()?df(l)?!0:MediaSource.isTypeSupported(l)||Te(l):Gc(l),m=l.split(";")[0],k[m]=k[m]||k[l];d=k;e={manifest:c,media:d,drm:b};f=$l;for(g in f)e[g]=f[g]();return h["return"](e)})};V.isBrowserSupported=Fk;V.setAdManagerFactory=function(a){qk=a};V.registerSupportPlugin=function(a,b){$l[a]=b};V.prototype.destroy=V.prototype.destroy;
|
|
452
452
|
var Wl="abrstatuschanged",Ql="adaptation",Nl="buffering",$k="drmsessionupdate",Bj="emsg",Xl="error",Zl="expirationupdated",Kk="loaded",Ik="loading",Vk="manifestparsed",yl="metadata",Ck="onstatechange",Dk="onstateidle",Ol="ratechange",jl="streaming",Ul="textchanged",Vl="texttrackvisibility",Sk="timelineregionadded",Al="timelineregionenter",Bl="timelineregionexit",Sl="trackschanged",Nk="unloading",Tl="variantchanged",am={Og:Wl,Pg:Ql,Qg:Nl,Tg:$k,$g:Bj,Error:Xl,ah:Zl,gh:"largegap",hh:Kk,ih:Ik,mh:Vk,Metadata:yl,
|
|
453
|
-
qh:Ck,rh:Dk,Bh:Ol,Fh:"sessiondata",Gh:jl,Hh:Ul,Ih:Vl,Jh:Sk,Kh:Al,Lh:Bl,Mh:Sl,Qh:Nk,Sh:Tl},Ek=0,nk=1,il=2,tl=3;V.LoadMode={DESTROYED:Ek,NOT_LOADED:nk,MEDIA_SOURCE:il,SRC_EQUALS:tl};V.version="v3.1.
|
|
453
|
+
qh:Ck,rh:Dk,Bh:Ol,Fh:"sessiondata",Gh:jl,Hh:Ul,Ih:Vl,Jh:Sk,Kh:Al,Lh:Bl,Mh:Sl,Qh:Nk,Sh:Tl},Ek=0,nk=1,il=2,tl=3;V.LoadMode={DESTROYED:Ek,NOT_LOADED:nk,MEDIA_SOURCE:il,SRC_EQUALS:tl};V.version="v3.1.8";var bm=["3","1"];yb=new function(a){this.g=a;this.i=zb;this.h=Ab}(new wb(Number(bm[0]),Number(bm[1])));var Yl=["output-restricted","internal-error"],$l={},qk=null;function cm(){this.h=[];this.j=this.i=this.g=0};function dm(a,b){var c=this;this.h=a;this.g=b;this.i=!1;this.l=this.g.getVolume();this.j=new of;this.j.o(this.g,google.ima.AdEvent.Type.PAUSED,function(){c.i=!0});this.j.o(this.g,google.ima.AdEvent.Type.RESUMED,function(){c.i=!1})}q=dm.prototype;q.getDuration=function(){return this.h.getDuration()};q.getMinSuggestedDuration=function(){return this.h.getMinSuggestedDuration()};q.getRemainingTime=function(){return this.g.getRemainingTime()};q.isPaused=function(){return this.i};
|
|
454
454
|
q.isSkippable=function(){return 0<=this.h.getSkipTimeOffset()};q.getTimeUntilSkippable=function(){var a=this.h.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};q.canSkipNow=function(){return this.g.getAdSkippableState()};q.skip=function(){return this.g.skip()};q.pause=function(){return this.g.pause()};q.play=function(){return this.g.resume()};q.getVolume=function(){return this.g.getVolume()};q.setVolume=function(a){return this.g.setVolume(a)};q.isMuted=function(){return 0==this.g.getVolume()};
|
|
455
455
|
q.resize=function(a,b){this.g.resize(a,b,document.fullscreenElement?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)};q.setMuted=function(a){a?(this.l=this.getVolume(),this.setVolume(0)):this.setVolume(this.l)};q.getSequenceLength=function(){var a=this.h.getAdPodInfo();return null==a?1:a.getTotalAds()};q.getPositionInSequence=function(){var a=this.h.getAdPodInfo();return null==a?1:a.getAdPosition()};q.release=function(){this.g=this.h=null};M("shaka.ads.ClientSideAd",dm);
|
|
456
456
|
dm.prototype.release=dm.prototype.release;dm.prototype.getPositionInSequence=dm.prototype.getPositionInSequence;dm.prototype.getSequenceLength=dm.prototype.getSequenceLength;dm.prototype.setMuted=dm.prototype.setMuted;dm.prototype.resize=dm.prototype.resize;dm.prototype.isMuted=dm.prototype.isMuted;dm.prototype.setVolume=dm.prototype.setVolume;dm.prototype.getVolume=dm.prototype.getVolume;dm.prototype.play=dm.prototype.play;dm.prototype.pause=dm.prototype.pause;dm.prototype.skip=dm.prototype.skip;
|
|
457
|
-
dm.prototype.canSkipNow=dm.prototype.canSkipNow;dm.prototype.getTimeUntilSkippable=dm.prototype.getTimeUntilSkippable;dm.prototype.isSkippable=dm.prototype.isSkippable;dm.prototype.isPaused=dm.prototype.isPaused;dm.prototype.getRemainingTime=dm.prototype.getRemainingTime;dm.prototype.getMinSuggestedDuration=dm.prototype.getMinSuggestedDuration;dm.prototype.getDuration=dm.prototype.getDuration;function em(a,b,c,d){var e=this;this.m=a;this.i=b;this.A=null;this.B=NaN;this.j=d;this.v=null;this.h=new of;google.ima.settings.setLocale(c);a=new google.ima.AdDisplayContainer(this.m,this.i);a.initialize();this.l=new google.ima.AdsLoader(a);this.l.getSettings().setPlayerType("shaka-player");this.l.getSettings().setPlayerVersion("v3.1.
|
|
457
|
+
dm.prototype.canSkipNow=dm.prototype.canSkipNow;dm.prototype.getTimeUntilSkippable=dm.prototype.getTimeUntilSkippable;dm.prototype.isSkippable=dm.prototype.isSkippable;dm.prototype.isPaused=dm.prototype.isPaused;dm.prototype.getRemainingTime=dm.prototype.getRemainingTime;dm.prototype.getMinSuggestedDuration=dm.prototype.getMinSuggestedDuration;dm.prototype.getDuration=dm.prototype.getDuration;function em(a,b,c,d){var e=this;this.m=a;this.i=b;this.A=null;this.B=NaN;this.j=d;this.v=null;this.h=new of;google.ima.settings.setLocale(c);a=new google.ima.AdDisplayContainer(this.m,this.i);a.initialize();this.l=new google.ima.AdsLoader(a);this.l.getSettings().setPlayerType("shaka-player");this.l.getSettings().setPlayerVersion("v3.1.8");this.g=null;this.h.Ia(this.l,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,function(f){fm(e,f)});this.h.o(this.l,google.ima.AdErrorEvent.Type.AD_ERROR,
|
|
458
458
|
function(f){gm(e,f)});this.i.onended=function(){e.l.contentComplete()}}em.prototype.stop=function(){this.g&&this.g.stop();this.m&&Pj(this.m)};em.prototype.release=function(){this.stop();this.A&&this.A.disconnect();this.h&&this.h.release();this.g&&this.g.destroy();this.l.destroy()};function gm(a,b){b.getError();hm(a,null);a.j(new N("ad-cue-points-changed",(new Map).set("cuepoints",[])))}
|
|
459
459
|
function fm(a,b){a.j(new N("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.B)));a.g=b.getAdsManager(a.i);a.j(new N("ima-ad-manager-loaded",(new Map).set("imaAdManager",a.g)));var c=a.g.getCuePoints();if(c.length){var d=[];c=t(c);for(var e=c.next();!e.done;e=c.next())d.push(new im(e.value));a.j(new N("ad-cue-points-changed",(new Map).set("cuepoints",d)))}jm(a);try{a.g.init(a.i.offsetWidth,a.i.offsetHeight,document.fullscreenElement?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL),
|
|
460
460
|
a.h.o(a.i,"loadeddata",function(){a.g.resize(a.i.offsetWidth,a.i.offsetHeight,document.fullscreenElement?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),"ResizeObserver"in window&&(a.A=new ResizeObserver(function(){a.g.resize(a.i.offsetWidth,a.i.offsetHeight,document.fullscreenElement?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),a.A.observe(a.i)),a.g.start()}catch(f){hm(a,null)}}
|
|
@@ -475,8 +475,8 @@ this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.COMPLETE,function(){e.i(new
|
|
|
475
475
|
function nm(a,b){a.i(new N("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.G)));var c=b.getStreamData().url;a.j.resolve(c);a.j=null;a.F||a.h.o(a.l,"seeked",function(){var d=a.l.currentTime;if(0!=d){a.g.streamTimeForContentTime(d);var e=a.g.previousCuePointForStreamTime(d);e&&!e.played&&(a.v=d,a.l.currentTime=e.start)}})};function W(){bb.call(this);this.g=this.i=null;this.h=new cm;this.j=navigator.language}u(W,bb);q=W.prototype;q.setLocale=function(a){this.j=a};q.initClientSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.AdsLoader)throw new Q(2,10,1E4);this.i&&this.i.release();this.i=new em(a,b,this.j,function(d){if(d&&d.type)switch(d.type){case "ads-loaded":c.h.h.push(d.loadTime);break;case "ad-started":c.h.g++;break;case "ad-complete":c.h.i++;break;case "ad-skipped":c.h.j++}c.dispatchEvent(d)})};
|
|
476
476
|
q.release=function(){this.i&&(this.i.release(),this.i=null);this.g&&(this.g.release(),this.g=null);bb.prototype.release.call(this)};q.onAssetUnload=function(){this.i&&this.i.stop();this.g&&this.g.stop();this.dispatchEvent(new N("ad-stopped"));this.h=new cm};q.requestClientSideAds=function(a){if(!this.i)throw new Q(1,10,10001);var b=this.i;b.B=Date.now()/1E3;b.l.requestAds(a)};
|
|
477
477
|
q.initServerSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.dai)throw new Q(2,10,10002);this.g&&this.g.release();this.g=new mm(a,b,this.j,function(d){if(d&&d.type)switch(d.type){case "ads-loaded":c.h.h.push(d.loadTime);break;case "ad-started":c.h.g++;break;case "ad-complete":c.h.i++;break;case "ad-skipped":c.h.j++}c.dispatchEvent(d)})};
|
|
478
|
-
q.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new Q(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Oa('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.adTagParameters.mpt="shaka-player";a.adTagParameters.mpv="v3.1.
|
|
479
|
-
(c.F=!0),c.j=new Oe,c.g.requestStream(a),c.D=d||"",c.G=Date.now()/1E3,c=c.j);return c};q.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new Q(1,10,10003);(a.mpt||a.mpv)&&Oa('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.mpt="Shaka Player";a.mpv="v3.1.
|
|
478
|
+
q.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new Q(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Oa('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.adTagParameters.mpt="shaka-player";a.adTagParameters.mpv="v3.1.8";c=this.g;var d=b;c.j?c=Promise.reject(new Q(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
|
|
479
|
+
(c.F=!0),c.j=new Oe,c.g.requestStream(a),c.D=d||"",c.G=Date.now()/1E3,c=c.j);return c};q.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new Q(1,10,10003);(a.mpt||a.mpv)&&Oa('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.mpt="Shaka Player";a.mpv="v3.1.8";this.g.g.replaceAdTagParameters(a)};
|
|
480
480
|
q.getStats=function(){var a=this.h;return{loadTimes:a.h,started:a.g,playedCompletely:a.i,skipped:a.j}};q.onDashTimedMetadata=function(a){if(this.g&&"urn:google:dai:2018"==a.schemeIdUri){var b=a.schemeIdUri,c=a.eventElement?a.eventElement.getAttribute("messageData"):null;this.g.g.processMetadata(b,c,a.startTime)}};q.onHlsTimedMetadata=function(a,b){this.g&&this.g.g.processMetadata("ID3",a.data,b)};q.onCueMetadataChange=function(a){if(this.g)this.g.onCueMetadataChange(a)};M("shaka.ads.AdManager",W);
|
|
481
481
|
W.prototype.onCueMetadataChange=W.prototype.onCueMetadataChange;W.prototype.onHlsTimedMetadata=W.prototype.onHlsTimedMetadata;W.prototype.onDashTimedMetadata=W.prototype.onDashTimedMetadata;W.prototype.getStats=W.prototype.getStats;W.prototype.replaceServerSideAdTagParameters=W.prototype.replaceServerSideAdTagParameters;W.prototype.requestServerSideStream=W.prototype.requestServerSideStream;W.prototype.initServerSide=W.prototype.initServerSide;W.prototype.requestClientSideAds=W.prototype.requestClientSideAds;
|
|
482
482
|
W.prototype.onAssetUnload=W.prototype.onAssetUnload;W.prototype.release=W.prototype.release;W.prototype.initClientSide=W.prototype.initClientSide;W.prototype.setLocale=W.prototype.setLocale;function im(a,b){this.start=a;this.end=void 0===b?null:b}W.ADS_LOADED="ads-loaded";W.AD_STARTED="ad-started";W.AD_FIRST_QUARTILE="ad-first-quartile";W.AD_MIDPOINT="ad-midpoint";W.AD_THIRD_QUARTILE="ad-third-quartile";W.AD_COMPLETE="ad-complete";W.AD_STOPPED="ad-stopped";W.AD_SKIPPED="ad-skipped";
|