macOS: Fix flicker during OS Window resize

Do not sync rendering to system vsync in out of sequence renders.
This commit is contained in:
Kovid Goyal
2026-03-03 08:51:41 +05:30
parent b8faada186
commit 77ac85f97b
2 changed files with 7 additions and 1 deletions

View File

@@ -254,6 +254,8 @@ Detailed list of changes
- macOS: Fix a crash when using :opt:`macos_traditional_fullscreen` with split
view (:pull:`9573`)
- macOS: Fix flickering during OS Window resize (:disc:`9582`)
0.45.0 [2025-12-24]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

View File

@@ -361,7 +361,11 @@ cocoa_out_of_sequence_render(OSWindow *window) {
}
bool rendered = false;
if (window->fonts_data->sprite_map) rendered = render_os_window(window, monotonic(), true);
if (window->fonts_data->sprite_map) {
window->needs_render = true;
window->render_state = RENDER_FRAME_READY;
rendered = render_os_window(window, monotonic(), true);
}
if (!rendered) {
debug_rendering("Cocoa out of sequence render did not happen\n");
blank_os_window(window);