Mercurial > vim
comparison src/gui_photon.c @ 15665:31367ce5aac7 v8.1.0840
patch 8.1.0840: getchar(0) never returns a character in the terminal
commit https://github.com/vim/vim/commit/12dfc9eef14fe74c46145aa9e6cba9666f1bcd40
Author: Bram Moolenaar <Bram@vim.org>
Date: Mon Jan 28 22:32:58 2019 +0100
patch 8.1.0840: getchar(0) never returns a character in the terminal
Problem: getchar(0) never returns a character in the terminal.
Solution: Call wait_func() at least once.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Mon, 28 Jan 2019 22:45:05 +0100 |
parents | 1ec942f1b648 |
children | cd5c83115ec6 |
comparison
equal
deleted
inserted
replaced
15664:128d7a4ccd54 | 15665:31367ce5aac7 |
---|---|
1342 int | 1342 int |
1343 gui_mch_wait_for_chars(int wtime) | 1343 gui_mch_wait_for_chars(int wtime) |
1344 { | 1344 { |
1345 is_timeout = FALSE; | 1345 is_timeout = FALSE; |
1346 | 1346 |
1347 if (wtime > 0) | 1347 if (wtime >= 0) |
1348 PtSetResource(gui_ph_timer_timeout, Pt_ARG_TIMER_INITIAL, wtime, 0); | 1348 PtSetResource(gui_ph_timer_timeout, Pt_ARG_TIMER_INITIAL, |
1349 wtime == 0 ? 1 : wtime, 0); | |
1349 | 1350 |
1350 while (1) | 1351 while (1) |
1351 { | 1352 { |
1352 PtProcessEvent(); | 1353 PtProcessEvent(); |
1353 if (input_available()) | 1354 if (input_available()) |