summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2020-12-02 18:14:13 +0100
committerAnton Khirnov <anton@khirnov.net>2020-12-02 18:14:13 +0100
commita18b660c007ee8d278554df64f07d4d653516a86 (patch)
tree68cfe9fd8f1b67afb177ab8dbcf7fcb6a3b99e35
parentca2f901197dd36520cc6de31aa1d4277caf72d6d (diff)
bindings: switch focus to target after swapping screens
-rw-r--r--bindings.lua4
1 files changed, 4 insertions, 0 deletions
diff --git a/bindings.lua b/bindings.lua
index 1e6e03c..75a2f8e 100644
--- a/bindings.lua
+++ b/bindings.lua
@@ -2,6 +2,7 @@ local M = {}
local awful = require("awful")
local gears = require("gears")
+local timer = require("gears.timer")
local commondefs = require("commondefs")
local utils = require("utils")
@@ -114,6 +115,7 @@ function M.create(workspace)
local page_idx = workspace.screen_state[screen_src].page_idx
workspace:view(screen_dst, desk_idx, page_idx)
end
+ timer.delayed_call(awful.screen.focus, screen_src)
end),
awful.key({ modkey, "Mod1" }, "w",
function ()
@@ -124,6 +126,7 @@ function M.create(workspace)
local page_idx = workspace.screen_state[screen_src].page_idx
workspace:view(screen_dst, desk_idx, page_idx)
end
+ timer.delayed_call(awful.screen.focus, screen_src)
end),
awful.key({ modkey, "Mod1" }, "e",
function ()
@@ -134,6 +137,7 @@ function M.create(workspace)
local page_idx = workspace.screen_state[screen_src].page_idx
workspace:view(screen_dst, desk_idx, page_idx)
end
+ timer.delayed_call(awful.screen.focus, screen_src)
end),
-- Prompt