mirror of
https://github.com/neovim/neovim.git
synced 2025-10-16 23:06:14 +00:00
fix(messages): avoid empty msg_showmode with 'noshowmode'
This commit is contained in:
@@ -3183,7 +3183,11 @@ void msg_ext_flush_showmode(void)
|
||||
{
|
||||
// Showmode messages doesn't interrupt normal message flow, so we use
|
||||
// separate event. Still reuse the same chunking logic, for simplicity.
|
||||
if (ui_has(kUIMessages)) {
|
||||
// This is called unconditionally; check if we are emitting, or have
|
||||
// emitted non-empty "content".
|
||||
static bool clear = false;
|
||||
if (ui_has(kUIMessages) && (msg_ext_last_attr != -1 || clear)) {
|
||||
clear = msg_ext_last_attr != -1;
|
||||
msg_ext_emit_chunk();
|
||||
Array *tofree = msg_ext_init_chunks();
|
||||
ui_call_msg_showmode(*tofree);
|
||||
|
Reference in New Issue
Block a user