aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormehekj <mehek.jethani@gmail.com>2022-06-21 14:01:33 -0400
committermehekj <mehek.jethani@gmail.com>2022-06-21 14:01:33 -0400
commit2852e29c73ccfe86e81f63258a843cc614b9e62e (patch)
tree619eb87c10e5a796a80ff3133282c9d278986367 /src
parent5a3bec8422a078a1c66f84587bd4de5e200f8caf (diff)
fixed scrubbing in full screen or after dragging slider
Diffstat (limited to 'src')
-rw-r--r--src/client/views/nodes/VideoBox.tsx12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/client/views/nodes/VideoBox.tsx b/src/client/views/nodes/VideoBox.tsx
index 43f052859..4c6680dcf 100644
--- a/src/client/views/nodes/VideoBox.tsx
+++ b/src/client/views/nodes/VideoBox.tsx
@@ -163,7 +163,8 @@ export class VideoBox extends ViewBoxAnnotatableComponent<ViewBoxAnnotatableProp
@action
keyEvents = (e: KeyboardEvent) => {
if (
- !(e.target instanceof HTMLInputElement) &&
+ // need to include range inputs because after dragging time slider it becomes target element
+ !(e.target instanceof HTMLInputElement && !(e.target.type === "range")) &&
this.props.isSelected(true)
) {
switch (e.key) {
@@ -283,10 +284,11 @@ export class VideoBox extends ViewBoxAnnotatableComponent<ViewBoxAnnotatableProp
// fades out controls in fullscreen after mouse stops moving
@action controlsFade = (e: PointerEvent) => {
e.stopPropagation();
- clearTimeout(this._controlsFadeTimer);
- this._controlsVisible = true;
- this._scrubbing = false;
- this._controlsFadeTimer = setTimeout(action(() => this._controlsVisible = false), 3000);
+ if (!this._scrubbing) {
+ clearTimeout(this._controlsFadeTimer);
+ this._controlsVisible = true;
+ this._controlsFadeTimer = setTimeout(action(() => this._controlsVisible = false), 3000);
+ }
}