Mercurial > vim
diff src/popupwin.c @ 19275:2142fb624658 v8.2.0196
patch 8.2.0196: blocking commands for a finished job in a popup window
Commit: https://github.com/vim/vim/commit/d98c0b63abd7b0e61a383669474abe96044615af
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Feb 2 15:25:16 2020 +0100
patch 8.2.0196: blocking commands for a finished job in a popup window
Problem: Blocking commands for a finished job in a popup window.
Solution: Do not block commands if the job has finished. Adjust test.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 02 Feb 2020 15:30:04 +0100 |
parents | ebeeb4b4a1fa |
children | 104c163131cc |
line wrap: on
line diff
--- a/src/popupwin.c +++ b/src/popupwin.c @@ -2863,10 +2863,15 @@ error_if_popup_window(int also_with_term } # if defined(FEAT_TERMINAL) || defined(PROTO) +/* + * Return TRUE if the current window is running a terminal in a popup window. + * Return FALSE when the job has ended. + */ int error_if_term_popup_window() { - if (WIN_IS_POPUP(curwin) && curbuf->b_term != NULL) + if (WIN_IS_POPUP(curwin) && curbuf->b_term != NULL + && term_job_running(curbuf->b_term)) { emsg(_("E899: Not allowed for a terminal in a popup window")); return TRUE;