diff options
| author | Maxime Coste <mawww@kakoune.org> | 2019-04-16 15:55:51 +0200 |
|---|---|---|
| committer | Maxime Coste <mawww@kakoune.org> | 2019-04-16 15:56:07 +0200 |
| commit | ace499ecb1027ad24db32a76e53066e26d2c1cf6 (patch) | |
| tree | 5b8e14f32f7711225a4d6375d155cee20b6f6baf /src/insert_completer.cc | |
| parent | 0bff4851d97436e4990df07dab15f510c256a677 (diff) | |
Pass selected completion text to InsertCompletionHide
Diffstat (limited to 'src/insert_completer.cc')
| -rw-r--r-- | src/insert_completer.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/insert_completer.cc b/src/insert_completer.cc index 69641085..2c8479a6 100644 --- a/src/insert_completer.cc +++ b/src/insert_completer.cc @@ -473,13 +473,14 @@ void InsertCompleter::reset() { if (m_explicit_completer or m_completions.is_valid()) { + String selected_item = std::move(m_completions.candidates[m_current_candidate].completion); m_explicit_completer = nullptr; m_completions = InsertCompletion{}; if (m_context.has_client()) { m_context.client().menu_hide(); m_context.client().info_hide(); - m_context.hooks().run_hook(Hook::InsertCompletionHide, "", m_context); + m_context.hooks().run_hook(Hook::InsertCompletionHide, selected_item, m_context); } } } |
