diff options
author | Björn Linse <bjorn.linse@gmail.com> | 2017-04-26 15:28:10 +0200 |
---|---|---|
committer | Björn Linse <bjorn.linse@gmail.com> | 2019-03-02 16:29:50 +0100 |
commit | 9a1675b065394734ddaef91a314896028e2b1d46 (patch) | |
tree | a8e869da9a89592dd69a806c19dbeacef84f9bf4 /src/nvim/buffer.c | |
parent | 018e0d5a19c3f710f41a78bcbb0c6e3e393a5ed8 (diff) | |
download | rneovim-9a1675b065394734ddaef91a314896028e2b1d46.tar.gz rneovim-9a1675b065394734ddaef91a314896028e2b1d46.tar.bz2 rneovim-9a1675b065394734ddaef91a314896028e2b1d46.zip |
floats: implement floating windows
Co-Author: Dongdong Zhou <dzhou121@gmail.com>
Diffstat (limited to 'src/nvim/buffer.c')
-rw-r--r-- | src/nvim/buffer.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/nvim/buffer.c b/src/nvim/buffer.c index 6ae239c9c3..6e4e7afeb2 100644 --- a/src/nvim/buffer.c +++ b/src/nvim/buffer.c @@ -474,8 +474,8 @@ void close_buffer(win_T *win, buf_T *buf, int action, int abort_if_last) return; } buf->b_locked--; - if (abort_if_last && one_window()) { - /* Autocommands made this the only window. */ + if (abort_if_last && last_nonfloat(win)) { + // Autocommands made this the only window. EMSG(_(e_auabort)); return; } @@ -491,8 +491,8 @@ void close_buffer(win_T *win, buf_T *buf, int action, int abort_if_last) return; } buf->b_locked--; - if (abort_if_last && one_window()) { - /* Autocommands made this the only window. */ + if (abort_if_last && last_nonfloat(win)) { + // Autocommands made this the only window. EMSG(_(e_auabort)); return; } |