From f4e5ce0899c379ebebb31897b756f8eb4fa59652 Mon Sep 17 00:00:00 2001 From: hut Date: Tue, 19 Feb 2013 06:53:46 +0100 Subject: widgets.browserview: clear image when (un)collapsing preview --- ranger/gui/widgets/browserview.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ranger/gui/widgets/browserview.py b/ranger/gui/widgets/browserview.py index 742bd9d4..1c6fc802 100644 --- a/ranger/gui/widgets/browserview.py +++ b/ranger/gui/widgets/browserview.py @@ -341,4 +341,9 @@ class BrowserView(Widget, DisplayableContainer): self.columns[-1].visible = True if self.preview and self.is_collapsed != self._collapse(): + if (self.fm.settings.preview_images and + self.fm.settings.preview_files): + pager = self.columns[-1] + pager.need_clear_image = True + pager.clear_image() self.resize(self.y, self.x, self.hei, self.wid) -- cgit 1.4.1-2-gfad0