Code

Fix the view clearing to only be effective for displayed views
authorJonas Fonseca <fonseca@diku.dk>
Fri, 13 Feb 2009 13:41:40 +0000 (14:41 +0100)
committerJonas Fonseca <fonseca@diku.dk>
Fri, 13 Feb 2009 13:41:40 +0000 (14:41 +0100)
The feature was introduced in ec9aa4f62ae2977d598dda865e6a50b9fc799428.

tig.c

diff --git a/tig.c b/tig.c
index 705e3ddbe5e96b91eb16b28c5d7848f82b60bfa9..1b5f0f22513fd6bfa59a669524d9ef2129162171 100644 (file)
--- a/tig.c
+++ b/tig.c
@@ -2859,7 +2859,7 @@ update_view(struct view *view)
                return TRUE;
 
        if (!io_can_read(view->pipe)) {
-               if (view->lines == 0) {
+               if (view->lines == 0 && view_is_displayed(view)) {
                        time_t secs = time(NULL) - view->start_time;
 
                        if (secs > 1 && secs > view->update_secs) {