mirror of
https://github.com/neovim/neovim.git
synced 2025-09-06 03:18:16 +00:00
vim-patch:8.2.2898: QuitPre and ExitPre not triggered when GUI window is closed
Problem: QuitPre and ExitPre not triggered when GUI window is closed.
Solution: Call before_quit_autocmds(). (closes vim/vim#8242)
3552e74289
This commit is contained in:
@@ -6340,7 +6340,7 @@ void not_exiting(void)
|
|||||||
exiting = false;
|
exiting = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool before_quit_autocmds(win_T *wp, bool quit_all, int forceit)
|
bool before_quit_autocmds(win_T *wp, bool quit_all, int forceit)
|
||||||
{
|
{
|
||||||
apply_autocmds(EVENT_QUITPRE, NULL, NULL, false, wp->w_buffer);
|
apply_autocmds(EVENT_QUITPRE, NULL, NULL, false, wp->w_buffer);
|
||||||
|
|
||||||
@@ -6406,7 +6406,7 @@ static void ex_quit(exarg_T *eap)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// If there are more files or windows we won't exit.
|
// If there is only one relevant window we will exit.
|
||||||
if (check_more(false, eap->forceit) == OK && only_one_window()) {
|
if (check_more(false, eap->forceit) == OK && only_one_window()) {
|
||||||
exiting = true;
|
exiting = true;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user