aboutsummaryrefslogtreecommitdiff
path: root/init.lua
diff options
context:
space:
mode:
Diffstat (limited to 'init.lua')
-rw-r--r--init.lua5
1 files changed, 5 insertions, 0 deletions
diff --git a/init.lua b/init.lua
index de496d7..6a391b6 100644
--- a/init.lua
+++ b/init.lua
@@ -512,6 +512,8 @@ local function vis_apply_textEdits(win, file, textEdits)
end
local function lspc_show_message(msg, hdr, syntax)
+ local current_win = vis.win
+
if lspc.show_message == 'message' then
vis:message((hdr or '') .. msg)
@@ -526,6 +528,9 @@ local function lspc_show_message(msg, hdr, syntax)
else
lspc_err('invalid message configuration "' .. lspc.show_message .. '".')
end
+
+ -- reset the focus to the current window
+ vis.win = current_win
end
-- apply a WorkspaceEdit received from the language server