Fix: add IsAlertBox virtual on SceneElement and override on Source

The Stream Alerts properties panel was incorrectly showing for the webcam
layer (a WebcamSceneConfig is not a Source) because IsAlertBox only existed
on Source, causing WPF binding to be treated as false-but-invisible context
or the trigger to bind against the wrong type. Adding a virtual IsAlertBox
to the base SceneElement (default false) and overriding on Source prevents
the UI block from rendering under webcam selection. Scope: Models/SceneElement.cs, Models/Source.cs, ytLive.Tests/AlertBoxPreviewVisibilityTests.cs. Build/test: app + 4 alert-box tests pass, other failures unrelated (float precision).
This commit is contained in:
2026-10-05 13:26:12 -07:00
parent 9d04aea55b
commit a8e3954f01
2 changed files with 4 additions and 1 deletions
+1 -1
View File
@@ -238,7 +238,7 @@ public class Source : SceneElement
set => Set(ref _alertDisplayMethod, value);
}
public bool IsAlertBox => Type == SourceType.AlertBox;
public override bool IsAlertBox => Type == SourceType.AlertBox;
// Chat box config (TASK 3.18)
private double _chatFontSize = 16;