mirror of
https://github.com/storytold/effectcraft.git
synced 2026-11-10 18:31:30 -06:00
Timeline: note that a snapped bar edge off the frame grid lands within half a frame (#1828)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
3c6abe3606
commit
d0eb89904c
@@ -3498,7 +3498,8 @@ struct BarDrag {
|
|||||||
|
|
||||||
/// The whole frames a bar drag of `px` moves its ends by: truncated as the pointer goes, or with
|
/// The whole frames a bar drag of `px` moves its ends by: truncated as the pointer goes, or with
|
||||||
/// `shift`, the move that puts one of `ends` on the nearest target within 8 px of the pointer
|
/// `shift`, the move that puts one of `ends` on the nearest target within 8 px of the pointer
|
||||||
/// (#1828). Measured from the pointer, never the snapped result, so dragging on lets go.
|
/// (#1828). Measured from the pointer, never the snapped result, so dragging on lets go. The
|
||||||
|
/// move stays whole frames, so an end off the frame grid lands within half a frame of its target.
|
||||||
fn bar_drag_frames(px: f64, pps: f64, fd: f64, ends: &[f64], targets: &[f64], shift: bool) -> i64 {
|
fn bar_drag_frames(px: f64, pps: f64, fd: f64, ends: &[f64], targets: &[f64], shift: bool) -> i64 {
|
||||||
let secs = px / pps;
|
let secs = px / pps;
|
||||||
let snapped = shift
|
let snapped = shift
|
||||||
|
|||||||
Reference in New Issue
Block a user