Mercurial > vim
comparison src/popupwin.c @ 19457:b70fbf3f0e0b v8.2.0286
patch 8.2.0286: cannot use popup_close() for a terminal popup
Commit: https://github.com/vim/vim/commit/11ec807639ae642bf55da883918489e2cd9911ab
Author: Bram Moolenaar <Bram@vim.org>
Date: Thu Feb 20 20:12:29 2020 +0100
patch 8.2.0286: cannot use popup_close() for a terminal popup
Problem: Cannot use popup_close() for a terminal popup.
Solution: Allow using popup_close(). (closes https://github.com/vim/vim/issues/5666)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Thu, 20 Feb 2020 20:15:04 +0100 |
parents | 18fc30542bf5 |
children | 9f07a6c172f2 |
comparison
equal
deleted
inserted
replaced
19456:c35caa98fe6a | 19457:b70fbf3f0e0b |
---|---|
2358 f_popup_close(typval_T *argvars, typval_T *rettv UNUSED) | 2358 f_popup_close(typval_T *argvars, typval_T *rettv UNUSED) |
2359 { | 2359 { |
2360 int id = (int)tv_get_number(argvars); | 2360 int id = (int)tv_get_number(argvars); |
2361 win_T *wp; | 2361 win_T *wp; |
2362 | 2362 |
2363 if (ERROR_IF_ANY_POPUP_WINDOW) | 2363 if ( |
2364 # ifdef FEAT_TERMINAL | |
2365 // if the popup contains a terminal it will become hidden | |
2366 curbuf->b_term == NULL && | |
2367 # endif | |
2368 ERROR_IF_ANY_POPUP_WINDOW) | |
2364 return; | 2369 return; |
2365 | 2370 |
2366 wp = find_popup_win(id); | 2371 wp = find_popup_win(id); |
2367 if (wp != NULL) | 2372 if (wp != NULL) |
2368 popup_close_and_callback(wp, &argvars[1]); | 2373 popup_close_and_callback(wp, &argvars[1]); |