1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2025-02-25 22:02:05 +00:00

refactor(core): remove an unused member from ErrorScreen

Also, rename `ErrorScreen::place` argument to `_bounds`,
similarly to how it's done in `model_quicksilver` and `model_bolt`.
This commit is contained in:
Roman Zeyde 2025-01-09 19:20:38 +01:00 committed by Roman Zeyde
parent 43721ab396
commit 849af38f5e

View File

@ -24,7 +24,6 @@ pub struct ErrorScreen<'a> {
title: Child<Label<'a>>,
message: Child<Label<'a>>,
footer: Child<Label<'a>>,
area: Rect,
}
impl<'a> ErrorScreen<'a> {
@ -39,7 +38,6 @@ impl<'a> ErrorScreen<'a> {
title: Child::new(title),
message: Child::new(message),
footer: Child::new(footer),
area: Rect::zero(),
}
}
}
@ -47,7 +45,7 @@ impl<'a> ErrorScreen<'a> {
impl Component for ErrorScreen<'_> {
type Msg = Never;
fn place(&mut self, bounds: Rect) -> Rect {
fn place(&mut self, _bounds: Rect) -> Rect {
self.bg.place(screen());
let title_area = Rect::new(screen().top_left(), screen().top_right() + Offset::y(11));
@ -77,7 +75,6 @@ impl Component for ErrorScreen<'_> {
);
self.footer.place(footer_area);
self.area = bounds;
screen()
}