summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMartin Rudalics <rudalics@gmx.at>2007-10-06 09:43:17 +0000
committerMartin Rudalics <rudalics@gmx.at>2007-10-06 09:43:17 +0000
commit15d814840f6ce72ddb14824f06ad474e8696dbc4 (patch)
tree5537c0a130b2cb1dfbb43a45a44f355f1b270dbb /src
parentf5578c7f65a267072b3c1599efc7696b0080fd89 (diff)
downloademacs-15d814840f6ce72ddb14824f06ad474e8696dbc4.tar.gz
(kbd_buffer_get_event): Break loop waiting for input
when there's an unread command event.
Diffstat (limited to 'src')
-rw-r--r--src/keyboard.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/keyboard.c b/src/keyboard.c
index c398a85684d..538c0a0d1b0 100644
--- a/src/keyboard.c
+++ b/src/keyboard.c
@@ -3995,6 +3995,12 @@ kbd_buffer_get_event (kbp, used_mouse_menu, end_time)
/* Wait until there is input available. */
for (;;)
{
+ /* Break loop if there's an unread command event. Needed in
+ moused window autoselection which uses a timer to insert such
+ events. */
+ if (CONSP (Vunread_command_events))
+ break;
+
if (kbd_fetch_ptr != kbd_store_ptr)
break;
#ifdef HAVE_MOUSE