From 054a576b7720081f8c80b5ca09219ed2fe241dac Mon Sep 17 00:00:00 2001 From: Chris Wilson <203455+cbw@users.noreply.github.com> Date: Sun, 28 Jul 2024 13:37:08 -0700 Subject: [PATCH] Add ability to seek video -0.1/+0.1 seconds with ctrl/meta modifier key on arrow down/up --- web/src/components/player/VideoControls.tsx | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/web/src/components/player/VideoControls.tsx b/web/src/components/player/VideoControls.tsx index 70d9a4be8..7ca852b8b 100644 --- a/web/src/components/player/VideoControls.tsx +++ b/web/src/components/player/VideoControls.tsx @@ -148,17 +148,25 @@ export default function VideoControls({ switch (key) { case "ArrowDown": - onSeek(-1); + if (modifiers.ctrl) { + onSeek(-0.1); + } else { + onSeek(-1); + } break; case "ArrowLeft": onSeek(-10); break; + case "ArrowUp": + if (modifiers.ctrl) { + onSeek(1 / 30); + } else { + onSeek(1); + } + break; case "ArrowRight": onSeek(10); break; - case "ArrowUp": - onSeek(1); - break; case "f": if (toggleFullscreen && !modifiers.repeat) { toggleFullscreen();