comparison src/ex_docmd.c @ 18402:527b7084c556 v8.1.2195

patch 8.1.2195: Vim does not exit when the terminal window is last window Commit: https://github.com/vim/vim/commit/4d14bac8e7441368977e81266166f728105a60d4 Author: Bram Moolenaar <Bram@vim.org> Date: Sun Oct 20 21:15:15 2019 +0200 patch 8.1.2195: Vim does not exit when the terminal window is last window Problem: Vim does not exit when closing a terminal window and it is the last window. Solution: Exit Vim if the closed terminal window is the last one. (closes #4539)
author Bram Moolenaar <Bram@vim.org>
date Sun, 20 Oct 2019 21:30:03 +0200
parents 105c6cf8b266
children fa6efc49d71f
comparison
equal deleted inserted replaced
18401:d1bb50cdb9ad 18402:527b7084c556
85 static char_u *replace_makeprg(exarg_T *eap, char_u *p, char_u **cmdlinep); 85 static char_u *replace_makeprg(exarg_T *eap, char_u *p, char_u **cmdlinep);
86 #endif 86 #endif
87 static char_u *repl_cmdline(exarg_T *eap, char_u *src, int srclen, char_u *repl, char_u **cmdlinep); 87 static char_u *repl_cmdline(exarg_T *eap, char_u *src, int srclen, char_u *repl, char_u **cmdlinep);
88 static void ex_highlight(exarg_T *eap); 88 static void ex_highlight(exarg_T *eap);
89 static void ex_colorscheme(exarg_T *eap); 89 static void ex_colorscheme(exarg_T *eap);
90 static void ex_quit(exarg_T *eap);
91 static void ex_cquit(exarg_T *eap); 90 static void ex_cquit(exarg_T *eap);
92 static void ex_quit_all(exarg_T *eap); 91 static void ex_quit_all(exarg_T *eap);
93 static void ex_close(exarg_T *eap); 92 static void ex_close(exarg_T *eap);
94 static void ex_win_close(int forceit, win_T *win, tabpage_T *tp); 93 static void ex_win_close(int forceit, win_T *win, tabpage_T *tp);
95 static void ex_only(exarg_T *eap); 94 static void ex_only(exarg_T *eap);
4840 } 4839 }
4841 4840
4842 /* 4841 /*
4843 * ":quit": quit current window, quit Vim if the last window is closed. 4842 * ":quit": quit current window, quit Vim if the last window is closed.
4844 * ":{nr}quit": quit window {nr} 4843 * ":{nr}quit": quit window {nr}
4845 */ 4844 * Also used when closing a terminal window that's the last one.
4846 static void 4845 */
4846 void
4847 ex_quit(exarg_T *eap) 4847 ex_quit(exarg_T *eap)
4848 { 4848 {
4849 win_T *wp; 4849 win_T *wp;
4850 4850
4851 #ifdef FEAT_CMDWIN 4851 #ifdef FEAT_CMDWIN