From 482da12f717040e4c07a0ffb03cc2d3fd6a4d012 Mon Sep 17 00:00:00 2001 From: ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> Date: Sat, 1 Jun 2024 16:48:27 +0200 Subject: Fix: Zero-sized borderless window causes high cpu usage on windows (#985) --- src/Fl_win32.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/Fl_win32.cxx b/src/Fl_win32.cxx index ce5cf0c72..45474fd0f 100644 --- a/src/Fl_win32.cxx +++ b/src/Fl_win32.cxx @@ -2211,7 +2211,7 @@ void Fl_WinAPI_Window_Driver::makeWindow() { if (!fl_clipboard_notify_empty() && clipboard_wnd == NULL) fl_clipboard_notify_target((HWND)x->xid); - wait_for_expose_value = 1; + wait_for_expose_value = ((wp == 0 || hp == 0) && !w->border() && !w->parent() ? 0 : 1); // issue #985 if (show_iconic()) { showit = 0; show_iconic(0); -- cgit v1.2.3