[gtk/wip.win32.fixes: 16/17] gdksurface-win32.c: Call gdk_surface_set_egl_native_window()
- From: Chun-wei Fan <fanchunwei src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip.win32.fixes: 16/17] gdksurface-win32.c: Call gdk_surface_set_egl_native_window()
- Date: Fri, 3 Dec 2021 02:42:27 +0000 (UTC)
commit 8ee141470612c4a4a8fd2242624df2c8b7a0e452
Author: Chun-wei Fan <fanchunwei src gnome org>
Date: Tue Nov 23 16:19:34 2021 +0800
gdksurface-win32.c: Call gdk_surface_set_egl_native_window()
.. when creating the surface (with the HWND associated with the
newly-created surface) as well as destroying the surface (with NULL,
since the HWND is going to be destroyed), so that we can tie the EGL
calls to the HWND that we want to do the EGL stuff.
gdk/win32/gdksurface-win32.c | 2 ++
1 file changed, 2 insertions(+)
---
diff --git a/gdk/win32/gdksurface-win32.c b/gdk/win32/gdksurface-win32.c
index 88931992b3..0c723067ad 100644
--- a/gdk/win32/gdksurface-win32.c
+++ b/gdk/win32/gdksurface-win32.c
@@ -638,6 +638,7 @@ _gdk_win32_display_create_surface (GdkDisplay *display,
return NULL;
}
+ gdk_surface_set_egl_native_window (surface, (void *) impl->handle);
if (display_win32->tablet_input_api == GDK_WIN32_TABLET_INPUT_API_WINPOINTER)
gdk_winpointer_initialize_surface (surface);
@@ -694,6 +695,7 @@ gdk_win32_surface_destroy (GdkSurface *window,
if (!foreign_destroy)
{
+ gdk_surface_set_egl_native_window (window, NULL);
window->destroyed = TRUE;
DestroyWindow (GDK_SURFACE_HWND (window));
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]