Only hide menu/info if the insert completer did display it

Avoid hiding info boxes opened by other places in the code.
This commit is contained in:
Maxime Coste 2016-12-04 13:37:33 +00:00
parent e2fae522e5
commit 4d538fb423

View File

@ -418,8 +418,10 @@ void InsertCompleter::update()
void InsertCompleter::reset() void InsertCompleter::reset()
{ {
m_completions = InsertCompletion{};
m_explicit_completer = nullptr; m_explicit_completer = nullptr;
if (m_completions.is_valid())
{
m_completions = InsertCompletion{};
if (m_context.has_client()) if (m_context.has_client())
{ {
m_context.client().menu_hide(); m_context.client().menu_hide();
@ -427,6 +429,7 @@ void InsertCompleter::reset()
m_context.hooks().run_hook("InsertCompletionHide", "", m_context); m_context.hooks().run_hook("InsertCompletionHide", "", m_context);
} }
} }
}
bool InsertCompleter::setup_ifn() bool InsertCompleter::setup_ifn()
{ {