Repository navigation
Keep the view in place when double-clicking a clip or track area - #12141
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI (base), Organization UI (inherited) Review profile: CHILL Plan: Advanced Run ID: 📥 CommitsReviewing files that changed from the base of the PR and between 8007d41021bae752f3546355535878f332586b5d and 9fc85cd1bc695fa3fafce1b87bd826bf0ed9d78e. 📒 Files selected for processing (3)
Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review. 📝 WalkthroughWalkthroughThe play cursor now provides Priority: ➖ Normal Estimated code review effort: 2 (Simple) | ~10 minutes Severity of issue fixed: Medium Sequence Diagram(s)sequenceDiagram
participant TracksItemsView
participant PlayCursorController
participant PlaybackState
TracksItemsView->>PlayCursorController: seekToTimeKeepingView(startTime)
PlayCursorController->>PlaybackState: seekTime(startTime)
PlaybackState-->>PlayCursorController: playbackPositionChanged(startTime)
PlayCursorController->>PlayCursorController: updatePositionX(startTime)
PlayCursorController-->>TracksItemsView: retain the current view frame
Merge Risk: 🔵 Low · up to A narrow sequence involving a negative seek at the project start can leave the view unchanged on the following ordinary seek. The behavior is localized but should be corrected. 🚥 Pre-merge checks | ✅ 3 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (3 passed)
Full details: Out of Scope Changes checkExplanation The pull request also changes play-cursor dragging to clamp the timeline position to zero or later during press, movement, and release. This behavior does not implement or verify the issue Warning Linked repositories: Public OSS repositories can only analyze public repositories installed in this organization. No linked repositories were analyzed; skipped Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI (base), Organization UI (inherited)
Review profile: CHILL
Plan: Advanced
Run ID: 9ccd6cc9-411c-4585-b841-287199e4212f
📥 Commits
Reviewing files that changed from the base of the PR and between 52941d6 and 8007d41021bae752f3546355535878f332586b5d.
📒 Files selected for processing (4)
src/projectscene/qml/Audacity/ProjectScene/tracksitemsview/TracksItemsView.qmlsrc/projectscene/tests/playcursorcontroller_tests.cppsrc/projectscene/view/playcursor/playcursorcontroller.cppsrc/projectscene/view/playcursor/playcursorcontroller.h
Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review.
| void PlayCursorController::seekToTimeKeepingView(double secs) | ||
| { | ||
| if (!playbackState()->isPlaying()) { | ||
| m_keepViewOnSeek = true; |
There was a problem hiding this comment.
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
Clear the flag when the seek does not dispatch.
If secs is negative and playback is already at zero, seekToTime() returns without a position update. Line 93 leaves m_keepViewOnSeek set. The next ordinary seek then consumes the flag and does not move the frame.
Make seekToTime() report whether it dispatched, or clear m_keepViewOnSeek when this call is a no-op.
| @@ -198,7 +208,7 @@ void PlayCursorController::updatePositionX(muse::secs_t secs) | |||
| } | |||
| } | |||
| } | |||
| } else { | |||
| } else if (!keepView) { | |||
There was a problem hiding this comment.
this is to avoid the smooth scroll right?
8007d41 to
9fc85cd
Compare
9fc85cd to
846cf9e
Compare
Keep the view in place when double-clicking a clip or track area (#12141)
Resolves: #12013
Recommended:
QA: