Skip to content

Volume bar, audio knobs, subtitle position and the audio-menu drag start on any mouse button and never end when released outside the player #183

Closed

Description

@Nawid3333

Severity: medium

Where: chrome/player/ui/VolumeControls.mjs (onVolumeBarMouseDown), chrome/player/ui/components/Knob.mjs (the container mousedown), chrome/player/ui/subtitles/SubtitlesManager.mjs (createSubtitleDisplayElements's wrapper mousedown), chrome/player/ui/menus/PlaybackRateChanger.mjs (onAudioMouseDown)

What happens

None of these checks event.button, and the drag ends only on a mouseup delivered to DOMElements.playerContainer. A right-click opens the context menu, which swallows the mouseup, exactly the mechanism the SubtitleSyncer fix in CLAUDE.md describes ("the track then followed the pointer"). After closing the menu, every mouse move inside the player drags the volume/knob/subtitle until a left click. Releasing outside the player has the same effect for the volume bar, knobs and subtitles. FineTimeControls got a document mouseup and an e.buttons === 0 guard for this; these did not.

Suggested fix

if (event.button !== 0) return; at the top of each mousedown handler; end the drag on document mouseup and on a mousemove with e.buttons === 0, as FineTimeControls does (or use pointer events with setPointerCapture).

Confidence: high for the right-click case; medium for the out-of-window release.


From a line-by-line code review of the tree at 41363fd (2026-10-02). Each claim above was checked against the source before filing; the reproduction steps and line references are as of that commit.


Generated by Claude Code

Activity

  1. added
    bugSomething isn't working
    code-reviewFound by the 2026-10-02 line-by-line review
    on Oct 2, 2026
  2. added a commit that references this issue on Oct 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingcode-reviewFound by the 2026-10-02 line-by-line review

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions