Skip to content

Commit

Permalink
chore: Removed battery from the panel.
Browse files Browse the repository at this point in the history
Signed-off-by: Jan Willems <[email protected]>
  • Loading branch information
jw committed May 12, 2024
1 parent bd3d619 commit ab37f0a
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/app.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ use tokio::sync::mpsc;

use crate::{
action::Action,
components::{battery::Battery, fps::FpsCounter, process::Process, Component},
components::{fps::FpsCounter, process::Process, Component},
config::Config,
tui,
};
Expand All @@ -32,13 +32,12 @@ impl App {
pub fn new(tick_rate: f64, frame_rate: f64, debug: bool) -> Result<Self> {
let mut process = Process::new();
process.refresh();
let battery = Battery::new();

let components: Vec<Box<dyn Component>> = if debug {
let fps = FpsCounter::new();
vec![Box::new(process), Box::new(battery), Box::new(fps)]
vec![Box::new(process), Box::new(fps)]
} else {
vec![Box::new(process), Box::new(battery)]
vec![Box::new(process)]
};
let config = Config::new()?;
let mode = Mode::Process;
Expand Down

0 comments on commit ab37f0a

Please sign in to comment.