Skip to content

Commit

Permalink
fix(Demo): Show correctly external text in the Demo (#5521)
Browse files Browse the repository at this point in the history
Backported to v4.3.x
  • Loading branch information
avelad authored and joeyparrish committed Aug 30, 2023
1 parent fd2b377 commit 01403c4
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions demo/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -1323,6 +1323,11 @@ shakaDemo.Main = class {
this.video_.poster = shakaDemo.Main.audioOnlyPoster_;
}

for (const extraText of asset.extraText) {
this.player_.addTextTrackAsync(extraText.uri, extraText.language,
extraText.kind, extraText.mime, extraText.codecs);
}

// If the asset has an ad tag attached to it, load the ads
const adManager = this.player_.getAdManager();
if (adManager && asset.adTagUri) {
Expand Down

0 comments on commit 01403c4

Please sign in to comment.