aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLuuk van Baal <luukvbaal@gmail.com>2024-03-25 14:40:22 +0100
committerLuuk van Baal <luukvbaal@gmail.com>2024-03-27 10:28:59 +0100
commit21360523cd3da8d203c3ad80b8ea2ad56b2d9703 (patch)
tree1c19789cd3f6e4b971b02ee521f15ac442a05221 /src
parent7dd6fd422b16e97ef5352430031baac0c5afa022 (diff)
downloadrneovim-21360523cd3da8d203c3ad80b8ea2ad56b2d9703.tar.gz
rneovim-21360523cd3da8d203c3ad80b8ea2ad56b2d9703.tar.bz2
rneovim-21360523cd3da8d203c3ad80b8ea2ad56b2d9703.zip
fix(intro): still show intro message with floating window
Stop drawing the intro only after a split is opened.
Diffstat (limited to 'src')
-rw-r--r--src/nvim/version.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/nvim/version.c b/src/nvim/version.c
index d7f94fadae..14e2491d18 100644
--- a/src/nvim/version.c
+++ b/src/nvim/version.c
@@ -34,6 +34,7 @@
#include "nvim/strings.h"
#include "nvim/ui.h"
#include "nvim/version.h"
+#include "nvim/window.h"
// for ":version", ":intro", and "nvim --version"
#ifndef NVIM_VERSION_MEDIUM
@@ -2714,9 +2715,9 @@ void list_version(void)
/// Whether it still is not too late to show an intro message
bool may_show_intro(void)
{
- return (buf_is_empty(curbuf)
- && (curbuf->b_fname == NULL)
- && (firstwin->w_next == NULL)
+ return (buf_is_empty(firstwin->w_buffer)
+ && (firstwin->w_buffer->b_fname == NULL)
+ && one_window(firstwin)
&& (vim_strchr(p_shm, SHM_INTRO) == NULL));
}