Honor 'hidden' setting when deciding whether to split window
This commit is contained in:
parent
787cef2a1d
commit
b0780ddc91
@ -207,7 +207,7 @@ function M.open_file(mode, filename)
|
||||
|
||||
if not found and (mode == 'edit' or mode == 'preview') then
|
||||
if target_bufnr then
|
||||
if api.nvim_buf_get_option(target_bufnr, 'modified') then
|
||||
if not vim.o.hidden and api.nvim_buf_get_option(target_bufnr, 'modified') then
|
||||
ecmd = string.format('%dwindo %s', target_winnr, splitcmd)
|
||||
end
|
||||
else
|
||||
|
||||
Loading…
Reference in New Issue
Block a user