mirror of
https://github.com/mawww/kakoune.git
synced 2024-12-25 20:41:49 +03:00
use a DynamicSelectionList when searching as the buffer may be modified during the prompt
This commit is contained in:
parent
86f6282cbe
commit
6df60f5d2f
@ -223,7 +223,7 @@ template<SelectMode mode, bool forward>
|
||||
void search(Context& context)
|
||||
{
|
||||
const char* prompt = forward ? "search:" : "reverse search:";
|
||||
SelectionList selections = context.editor().selections();
|
||||
DynamicSelectionList selections{context.buffer(), context.editor().selections()};
|
||||
context.input_handler().prompt(prompt, get_color("Prompt"), complete_nothing,
|
||||
[selections](const String& str, PromptEvent event, Context& context) {
|
||||
try
|
||||
|
Loading…
Reference in New Issue
Block a user