From: Jonas Fonseca Date: Wed, 21 Jan 2009 15:27:15 +0000 (+0100) Subject: Do not terminate the update when switching back to a loading view X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=49dc4030694e22b7f141bfb13565783985c48b77;p=tig.git Do not terminate the update when switching back to a loading view Move call to end_update() to begin_update() so checks for view content is honored in the case where no reloading is necessary. --- diff --git a/tig.c b/tig.c index f34334c..79b23e0 100644 --- a/tig.c +++ b/tig.c @@ -2622,6 +2622,9 @@ prepare_update_file(struct view *view, const char *name) static bool begin_update(struct view *view, bool refresh) { + if (view->pipe) + end_update(view, TRUE); + if (refresh) { if (!start_io(&view->io)) return FALSE; @@ -2855,9 +2858,6 @@ open_view(struct view *prev, enum request request, enum open_flags flags) (nviews == 1 && base_view != display[0])) resize_display(); - if (view->pipe) - end_update(view, TRUE); - if (view->ops->open) { if (!view->ops->open(view)) { report("Failed to load %s view", view->name);