clippy clean ups
This commit is contained in:
parent
1e248306a6
commit
8d81ee1f7e
@ -138,7 +138,7 @@ impl App {
|
||||
.as_ref()
|
||||
.map(|mm| mm.cpu_per_core.len())
|
||||
.unwrap_or(0);
|
||||
per_core_clamp(
|
||||
per_core_clamp(
|
||||
&mut self.per_core_scroll,
|
||||
total_rows,
|
||||
content.height as usize,
|
||||
|
||||
@ -322,12 +322,12 @@ pub fn draw_per_core_bars(
|
||||
.unwrap_or(curr);
|
||||
|
||||
let trend = if curr > older + 0.2 {
|
||||
"↑"
|
||||
"↑"
|
||||
} else if curr + 0.2 < older {
|
||||
"↓"
|
||||
} else {
|
||||
"╌"
|
||||
};
|
||||
};
|
||||
|
||||
let fg = match curr {
|
||||
x if x < 25.0 => Color::Green,
|
||||
|
||||
@ -21,8 +21,8 @@ fn fmt_bytes(b: u64) -> String {
|
||||
format!("{:.1}K", fb / KB)
|
||||
} else {
|
||||
format!("{b}B")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
pub fn draw_gpu(f: &mut ratatui::Frame<'_>, area: Rect, m: Option<&Metrics>) {
|
||||
let mut area = area;
|
||||
|
||||
@ -30,7 +30,6 @@ pub struct AppState {
|
||||
}
|
||||
|
||||
impl AppState {
|
||||
|
||||
#[allow(dead_code)]
|
||||
pub fn new() -> Self {
|
||||
let sys = System::new(); // targeted refreshes per tick
|
||||
|
||||
Loading…
Reference in New Issue
Block a user