Skip to content

fix: defer timeline pointer capture until drag starts so clip child clicks work#148

Merged
dazzatronus merged 1 commit into
mainfrom
derk/fix-mask-badge-click
Jul 22, 2026
Merged

fix: defer timeline pointer capture until drag starts so clip child clicks work#148
dazzatronus merged 1 commit into
mainfrom
derk/fix-mask-badge-click

Conversation

@dazzatronus

Copy link
Copy Markdown
Contributor

What

Clicking the luma mask badge on a timeline clip no longer detached the mask. Capturing the pointer to the tracks container on every clip pointerdown retargets the derived click event away from clip children, so the badge's click handler never fired.

Pointer capture now happens only when a gesture commits: immediately for resize, and at the drag threshold for drags. Plain clicks flow to clip children untouched.

Why it's safe

The interruption handling that introduced the capture is preserved: pointercancel and the lost-pointerup buttons check are unchanged, and drag/resize (the only states with visible stuck-clip risk) still capture. A lost pointerup during the pending state has no visual side effects and is cleared by the existing cancel paths. All six interruption tests pass unchanged.

Verify

  • New test: no capture on plain pointerdown, capture once the drag threshold is crossed.
  • Manual: attach a luma to a clip, click the ◐ badge → mask detaches to a new track. Drag a clip and release outside the window → no stuck clip.

@dazzatronus
dazzatronus merged commit 589cd18 into main Jul 22, 2026
1 check passed
@github-actions

Copy link
Copy Markdown

🎉 This PR is included in version 2.15.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant