aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/ui.c
diff options
context:
space:
mode:
authorJosh Rahm <rahm@google.com>2022-10-11 19:00:34 +0000
committerJosh Rahm <rahm@google.com>2022-10-11 19:00:34 +0000
commitc367400b73d207833d51e09d663f969ffab37531 (patch)
treebc26006d942509a92b514107f9d8dca6d3911128 /src/nvim/ui.c
parent4066fa85abef16fa23c30e94dc4d2bfb3b9c4545 (diff)
parent760b399f6c0c6470daa0663752bd22886997f9e6 (diff)
downloadrneovim-c367400b73d207833d51e09d663f969ffab37531.tar.gz
rneovim-c367400b73d207833d51e09d663f969ffab37531.tar.bz2
rneovim-c367400b73d207833d51e09d663f969ffab37531.zip
Merge remote-tracking branch 'upstream/master' into colorcolchar
Diffstat (limited to 'src/nvim/ui.c')
-rw-r--r--src/nvim/ui.c17
1 files changed, 7 insertions, 10 deletions
diff --git a/src/nvim/ui.c b/src/nvim/ui.c
index 46f4d137c4..2c9510bf34 100644
--- a/src/nvim/ui.c
+++ b/src/nvim/ui.c
@@ -198,13 +198,16 @@ void ui_refresh(void)
ext_widgets[i] = true;
}
+ UI *compositor = uis[0];
+
bool inclusive = ui_override();
- for (size_t i = 0; i < ui_count; i++) {
+ for (size_t i = 1; i < ui_count; i++) {
UI *ui = uis[i];
width = MIN(ui->width, width);
height = MIN(ui->height, height);
for (UIExtension j = 0; (int)j < kUIExtCount; j++) {
- ext_widgets[j] &= (ui->ui_ext[j] || inclusive);
+ bool in_compositor = ui->composed && compositor->ui_ext[j];
+ ext_widgets[j] &= (ui->ui_ext[j] || in_compositor || inclusive);
}
}
@@ -507,7 +510,7 @@ void ui_flush(void)
return;
}
cmdline_ui_flush();
- win_ui_flush();
+ win_ui_flush(false);
msg_ext_ui_flush();
msg_scroll_flush();
@@ -565,7 +568,7 @@ void ui_check_mouse(void)
// - 'a' is in 'mouse' and "c" is in MOUSE_A, or
// - the current buffer is a help file and 'h' is in 'mouse' and we are in a
// normal editing mode (not at hit-return message).
- for (char_u *p = (char_u *)p_mouse; *p; p++) {
+ for (char *p = p_mouse; *p; p++) {
switch (*p) {
case 'a':
if (vim_strchr(MOUSE_A, checkfor) != NULL) {
@@ -611,12 +614,6 @@ bool ui_has(UIExtension ext)
return ui_ext[ext];
}
-/// Returns true if the UI has messages area.
-bool ui_has_messages(void)
-{
- return p_ch > 0 || ui_has(kUIMessages);
-}
-
Array ui_array(void)
{
Array all_uis = ARRAY_DICT_INIT;