From f5dab5907147dfba0f590f34447225c937855cd0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Camilla=20L=C3=B6wy?= Date: Tue, 28 Dec 2021 01:39:06 +0100 Subject: [PATCH] Wayland: Fix missing damage event on window show By definition a hidden window on Wayland does not have valid framebuffer contents. This adds a window damage (refresh) event when a window is shown, to request an initial frame for the now visible window. (cherry picked from commit 25c521cbe5acd58641740db5063d33fb51eeb882) --- README.md | 1 + src/wl_window.c | 1 + 2 files changed, 2 insertions(+) diff --git a/README.md b/README.md index 3e0fb5ad..6470cd58 100644 --- a/README.md +++ b/README.md @@ -129,6 +129,7 @@ information on what to include when reporting a bug. - [Wayland] Bugfix: Disable key repeat mechanism when window loses input focus - [Wayland] Bugfix: Window hiding and showing did not work (#1492,#1731) - [Wayland] Bugfix: A key being repeated was not released when window lost focus + - [Wayland] Bugfix: Showing a hidden window did not emit a window refresh event ## Contact diff --git a/src/wl_window.c b/src/wl_window.c index c73a2cf9..002fead9 100644 --- a/src/wl_window.c +++ b/src/wl_window.c @@ -1180,6 +1180,7 @@ void _glfwPlatformShowWindow(_GLFWwindow* window) createShellSurface(window); window->wl.visible = GLFW_TRUE; + _glfwInputWindowDamage(window); } }