add close binding
This commit is contained in:
parent
787cef2a1d
commit
01ae59823c
@ -71,6 +71,7 @@ function M.get_bindings()
|
||||
prev_git_item = keybindings.prev_git_item or '[c',
|
||||
next_git_item = keybindings.next_git_item or ']c',
|
||||
dir_up = keybindings.dir_up or '-',
|
||||
close = keybindings.close or 'q',
|
||||
}
|
||||
end
|
||||
|
||||
|
||||
@ -284,6 +284,7 @@ local function set_mappings()
|
||||
[bindings.prev_git_item] = 'on_keypress("prev_git_item")';
|
||||
[bindings.next_git_item] = 'on_keypress("next_git_item")';
|
||||
[bindings.dir_up] = 'on_keypress("dir_up")';
|
||||
[bindings.close] = 'on_keypress("close")';
|
||||
gx = "xdg_open()";
|
||||
}
|
||||
|
||||
|
||||
@ -76,6 +76,7 @@ local keypress_funcs = {
|
||||
prev_git_item = gen_go_to('prev_git_item'),
|
||||
next_git_item = gen_go_to('next_git_item'),
|
||||
dir_up = lib.dir_up,
|
||||
close = function(node) M.close() end,
|
||||
preview = function(node)
|
||||
if node.entries ~= nil or node.name == '..' then return end
|
||||
return lib.open_file('preview', node.absolute_path)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user