From c4a269b32a4347f8d000cb52583273cf34b600d8 Mon Sep 17 00:00:00 2001 From: BearOso Date: Wed, 4 Nov 2020 12:03:28 -0600 Subject: [PATCH] Gtk: OpenGL: Try to ensure window is mapped. --- gtk/src/gtk_display_driver_opengl.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gtk/src/gtk_display_driver_opengl.cpp b/gtk/src/gtk_display_driver_opengl.cpp index ec48e159..245cdfef 100644 --- a/gtk/src/gtk_display_driver_opengl.cpp +++ b/gtk/src/gtk_display_driver_opengl.cpp @@ -479,6 +479,8 @@ bool S9xOpenGLDisplayDriver::create_context() #ifdef GDK_WINDOWING_X11 if (GDK_IS_X11_WINDOW(gdk_window)) { + gdk_window_ensure_native(gdk_window); + gdk_display_sync(gdk_display); if (!glx.attach(gdk_x11_display_get_xdisplay(gdk_display), gdk_x11_window_get_xid(gdk_window))) return false; context = &glx;