0
0
mirror of https://github.com/vim/vim.git synced 2025-09-25 03:54:15 -04:00

updated for version 7.1-095

This commit is contained in:
Bram Moolenaar
2007-09-05 19:47:23 +00:00
parent 102e3a6164
commit 9c8791fde0
6 changed files with 54 additions and 15 deletions

View File

@@ -4519,7 +4519,18 @@ gui_focus_change(in_focus)
xim_set_focus(in_focus);
# endif
ui_focus_change(in_focus);
/* Put events in the input queue only when allowed.
* ui_focus_change() isn't called directly, because it invokes
* autocommands and that must not happen asynchronously. */
if (!hold_gui_events)
{
char_u bytes[3];
bytes[0] = CSI;
bytes[1] = KS_EXTRA;
bytes[2] = in_focus ? (int)KE_FOCUSGAINED : (int)KE_FOCUSLOST;
add_to_input_buf(bytes, 3);
}
#endif
}