[Bf-blender-cvs] [7a849678c93] master: Fix GHOST/Wayland setting the window size
Campbell Barton
noreply at git.blender.org
Sun Jun 12 09:49:44 CEST 2022
Commit: 7a849678c93ec907fc98b0d30c0c9fd0664ca04c
Author: Campbell Barton
Date: Sun Jun 12 17:44:15 2022 +1000
Branches: master
https://developer.blender.org/rB7a849678c93ec907fc98b0d30c0c9fd0664ca04c
Fix GHOST/Wayland setting the window size
Zoom in the animation player wasn't working:
- The internal window size value wasn't being updated.
- The window size event wasn't being sent.
===================================================================
M intern/ghost/intern/GHOST_WindowWayland.cpp
===================================================================
diff --git a/intern/ghost/intern/GHOST_WindowWayland.cpp b/intern/ghost/intern/GHOST_WindowWayland.cpp
index 051c826055d..685fcedd649 100644
--- a/intern/ghost/intern/GHOST_WindowWayland.cpp
+++ b/intern/ghost/intern/GHOST_WindowWayland.cpp
@@ -437,6 +437,16 @@ GHOST_TSuccess GHOST_WindowWayland::setClientHeight(uint32_t height)
GHOST_TSuccess GHOST_WindowWayland::setClientSize(uint32_t width, uint32_t height)
{
wl_egl_window_resize(w->egl_window, int(width), int(height), 0, 0);
+
+ /* Override any pending size that may be set. */
+ w->size_pending[0] = 0;
+ w->size_pending[1] = 0;
+
+ w->size[0] = width;
+ w->size[1] = height;
+
+ notify_size();
+
return GHOST_kSuccess;
}
More information about the Bf-blender-cvs
mailing list