From 62cb035afe4db3dd7615032e4804759085453145 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sat, 22 Sep 2018 12:17:35 +0530 Subject: [PATCH] Remote control: Fix the ``focus_window`` command not focusing the top-level OS window of the specified kitty window Fixes #1003 --- docs/changelog.rst | 2 ++ kitty/cmds.py | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/changelog.rst b/docs/changelog.rst index af1ae0848..b4e849b52 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -64,6 +64,8 @@ Changelog mouse cursor image that can be seen on both light and dark backgrounds (:iss:`359`) +- Remote control: Fix the ``focus_window`` command not focusing the + top-level OS window of the specified kitty window (:iss:`1003`) 0.12.1 [2018-09-08] ------------------------------ diff --git a/kitty/cmds.py b/kitty/cmds.py index b7f0f23b6..60af99173 100644 --- a/kitty/cmds.py +++ b/kitty/cmds.py @@ -573,7 +573,9 @@ def focus_window(boss, window, payload): raise MatchError(match) for window in windows: if window: - boss.set_active_window(window) + os_window_id = boss.set_active_window(window) + if os_window_id: + focus_os_window(os_window_id, True) break # }}}