1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2025-08-05 13:26:57 +00:00

refactor(core): render full/empty logo same way as in TR

This commit is contained in:
matejcik 2023-08-18 12:53:08 +02:00 committed by matejcik
parent 5947f8a50d
commit ae7a1c7d52

View File

@ -40,21 +40,17 @@ impl Component for WelcomeScreen {
} }
fn paint(&mut self) { fn paint(&mut self) {
if self.empty_lock { let logo = if self.empty_lock {
theme::ICON_LOGO_EMPTY.draw( theme::ICON_LOGO_EMPTY
self.area.top_center() + Offset::y(ICON_TOP_MARGIN),
Alignment2D::TOP_CENTER,
theme::FG,
theme::BG,
);
} else { } else {
theme::ICON_LOGO.draw( theme::ICON_LOGO
self.area.top_center() + Offset::y(ICON_TOP_MARGIN), };
Alignment2D::TOP_CENTER, logo.draw(
theme::FG, self.area.top_center() + Offset::y(ICON_TOP_MARGIN),
theme::BG, Alignment2D::TOP_CENTER,
); theme::FG,
} theme::BG,
);
#[cfg(not(feature = "bootloader"))] #[cfg(not(feature = "bootloader"))]
display::text_center( display::text_center(
self.area.bottom_center() - Offset::y(TEXT_BOTTOM_MARGIN), self.area.bottom_center() - Offset::y(TEXT_BOTTOM_MARGIN),