Add unformated memory total to example
This commit is contained in:
parent
53538b65b1
commit
d9853165e7
1 changed files with 7 additions and 1 deletions
|
|
@ -91,9 +91,15 @@ impl Application for Example {
|
||||||
.to_string())
|
.to_string())
|
||||||
));
|
));
|
||||||
|
|
||||||
|
let memory_readable =
|
||||||
|
ByteSize::kb(information.memory_total).to_string();
|
||||||
|
|
||||||
let memory_total = Text::new(format!(
|
let memory_total = Text::new(format!(
|
||||||
"Memory (total): {}",
|
"Memory (total): {}",
|
||||||
ByteSize::kb(information.memory_total).to_string()
|
format!(
|
||||||
|
"{} kb ({})",
|
||||||
|
information.memory_total, memory_readable
|
||||||
|
)
|
||||||
));
|
));
|
||||||
|
|
||||||
Column::with_children(vec![
|
Column::with_children(vec![
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue