mirror of
https://github.com/glfw/glfw.git
synced 2026-09-19 15:25:50 +00:00
Wayland: Fix undecorated libdecor frame creation
In order to safely call libdecor_frame_set_visibility during window creation, a libdecor frame state was synthesized and committed. This commit instead postpones the call to libdecor_frame_set_visibility until after the frame state received by the frame configure event has been committed. This appears to be a more polite approach. Related to #2842
This commit is contained in:
@@ -798,6 +798,8 @@ int _glfwInitWayland(void)
|
||||
_glfwPlatformGetModuleSymbol(_glfw.wl.libdecor.handle, "libdecor_frame_unset_capabilities");
|
||||
_glfw.wl.libdecor.libdecor_frame_set_visibility_ = (PFN_libdecor_frame_set_visibility)
|
||||
_glfwPlatformGetModuleSymbol(_glfw.wl.libdecor.handle, "libdecor_frame_set_visibility");
|
||||
_glfw.wl.libdecor.libdecor_frame_is_visible_ = (PFN_libdecor_frame_is_visible)
|
||||
_glfwPlatformGetModuleSymbol(_glfw.wl.libdecor.handle, "libdecor_frame_is_visible");
|
||||
_glfw.wl.libdecor.libdecor_frame_get_xdg_toplevel_ = (PFN_libdecor_frame_get_xdg_toplevel)
|
||||
_glfwPlatformGetModuleSymbol(_glfw.wl.libdecor.handle, "libdecor_frame_get_xdg_toplevel");
|
||||
_glfw.wl.libdecor.libdecor_configuration_get_content_size_ = (PFN_libdecor_configuration_get_content_size)
|
||||
@@ -829,6 +831,7 @@ int _glfwInitWayland(void)
|
||||
!_glfw.wl.libdecor.libdecor_frame_set_capabilities_ ||
|
||||
!_glfw.wl.libdecor.libdecor_frame_unset_capabilities_ ||
|
||||
!_glfw.wl.libdecor.libdecor_frame_set_visibility_ ||
|
||||
!_glfw.wl.libdecor.libdecor_frame_is_visible_ ||
|
||||
!_glfw.wl.libdecor.libdecor_frame_get_xdg_toplevel_ ||
|
||||
!_glfw.wl.libdecor.libdecor_configuration_get_content_size_ ||
|
||||
!_glfw.wl.libdecor.libdecor_configuration_get_window_state_ ||
|
||||
|
||||
Reference in New Issue
Block a user