summaryrefslogtreecommitdiff
path: root/src/app.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/app.rs')
-rw-r--r--src/app.rs8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/app.rs b/src/app.rs
index 0f740e8..b245b5b 100644
--- a/src/app.rs
+++ b/src/app.rs
@@ -1,10 +1,7 @@
use std::{io, time::Duration};
use crate::{
- config, lua,
- sheet::register::Register,
- tui,
- widgets::{logview::LogView, sheetview::SheetView},
+ config, lua, sheet::register::Register, state::GlobalState, tui, widgets::{logview::LogView, sheetview::SheetView}
};
use ratatui::{
@@ -22,7 +19,8 @@ pub struct App {
impl App {
pub fn new() -> Self {
let sheet_id = Register::create(10, 50);
- let view = SheetView::new(sheet_id);
+ GlobalState::instance_mut().sheetview.set_active_sheet(Some(sheet_id));
+ let view = SheetView::new();
Self {
exit: false,