From a57287f8ad76ee92c908bfec1ebaa6d6185c470f Mon Sep 17 00:00:00 2001 From: Erik Date: Thu, 13 Aug 2026 09:18:30 +0200 Subject: [PATCH] fix: move the #387 resize evidence line into the typed owner MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit GameWindowSlice8BoundaryTests.FramebufferResize_IsOneTypedOwnerHandoff correctly rejected the log line added to GameWindow.OnFramebufferResize — the window callback is contractually a one-line handoff. The line now lives in FramebufferResizeController.Resize after its zero-size gate, which is also the better home (one owner, all callers covered). Full Debug App suite 4,941/3 skips. Co-Authored-By: Claude Fable 5 --- src/AcDream.App/Rendering/FramebufferResizeController.cs | 7 +++++++ src/AcDream.App/Rendering/GameWindow.cs | 7 +------ 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/src/AcDream.App/Rendering/FramebufferResizeController.cs b/src/AcDream.App/Rendering/FramebufferResizeController.cs index 9b962f79..84759f27 100644 --- a/src/AcDream.App/Rendering/FramebufferResizeController.cs +++ b/src/AcDream.App/Rendering/FramebufferResizeController.cs @@ -111,6 +111,13 @@ internal sealed class FramebufferResizeController if (width <= 0 || height <= 0) return; + // #387 evidence line (permanent — resize events are rare and this is + // the only trace of whether the native event fired at all). Lives here + // rather than in GameWindow.OnFramebufferResize because the window + // callback is contractually a one-line typed-owner handoff + // (GameWindowSlice8BoundaryTests.FramebufferResize_IsOneTypedOwnerHandoff). + Console.WriteLine($"window: framebuffer resize event {width}x{height}"); + // Frozen order: GL viewport, shared aspect publication, camera, then // the optional developer-tools layout reset (unbound since Campaign V // slice V11 removed the ImGui frontend). Late binding never replays an diff --git a/src/AcDream.App/Rendering/GameWindow.cs b/src/AcDream.App/Rendering/GameWindow.cs index d55788e3..5baab269 100644 --- a/src/AcDream.App/Rendering/GameWindow.cs +++ b/src/AcDream.App/Rendering/GameWindow.cs @@ -1625,12 +1625,7 @@ public sealed class GameWindow : /// previously off the new viewport snap back to default positions. /// private void OnFramebufferResize(Silk.NET.Maths.Vector2D newSize) - { - // #387 evidence line (permanent — resize events are rare and this is - // the only trace of whether the native event fired at all). - Console.WriteLine($"window: framebuffer resize event {newSize.X}x{newSize.Y}"); - _framebufferResize.Resize(newSize); - } + => _framebufferResize.Resize(newSize); private void OnClosing() => CompleteShutdown(releaseNativeWindow: false);