M13.33: nested comp markers on the precomp layer bar
- commands::markers::nested_markers: a precomp layer's comp markers at their times in the
containing comp (start and stretch in closed form; with time remapping or a stretch over
protected regions, the first frame whose source time reaches them), within In–Out.
- markers.nested {layer}: the same list for agents.
- Timeline: drawn on the precomp bar as outlined read-only markers (positions cached per
revision), hover names them, double-click opens the nested comp at the marker; automation id
timeline.layer.<id>.nestedMarker.<i>.
- Tests: engine (start, stretch, trim, time remap, non-precomp error), UI (draw, label, open).
Docs: parity, control protocol.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
1ac55c33a3
commit
f013bdd8d7
@@ -144,3 +144,25 @@ fn tab_drag_snapshot() {
|
||||
std::fs::create_dir_all(dir).unwrap();
|
||||
h.render().expect("render").save(format!("{dir}/tab-drag.png")).unwrap();
|
||||
}
|
||||
|
||||
/// A precomp layer's bar shows its comp's markers; a double-click opens that comp at the marker.
|
||||
#[test]
|
||||
fn nested_comp_markers_show_on_the_precomp_bar() {
|
||||
let (mut h, pre, main) = harness();
|
||||
{
|
||||
let s = &mut h.state_mut().session;
|
||||
s.execute("comp.open", json!({"comp": pre})).unwrap();
|
||||
s.execute("markers.set", json!({"new": true, "time": 1.0, "comment": "beat"})).unwrap();
|
||||
s.execute("comp.open", json!({"comp": main})).unwrap();
|
||||
}
|
||||
h.run_steps(4);
|
||||
let l = h.state().session.project.comp(ItemId(main)).unwrap().layers[0].id.0;
|
||||
let id = format!("timeline.layer.{l}.nestedMarker.0");
|
||||
let m = rect(&h, &id);
|
||||
let e = h.state().auto.find(&id).unwrap().clone();
|
||||
assert_eq!(e.label, "beat (marker in Pre)");
|
||||
click_n(&mut h, m.center(), 2);
|
||||
assert_eq!(h.state().session.active_comp_id(), Some(ItemId(pre)));
|
||||
// (29.97 fps: the marker's frame is at 1.001 s)
|
||||
assert!((h.state().session.time().seconds() - 1.0).abs() < 0.034, "{}", h.state().session.time().seconds());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user