From 46d12e587328f3f39d26941760d3e1257b25603c Mon Sep 17 00:00:00 2001 From: gramps Date: Sun, 1 Nov 2026 14:07:14 -0800 Subject: [PATCH] =?UTF-8?q?fix(alerts):=20Test=20alert=20actually=20plays?= =?UTF-8?q?=20=E2=80=94=20it=20was=20queuing=20into=20nothing?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit TestAlert called Enqueue, which is the pure test seam: it fills the queue and returns. The alert layer needs three more things to show anything — its scene list, the playback ticker running, and the preview refreshed — and all three live in OnMessageReceived, the same entry the chat feed uses (MainViewModel.Chat.cs). Now it calls OnMessageReceived(message, Scenes), so the clip advances on the ticker and writes frames to the box's VideoImageSource, which is what the preview pane displays. --- ViewModels/MainViewModel.Overlays.cs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ViewModels/MainViewModel.Overlays.cs b/ViewModels/MainViewModel.Overlays.cs index 59619d3..6ff6a0f 100644 --- a/ViewModels/MainViewModel.Overlays.cs +++ b/ViewModels/MainViewModel.Overlays.cs @@ -129,7 +129,10 @@ public partial class MainViewModel : ViewModelBase private void TestAlert() { - _alertLayer.Enqueue(new Models.ChatMessage + // ⛔ OnMessageReceived, not Enqueue: Enqueue only fills the queue. The layer needs its scene + // list, its playback ticker started and its previews refreshed — that is what the chat path + // does (MainViewModel.Chat.cs), and it is why a bare Enqueue played nothing in the pane. + _alertLayer.OnMessageReceived(new Models.ChatMessage { AuthorName = "Test viewer", Message = "Test alert — this is what a Super Chat looks like.", @@ -140,7 +143,7 @@ public partial class MainViewModel : ViewModelBase SuperChatCurrency = "$", SuperChatDisplayString = "$5.00", Kind = Models.ChatEventKind.SuperChat, - }); + }, Scenes); } public ICommand OpenSettingsCommand { get; }