From 2d3a0a1034c21ddc7ef7829cacb24a92d93c8560 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Sun, 24 Nov 2013 13:40:02 +0900 Subject: [PATCH] Reduce the number of Curses.refresh calls --- fzf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/fzf b/fzf index 2e53d98..684759f 100755 --- a/fzf +++ b/fzf @@ -638,7 +638,9 @@ class FZF Thread.new do begin while blk = @queue.shift - blk.call + blks = [blk] + blks << blk while blk = (@queue.shift(true) rescue nil) + blks.each { |blk| blk.call } refresh end rescue Exception => e