mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
fix: pass player to playbackManager
This commit is contained in:
parent
6c0a173361
commit
c7f31c0fac
1 changed files with 3 additions and 3 deletions
|
@ -480,7 +480,7 @@ function tryRemoveElement(elem) {
|
|||
secondaryTrackValid = false;
|
||||
}
|
||||
// secondary track should not be shown if primary track is no longer a valid pair
|
||||
if (initialSubtitleStream && !playbackManager.trackHasSecondarySubtitleSupport(initialSubtitleStream)) {
|
||||
if (initialSubtitleStream && !playbackManager.trackHasSecondarySubtitleSupport(initialSubtitleStream, this)) {
|
||||
secondaryTrackValid = false;
|
||||
}
|
||||
} else {
|
||||
|
@ -488,11 +488,11 @@ function tryRemoveElement(elem) {
|
|||
}
|
||||
|
||||
// Get the secondary track that has been set during this watch session
|
||||
let currentSecondaryTrackIndex = playbackManager.getSecondarySubtitleStreamIndex();
|
||||
let currentSecondaryTrackIndex = playbackManager.getSecondarySubtitleStreamIndex(this);
|
||||
|
||||
if (!secondaryTrackValid) {
|
||||
currentSecondaryTrackIndex = -1;
|
||||
playbackManager.setSecondarySubtitleStreamIndex(currentSecondaryTrackIndex);
|
||||
playbackManager.setSecondarySubtitleStreamIndex(currentSecondaryTrackIndex, this);
|
||||
}
|
||||
|
||||
this.#secondarySubtitleTrackIndexToSetOnPlaying = currentSecondaryTrackIndex == null ? -1 : currentSecondaryTrackIndex;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue