From 368a59e6f9733f19d205fa58bd0e47dde88b3266 Mon Sep 17 00:00:00 2001 From: Riteo Siuga Date: Mon, 20 Jan 2025 01:38:25 +0100 Subject: [PATCH] Wayland: Release pressed events on application focus out Looks like I always assumed wrongly that the compositor would send us key release events when unfocusing... It did not. --- platform/linuxbsd/wayland/display_server_wayland.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/platform/linuxbsd/wayland/display_server_wayland.cpp b/platform/linuxbsd/wayland/display_server_wayland.cpp index cd46508bf44..532eaa6bcf4 100644 --- a/platform/linuxbsd/wayland/display_server_wayland.cpp +++ b/platform/linuxbsd/wayland/display_server_wayland.cpp @@ -1174,6 +1174,7 @@ void DisplayServerWayland::process_events() { if (OS::get_singleton()->get_main_loop()) { OS::get_singleton()->get_main_loop()->notification(MainLoop::NOTIFICATION_APPLICATION_FOCUS_OUT); } + Input::get_singleton()->release_pressed_events(); } }