authorgravatar for git@paperclover.netclover caruso <git@paperclover.net> 2026-09-24 02:45:00-07:00
committergravatar for git@paperclover.netclover caruso <git@paperclover.net> 2026-09-25 20:26:21-07:00
logc3f7869026fe3c368c667c6d6d40cfe6c7fef277
treef5f781855f8036aeb5c3ebddd22939cc89741506
parent22ec560def0e7769c2cfd79da312576382966e1e
signature Signed by SSH key SHA256:52mNGHRsVFBDED9IAX5pe+LRWUefqTbxEReunq21QvU

fix: present the resized frame inside the window resize

The surface already presents with AppKit's transaction, but a resize only requested a redraw, so the window could show the previous frame stretched to the new size until the next turn of the event loop. Resized now draws before returning. Built and tested headless; the visual result has not yet been checked on a display. Assisted-by: claude-opus-5.5

1 files changed, 3 insertions(+), 0 deletions(-)

crates/snowbound/src/main.rs+3
...@@ -1354,6 +1354,9 @@ impl ApplicationHandler<UserEvent> for App {...@@ -1354,6 +1354,9 @@ impl ApplicationHandler<UserEvent> for App {
1354 .surface1354 .surface
1355 .configure(&state.renderer.device, &state.config);1355 .configure(&state.renderer.device, &state.config);
1356 state.changed()?;1356 state.changed()?;
1357 // Present inside AppKit's resize transaction; a redraw on the next turn
1358 // lets the window show the previous frame at the new size.
1359 state.draw()?;
1357 }1360 }
1358 }1361 }
1359 WindowEvent::ScaleFactorChanged { scale_factor, .. } => {1362 WindowEvent::ScaleFactorChanged { scale_factor, .. } => {