mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Save playback speed rate, and restore when playing a video again
This commit is contained in:
parent
55e09b6466
commit
5ffe4aac8f
3 changed files with 13 additions and 0 deletions
|
@ -446,6 +446,7 @@ import { appRouter } from '../../../components/appRouter';
|
|||
updatePlayerStateInternal(event, player, state);
|
||||
updatePlaylist();
|
||||
enableStopOnBack(true);
|
||||
updatePlaybackRate(player);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1253,6 +1254,14 @@ import { appRouter } from '../../../components/appRouter';
|
|||
}
|
||||
}
|
||||
|
||||
function updatePlaybackRate(player) {
|
||||
// Restore playback speed control, if it exists in the session.
|
||||
const playbackRateSpeed = sessionStorage.getItem('playbackRateSpeed');
|
||||
if (playbackRateSpeed !== null) {
|
||||
player.setPlaybackRate(playbackRateSpeed);
|
||||
}
|
||||
}
|
||||
|
||||
shell.enableFullscreen();
|
||||
|
||||
let currentPlayer;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue