From 47095f97d2d30ea95cb75b3d3e304352217f221b Mon Sep 17 00:00:00 2001 From: Alexander Larsson Date: Thu, 27 Oct 2011 16:56:40 +0200 Subject: [PATCH] win32: Make flush/sync work like in X gdk_flush() should gdk_display_sync() on all open displays. Both for display_flush and display_sync it seems useful to call GdiFlush, but we don't have anything extra to do for display_sync, as there is no inherent roundtrip on win32. This should close bug #84314 --- gdk/win32/gdkevents-win32.c | 19 +++---------------- 1 file changed, 3 insertions(+), 16 deletions(-) diff --git a/gdk/win32/gdkevents-win32.c b/gdk/win32/gdkevents-win32.c index e7caf9c5d9..99441e5c83 100644 --- a/gdk/win32/gdkevents-win32.c +++ b/gdk/win32/gdkevents-win32.c @@ -3652,18 +3652,7 @@ gdk_screen_broadcast_client_message (GdkScreen *screen, void gdk_flush (void) { -#if 0 - MSG msg; - - /* Process all messages currently available */ - while (PeekMessageW (&msg, NULL, 0, 0, PM_REMOVE)) - { - TranslateMessage (&msg); - DispatchMessageW (&msg); - } -#endif - - GdiFlush (); + gdk_display_sync (_gdk_display); } void @@ -3673,9 +3662,7 @@ gdk_display_sync (GdkDisplay * display) g_return_if_fail (display == _gdk_display); - /* Process all messages currently available */ - while (PeekMessageW (&msg, NULL, 0, 0, PM_REMOVE)) - DispatchMessageW (&msg); + GdiFlush (); } void @@ -3683,7 +3670,7 @@ gdk_display_flush (GdkDisplay * display) { g_return_if_fail (display == _gdk_display); - /* Nothing */ + GdiFlush (); } gboolean