Merge remote-tracking branch 'krobelus/fix-noincsearch'

This commit is contained in:
Maxime Coste 2023-11-13 22:56:06 +11:00
commit c2fb0738d3
6 changed files with 15 additions and 1 deletions

View File

@ -860,7 +860,9 @@ void regex_prompt(Context& context, String prompt, char reg, T func)
{
case PromptEvent::Abort: return;
case PromptEvent::Change:
if (incsearch and not str.empty())
if (not incsearch)
return;
if (not str.empty())
RegisterManager::instance()[reg].set(context, str.str());
break;
case PromptEvent::Validate:

View File

@ -0,0 +1 @@

View File

@ -0,0 +1,3 @@
x1
x2

View File

@ -0,0 +1 @@
x1

View File

@ -0,0 +1 @@
set-option global incsearch false

View File

@ -0,0 +1,6 @@
ui_out -ignore 4
ui_in '{ "jsonrpc": "2.0", "method": "keys", "params": [ "/x" ] }'
sleep 0.1
ui_in '{ "jsonrpc": "2.0", "method": "keys", "params": [ ".<ret>" ] }'
sleep 0.1
ui_out -ignore 1