Skip to content

SequencePlayer: replace basic Slider with a TimelineSlider component#3059

Open
Copilot wants to merge 1 commit intodevelopfrom
copilot/replace-basic-slider-with-timeline-component
Open

SequencePlayer: replace basic Slider with a TimelineSlider component#3059
Copilot wants to merge 1 commit intodevelopfrom
copilot/replace-basic-slider-with-timeline-component

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 27, 2026

The SequencePlayer used a plain Slider with an inline custom background. This replaces it with a dedicated TimelineSlider component that looks and behaves like a real timeline.

Description

Introduces TimelineSlider, a Slider subclass with timeline-style visuals, and wires it into SequencePlayer.

Features list

  • Playhead handle — downward triangle + vertical line (palette.highlight) replaces the default circular thumb
  • Ruler — frame-number labels and tick marks above the track; major-tick interval adapts to range (1 / 5 / 10 / 50 / 100 / 250)
  • Taller track — 8 px (up from 4 px), rounded ends
  • Cached-frame highlighting — blue intervals preserved, extracted into a cachedFrames property on the component
  • TimelineSlider registered in Controls/qmldir for reuse

Implementation remarks

TimelineSlider keeps the same public interface as Slider (from, to, value, stepSize, snapMode, live, pressed) so the drop-in replacement in SequencePlayer requires no logic changes — only the inline background/cacheView block is removed.

The cached-frame x-position formula (modelData.x * frameLength) is intentionally unchanged from the original: cachedFrames carries 0-based frame indices relative to sequence start, matching frameRange.min = 0 in the existing model.

The ruler tick interval is chosen so there are ~10–15 major ticks regardless of sequence length, preventing label crowding without requiring dynamic width measurement.

@codecov
Copy link
Copy Markdown

codecov Bot commented Mar 27, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 83.36%. Comparing base (9bed2ab) to head (d2444c8).
⚠️ Report is 2 commits behind head on develop.
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #3059      +/-   ##
===========================================
- Coverage    83.38%   83.36%   -0.03%     
===========================================
  Files           73       73              
  Lines         9874     9880       +6     
===========================================
+ Hits          8233     8236       +3     
- Misses        1641     1644       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@cbentejac cbentejac force-pushed the copilot/replace-basic-slider-with-timeline-component branch from c72d769 to d2444c8 Compare April 9, 2026 11:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants