mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Cast playback time update
This commit is contained in:
parent
e8084be0db
commit
dc2fc2f857
1 changed files with 10 additions and 2 deletions
|
@ -628,7 +628,7 @@
|
|||
return;
|
||||
}
|
||||
|
||||
this.currentMediaOffset = startTimeTicks;
|
||||
this.currentMediaOffset = startTimeTicks || 0;
|
||||
|
||||
var maxBitrate = 12000000;
|
||||
var mediaInfo = getMediaSourceInfo(user, item, maxBitrate, mediaSourceId, audioStreamIndex, subtitleStreamIndex);
|
||||
|
@ -827,6 +827,10 @@
|
|||
this.onError.bind(this));
|
||||
this.castPlayerState = PLAYER_STATE.STOPPED;
|
||||
clearInterval(this.timer);
|
||||
var playTime = document.getElementById(this.playback);
|
||||
if (playTime) {
|
||||
playTime.parentNode.removeChild(playTime);
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -958,8 +962,12 @@
|
|||
|
||||
if (this.currentMediaDuration > 0) {
|
||||
var pp = Number(this.currentMediaTime / this.currentMediaDuration).toFixed(3);
|
||||
|
||||
var startTime = this.currentMediaOffset / 10000000;
|
||||
document.getElementById(this.playback).innerHTML = formatTime(startTime + this.currentMediaTime);
|
||||
var playTime = document.getElementById(this.playback);
|
||||
if (playTime) {
|
||||
playTime.innerHTML = formatTime(startTime + this.currentMediaTime);
|
||||
}
|
||||
}
|
||||
|
||||
if (this.progressFlag) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue