Mercurial > vim
comparison src/terminal.c @ 12798:5ae0d05e046a v8.0.1276
patch 8.0.1276: key lost when window closed in exit callback
commit https://github.com/vim/vim/commit/a3f7e58bf846b28b347a5d5b96c2d829871bd212
Author: Bram Moolenaar <Bram@vim.org>
Date: Thu Nov 9 13:21:58 2017 +0100
patch 8.0.1276: key lost when window closed in exit callback
Problem: Typed key is lost when the terminal window is closed in exit
callback. (Gabriel Barta)
Solution: When the current window changes bail out of the wait loop. (closes
#2302)
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Thu, 09 Nov 2017 13:30:05 +0100 |
parents | 4d9cdb1d8bea |
children | 8dfeed7e07e7 |
comparison
equal
deleted
inserted
replaced
12797:d3c7adaf2e74 | 12798:5ae0d05e046a |
---|---|
36 * that buffer, attributes come from the scrollback buffer tl_scrollback. | 36 * that buffer, attributes come from the scrollback buffer tl_scrollback. |
37 * When the buffer is changed it is turned into a normal buffer, the attributes | 37 * When the buffer is changed it is turned into a normal buffer, the attributes |
38 * in tl_scrollback are no longer used. | 38 * in tl_scrollback are no longer used. |
39 * | 39 * |
40 * TODO: | 40 * TODO: |
41 * - Termdebug: issue #2154 might be avoided by adding -quiet to gdb? | |
42 * patch by Christian, 2017 Oct 23. | |
43 * - in GUI vertical split causes problems. Cursor is flickering. (Hirohito | 41 * - in GUI vertical split causes problems. Cursor is flickering. (Hirohito |
44 * Higashi, 2017 Sep 19) | 42 * Higashi, 2017 Sep 19) |
45 * - double click in Window toolbar starts Visual mode (but not always?). | 43 * - double click in Window toolbar starts Visual mode (but not always?). |
46 * - Shift-Tab does not work. | 44 * - Shift-Tab does not work. |
47 * - after resizing windows overlap. (Boris Staletic, #2164) | 45 * - after resizing windows overlap. (Boris Staletic, #2164) |
1579 } | 1577 } |
1580 #endif | 1578 #endif |
1581 | 1579 |
1582 c = term_vgetc(); | 1580 c = term_vgetc(); |
1583 if (!term_use_loop()) | 1581 if (!term_use_loop()) |
1582 { | |
1584 /* job finished while waiting for a character */ | 1583 /* job finished while waiting for a character */ |
1584 if (c != K_IGNORE) | |
1585 vungetc(c); | |
1585 break; | 1586 break; |
1587 } | |
1586 if (c == K_IGNORE) | 1588 if (c == K_IGNORE) |
1587 continue; | 1589 continue; |
1588 | 1590 |
1589 #ifdef WIN3264 | 1591 #ifdef WIN3264 |
1590 /* On Windows winpty handles CTRL-C, don't send a CTRL_C_EVENT. | 1592 /* On Windows winpty handles CTRL-C, don't send a CTRL_C_EVENT. |