From 8a4c9fe16faeaaffe1a534b48ceef9ef8efdd547 Mon Sep 17 00:00:00 2001 From: Bjorn Winckler Date: Sun, 29 Jan 2012 13:46:07 +0100 Subject: [PATCH] Flush while searching in included files This fixes a problem where the completion menu would not pop up immediately when hitting Ctrl-n to complete an identifier in a .pl file. --- src/search.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/search.c b/src/search.c index f04029b327..a481dc347e 100644 --- a/src/search.c +++ b/src/search.c @@ -5154,6 +5154,12 @@ find_pattern_in_path(ptr, dir, len, whole, skip_comments, goto search_line; } line_breakcheck(); +#ifdef FEAT_GUI_MACVIM + /* This loop could potentially take a long time, so make sure MacVim + * gets a chance to flush its output. */ + if (gui.in_use) + gui_macvim_flush(); +#endif #ifdef FEAT_INS_EXPAND if (action == ACTION_EXPAND) ins_compl_check_keys(30);