mirror of
https://github.com/vim/vim.git
synced 2025-09-24 03:44:06 -04:00
patch 8.1.0069: cannot handle pressing CTRL-C in a prompt buffer
Problem: Cannot handle pressing CTRL-C in a prompt buffer. Solution: Add prompt_setinterrupt().
This commit is contained in:
13
src/edit.c
13
src/edit.c
@@ -1016,6 +1016,19 @@ edit(
|
||||
goto doESCkey;
|
||||
}
|
||||
#endif
|
||||
#ifdef FEAT_JOB_CHANNEL
|
||||
if (c == Ctrl_C && bt_prompt(curbuf))
|
||||
{
|
||||
if (invoke_prompt_interrupt())
|
||||
{
|
||||
if (!bt_prompt(curbuf))
|
||||
// buffer changed to a non-prompt buffer, get out of
|
||||
// Insert mode
|
||||
goto doESCkey;
|
||||
break;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef UNIX
|
||||
do_intr:
|
||||
|
Reference in New Issue
Block a user