diff options
author | rabite <rabite@posteo.de> | 2019-05-23 19:49:01 +0200 |
---|---|---|
committer | rabite <rabite@posteo.de> | 2019-05-23 19:49:01 +0200 |
commit | cdaacd1ca6300a037140c01cce1d788bebf9baee (patch) | |
tree | e6268833bf817018e6401dd251ea82d011ec7f7d /src/preview.rs | |
parent | 6d43ce621de7ea82eadaf2806fbab3836bdade7e (diff) |
move methods from Widget trait to WidgetCore
Diffstat (limited to 'src/preview.rs')
-rw-r--r-- | src/preview.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/preview.rs b/src/preview.rs index a3c3a5f..1dbe511 100644 --- a/src/preview.rs +++ b/src/preview.rs @@ -166,14 +166,14 @@ impl<T: Widget + Send + 'static> Widget for AsyncWidget<T> { } fn get_drawlist(&self) -> HResult<String> { if self.widget().is_err() { - let clear = self.get_clearlist()?; + let clear = self.core.get_clearlist()?; let (xpos, ypos) = self.get_coordinates()?.u16position(); let pos = crate::term::goto_xy(xpos, ypos); return Ok(clear + &pos + "...") } if self.is_stale()? { - return self.get_clearlist() + return self.core.get_clearlist() } self.widget()?.get_drawlist() @@ -517,7 +517,7 @@ impl Widget for Previewer { } fn config_loaded(&mut self) -> HResult<()> { - let show_hidden = self.config().show_hidden(); + let show_hidden = self.core.config().show_hidden(); if let PreviewWidget::FileList(filelist) = self.widget.widget_mut()? { filelist.content.show_hidden = show_hidden; filelist.content.dirty_meta.set_dirty(); |