File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -3319,7 +3319,13 @@ shaka.Player = class extends shaka.util.FakeEventTarget {
3319
3319
this . loadEventManager_ ,
3320
3320
( ) => {
3321
3321
this . playhead_ . ready ( ) ;
3322
- fullyLoaded . resolve ( ) ;
3322
+ // We don't consider native HLS playback "fully loaded" until
3323
+ // we have loaded the first frame. This gives the browser time
3324
+ // to load caption information.
3325
+ if ( ! this . mimeType_ ||
3326
+ ! shaka . util . MimeUtils . isHlsType ( this . mimeType_ ) ) {
3327
+ fullyLoaded . resolve ( ) ;
3328
+ }
3323
3329
} ) ;
3324
3330
3325
3331
const waitForNativeTracks = ( ) => {
@@ -3388,6 +3394,11 @@ shaka.Player = class extends shaka.util.FakeEventTarget {
3388
3394
}
3389
3395
3390
3396
this . setupPreferredTextOnSrc_ ( ) ;
3397
+
3398
+ if ( this . mimeType_ &&
3399
+ shaka . util . MimeUtils . isHlsType ( this . mimeType_ ) ) {
3400
+ fullyLoaded . resolve ( ) ;
3401
+ }
3391
3402
} ) ;
3392
3403
3393
3404
if ( mediaElement . error ) {
You can’t perform that action at this time.
0 commit comments