aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/ui.c
diff options
context:
space:
mode:
authorLuuk van Baal <luukvbaal@gmail.com>2024-03-15 12:54:39 +0100
committerLuuk van Baal <luukvbaal@gmail.com>2024-04-20 15:44:12 +0200
commitb5a38530ba18b324c739e1d087bd78e4a0a6d4b3 (patch)
tree366a27e59f59fc1aa3dae4f62e0cee97892f965f /src/nvim/ui.c
parentf190f758ac58d9cc955368e047b070e0a2261033 (diff)
downloadrneovim-b5a38530ba18b324c739e1d087bd78e4a0a6d4b3.tar.gz
rneovim-b5a38530ba18b324c739e1d087bd78e4a0a6d4b3.tar.bz2
rneovim-b5a38530ba18b324c739e1d087bd78e4a0a6d4b3.zip
fix(ui): don't force 'cmdheight' to zero with ext_messages
Remove remaining code that prevents non-zero 'cmdheight' with ext_messages.
Diffstat (limited to 'src/nvim/ui.c')
-rw-r--r--src/nvim/ui.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/nvim/ui.c b/src/nvim/ui.c
index 98751c8952..75af543448 100644
--- a/src/nvim/ui.c
+++ b/src/nvim/ui.c
@@ -227,6 +227,11 @@ void ui_refresh(void)
if (i < kUIGlobalCount) {
ext_widgets[i] |= ui_cb_ext[i];
}
+ // Set 'cmdheight' to zero when ext_messages becomes active.
+ if (i == kUIMessages && !ui_ext[i] && ext_widgets[i]) {
+ set_option_value(kOptCmdheight, NUMBER_OPTVAL(0), 0);
+ command_height();
+ }
ui_ext[i] = ext_widgets[i];
if (i < kUIGlobalCount) {
ui_call_option_set(cstr_as_string(ui_ext_names[i]),
@@ -241,10 +246,6 @@ void ui_refresh(void)
screen_resize(width, height);
p_lz = save_p_lz;
- if (ext_widgets[kUIMessages]) {
- set_option_value(kOptCmdheight, NUMBER_OPTVAL(0), 0);
- command_height();
- }
ui_mode_info_set();
pending_mode_update = true;
ui_cursor_shape();