G2 (#66): respect solo and visibility in viewer selection

This commit is contained in:
Jonas Neubauer
2026-10-05 18:01:41 +02:00
parent e5c58600fd
commit a0c1b60d61
5 changed files with 119 additions and 16 deletions
+2 -4
View File
@@ -119,10 +119,8 @@ fn edited(app: &EffectcraftApp, ectx: &EvalCtx, lid: LayerId) -> Option<Edited>
/// The topmost text layer whose text is under screen point `s`.
fn text_layer_at(app: &EffectcraftApp, ectx: &EvalCtx, map: &ViewerMap, s: Pos2) -> Option<Edited> {
ectx.comp
.layers
.iter()
.filter(|l| matches!(l.source, LayerSource::Text) && l.is_active_at(ectx.time) && l.switches.video && !l.switches.locked)
super::viewer::selectable_layers(ectx.comp, ectx.time)
.filter(|l| matches!(l.source, LayerSource::Text))
.filter_map(|l| edited(app, ectx, l.id))
.find(|e| e.contains(map, s))
}