From 40b5fedbd2365aa0492110e8e2fd949749729fca Mon Sep 17 00:00:00 2001 From: tychovrahe Date: Fri, 30 Jun 2023 22:13:54 +0200 Subject: [PATCH] fix(core): fix TT bootloader emulator backlight, fix rust warning [no changelog] --- core/SConscript.bootloader_emu | 1 + core/embed/rust/src/ui/display/mod.rs | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/core/SConscript.bootloader_emu b/core/SConscript.bootloader_emu index e048c504fa..94f1d2acee 100644 --- a/core/SConscript.bootloader_emu +++ b/core/SConscript.bootloader_emu @@ -230,6 +230,7 @@ def cargo_build(): if TREZOR_MODEL in ('T',): features.append('touch') + features.append('backlight') if TREZOR_MODEL in ('R', '1'): features.append('button') diff --git a/core/embed/rust/src/ui/display/mod.rs b/core/embed/rust/src/ui/display/mod.rs index 67a891d6d7..0dbb697e8f 100644 --- a/core/embed/rust/src/ui/display/mod.rs +++ b/core/embed/rust/src/ui/display/mod.rs @@ -23,9 +23,11 @@ use crate::ui::component::image::Image; #[cfg(not(feature = "dma2d"))] use crate::ui::geometry::Alignment2D; +#[cfg(feature = "backlight")] +use crate::{time::Duration, trezorhal::time}; + use crate::{ - time::Duration, - trezorhal::{buffers, display, time, uzlib::UzlibContext}, + trezorhal::{buffers, display, uzlib::UzlibContext}, ui::lerp::Lerp, };