From fed8f10652b640e9619b5fe3e591a160125f5d2d Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Sat, 2 Sep 2023 19:01:36 +0200 Subject: rc: only jump to new clients if they spawn on the focused page --- rc.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rc.lua b/rc.lua index 53f4987..5a096e5 100644 --- a/rc.lua +++ b/rc.lua @@ -199,8 +199,8 @@ client.connect_signal("manage", function (c, startup) -- put new clients at the end awful.client.setslave(c) - -- give the new client focus - if c.focusable then + -- give the new client focus if it spawns on the focused page + if c.focusable and c.first_tag == mouse.screen.selected_tag then -- use pcall() because the client might be gone by the time we get to it gears.timer.delayed_call(pcall, function() c:jump_to(false) end) end -- cgit v1.2.3