client(hotkeys): remove seekstep VLC behavior

closes #2810
pull/3746/head
kontrollanten 2021-02-05 09:49:15 +01:00 committed by Chocobozzz
parent e0b5972167
commit 684cdacbbd
1 changed files with 8 additions and 13 deletions

View File

@ -543,24 +543,19 @@ export class PeertubePlayerManager {
enableVolumeScroll: false,
enableModifiersForNumbers: false,
rewindKey: function (event: KeyboardEvent) {
return isNaked(event, 'ArrowLeft')
},
forwardKey: function (event: KeyboardEvent) {
return isNaked(event, 'ArrowRight')
},
fullscreenKey: function (event: KeyboardEvent) {
// fullscreen with the f key or Ctrl+Enter
return isNaked(event, 'f') || (!event.altKey && event.ctrlKey && event.key === 'Enter')
},
seekStep: function (event: KeyboardEvent) {
// mimic VLC seek behavior, and default to 5 (original value is 5).
if (event.ctrlKey && event.altKey) {
return 5 * 60
} else if (event.ctrlKey) {
return 60
} else if (event.altKey) {
return 10
} else {
return 5
}
},
customKeys: {
increasePlaybackRateKey: {
key: function (event: KeyboardEvent) {