parent
395d7cbb69
commit
ec55986f3e
|
@ -189,10 +189,13 @@ end
|
||||||
|
|
||||||
local function exec_autocommands()
|
local function exec_autocommands()
|
||||||
_G.set_lualine_theme = set_lualine_theme
|
_G.set_lualine_theme = set_lualine_theme
|
||||||
|
_G.lualine_statusline = status_dispatch
|
||||||
vim.api.nvim_exec([[
|
vim.api.nvim_exec([[
|
||||||
augroup lualine
|
augroup lualine
|
||||||
autocmd!
|
autocmd!
|
||||||
autocmd ColorScheme * call v:lua.set_lualine_theme()
|
autocmd ColorScheme * call v:lua.set_lualine_theme()
|
||||||
|
autocmd WinLeave,BufLeave * lua vim.wo.statusline=lualine_statusline()
|
||||||
|
autocmd WinEnter,BufEnter * setlocal statusline=%!v:lua.lualine_statusline()
|
||||||
augroup END
|
augroup END
|
||||||
]], false)
|
]], false)
|
||||||
end
|
end
|
||||||
|
@ -202,8 +205,6 @@ function M.status()
|
||||||
exec_autocommands()
|
exec_autocommands()
|
||||||
load_components()
|
load_components()
|
||||||
load_extensions()
|
load_extensions()
|
||||||
_G.lualine_statusline = status_dispatch
|
|
||||||
vim.o.statusline = '%!v:lua.lualine_statusline()'
|
|
||||||
end
|
end
|
||||||
|
|
||||||
return M
|
return M
|
||||||
|
|
Loading…
Reference in New Issue