diff --git a/winit/src/application.rs b/winit/src/application.rs index 5aefb378..ef6c8463 100644 --- a/winit/src/application.rs +++ b/winit/src/application.rs @@ -299,11 +299,16 @@ async fn run_instance( messages.push(message); } event::Event::RedrawRequested(_) => { + let physical_size = state.physical_size(); + + if physical_size.width == 0 || physical_size.height == 0 { + continue; + } + debug.render_started(); let current_viewport_version = state.viewport_version(); if viewport_version != current_viewport_version { - let physical_size = state.physical_size(); let logical_size = state.logical_size(); debug.layout_started();