mirror of
https://github.com/SpaceVim/SpaceVim.git
synced 2025-03-11 08:55:43 +08:00
feat(flygrep): add toggle_expr_mode function
This commit is contained in:
parent
231d92b229
commit
ce8608ef96
@ -357,6 +357,18 @@ local function double_click()
|
|||||||
open_item()
|
open_item()
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local function toggle_expr_mode()
|
||||||
|
if grep_mode == 'expr' then
|
||||||
|
grep_mode = 'string'
|
||||||
|
else
|
||||||
|
grep_mode = 'expr'
|
||||||
|
end
|
||||||
|
mpt._oninputpro()
|
||||||
|
mpt._handle_fly(mpt._prompt.cursor_begin
|
||||||
|
.. mpt._prompt.cursor_char
|
||||||
|
.. mpt._prompt.cursor_end)
|
||||||
|
end
|
||||||
|
|
||||||
mpt._function_key = {
|
mpt._function_key = {
|
||||||
[Key.t('<Tab>')] = next_item,
|
[Key.t('<Tab>')] = next_item,
|
||||||
[Key.t('<C-j>')] = next_item,
|
[Key.t('<C-j>')] = next_item,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user