diff options
Diffstat (limited to 'src/app.rs')
| -rw-r--r-- | src/app.rs | 13 |
1 files changed, 6 insertions, 7 deletions
@@ -10,16 +10,15 @@ use crate::{ use ratatui::{ crossterm::event::{self, Event, KeyCode, KeyEvent, KeyEventKind, KeyModifiers}, prelude::*, - widgets::Block, }; -pub struct App<'a> { +pub struct App { exit: bool, - view: SheetView<'a>, - logview: Option<LogView<'a>>, + view: SheetView, + logview: Option<LogView>, } -impl App<'_> { +impl App { pub fn new() -> Self { let sheet_id = Register::create(200, 1000); let sheet = Register::get(sheet_id).unwrap(); @@ -81,7 +80,7 @@ impl App<'_> { match self.logview { Some(_) => self.logview = None, None => { - self.logview = Some(LogView::new().block(Block::bordered().title(" Log "))) + self.logview = Some(LogView::new()) } } } @@ -94,7 +93,7 @@ impl App<'_> { } } -impl Widget for &mut App<'_> { +impl Widget for &mut App { fn render(self, area: Rect, buf: &mut Buffer) where Self: Sized, |