mirror of
https://github.com/trezor/trezor-firmware.git
synced 2025-05-08 09:58:46 +00:00
core/boot: modify initial lockscreen label
This commit is contained in:
parent
09af8aed4e
commit
a9ddc2a8e2
@ -14,8 +14,11 @@ async def lockscreen() -> None:
|
|||||||
|
|
||||||
|
|
||||||
class Lockscreen(HomescreenBase):
|
class Lockscreen(HomescreenBase):
|
||||||
def __init__(self, lock_label: str = "Locked") -> None:
|
def __init__(
|
||||||
|
self, lock_label: str = "Locked", tap_label: str = "Tap to unlock"
|
||||||
|
) -> None:
|
||||||
self.lock_label = lock_label
|
self.lock_label = lock_label
|
||||||
|
self.tap_label = tap_label
|
||||||
super().__init__()
|
super().__init__()
|
||||||
|
|
||||||
def render_lock(self) -> None:
|
def render_lock(self) -> None:
|
||||||
@ -26,7 +29,7 @@ class Lockscreen(HomescreenBase):
|
|||||||
)
|
)
|
||||||
|
|
||||||
ui.display.text_center(
|
ui.display.text_center(
|
||||||
ui.WIDTH // 2 + 10, 220, "Tap to unlock", ui.BOLD, ui.TITLE_GREY, ui.BG
|
ui.WIDTH // 2 + 10, 220, self.tap_label, ui.BOLD, ui.TITLE_GREY, ui.BG
|
||||||
)
|
)
|
||||||
ui.display.icon(45, 202, res.load(ui.ICON_CLICK), ui.TITLE_GREY, ui.BG)
|
ui.display.icon(45, 202, res.load(ui.ICON_CLICK), ui.TITLE_GREY, ui.BG)
|
||||||
|
|
||||||
|
@ -9,7 +9,7 @@ from apps.homescreen.lockscreen import Lockscreen
|
|||||||
|
|
||||||
|
|
||||||
async def bootscreen() -> None:
|
async def bootscreen() -> None:
|
||||||
lockscreen = Lockscreen(lock_label="Disconnected")
|
lockscreen = Lockscreen(lock_label="Not connected", tap_label="Tap to connect")
|
||||||
ui.display.orientation(storage.device.get_rotation())
|
ui.display.orientation(storage.device.get_rotation())
|
||||||
while True:
|
while True:
|
||||||
try:
|
try:
|
||||||
|
Loading…
Reference in New Issue
Block a user