layout: Unbox buttons

The Box was just polluting the code, and the original reason for it (passing buttons individually to C) is gone.
This commit is contained in:
Dorota Czaplejewicz
2022-10-01 15:13:28 +00:00
parent 952ec805ed
commit a5fdc25452
3 changed files with 34 additions and 35 deletions

View File

@ -224,7 +224,7 @@ impl Layout {
let rows = view.iter().map(|row| {
let buttons = row.split_ascii_whitespace()
.map(|name| {
Box::new(create_button(
create_button(
&self.buttons,
&self.outlines,
name,
@ -232,7 +232,7 @@ impl Layout {
.expect("Button state not created")
.clone(),
&mut warning_handler,
))
)
});
layout::Row::new(
add_offsets(