From 89d652ba3a9ec03f40cc780179812da54fbe0a1b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois?= Date: Sun, 26 Nov 2023 02:26:44 +0100 Subject: [PATCH] don't run update before window creation in winit (#10741) # Objective - Window size, scale and position are not correct on the first execution of the systems - Fixes #10407, fixes #10642 ## Solution - Don't run `update` before we get a chance to create the window in winit - Finish reverting #9826 after #10389 --- crates/bevy_winit/src/lib.rs | 3 --- 1 file changed, 3 deletions(-) diff --git a/crates/bevy_winit/src/lib.rs b/crates/bevy_winit/src/lib.rs index 7d531a281a432..2f043727321f3 100644 --- a/crates/bevy_winit/src/lib.rs +++ b/crates/bevy_winit/src/lib.rs @@ -349,11 +349,8 @@ impl Default for WinitAppRunnerState { /// `EventLoop`. pub fn winit_runner(mut app: App) { if app.plugins_state() == PluginsState::Ready { - // If we're already ready, we finish up now and advance one frame. - // This prevents black frames during the launch transition on iOS. app.finish(); app.cleanup(); - app.update(); } let mut event_loop = app