From 2c714645d358d746f3893afa020df79695e52461 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Tue, 11 Feb 2025 00:42:45 +0100 Subject: [PATCH] main: Don't set stage key focus to stage itself Moving the key focus to the stage should be done by unsetting the key focus, not by setting it to the stage itself. Part-of: --- js/ui/main.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/js/ui/main.js b/js/ui/main.js index 2705a4026..4d8079a4d 100644 --- a/js/ui/main.js +++ b/js/ui/main.js @@ -737,7 +737,8 @@ export function pushModal(actor, params = {}) { }); actionMode = newActionMode; - global.stage.set_key_focus(actor); + const newFocus = actor === global.stage ? null : actor; + global.stage.set_key_focus(newFocus); return grab; }