mirror of
https://github.com/mawww/kakoune.git
synced 2024-11-28 09:07:19 +03:00
use plain SelectionList for regex_prompt
This commit is contained in:
parent
11d9b60766
commit
fbf7856e3e
@ -599,13 +599,14 @@ void paste(Context& context, int)
|
||||
template<typename T>
|
||||
void regex_prompt(Context& context, const String prompt, T func)
|
||||
{
|
||||
DynamicSelectionList selections{context.selections()};
|
||||
SelectionList selections = context.selections();
|
||||
context.input_handler().prompt(prompt, "", get_color("Prompt"), complete_nothing,
|
||||
[=](const String& str, PromptEvent event, Context& context) {
|
||||
[=](const String& str, PromptEvent event, Context& context) mutable {
|
||||
try
|
||||
{
|
||||
if (event != PromptEvent::Change and context.has_ui())
|
||||
context.ui().info_hide();
|
||||
selections.update();
|
||||
context.selections() = selections;
|
||||
context.input_handler().set_prompt_colors(get_color("Prompt"));
|
||||
if (event == PromptEvent::Abort)
|
||||
|
Loading…
Reference in New Issue
Block a user