mirror of
https://github.com/trezor/trezor-firmware.git
synced 2025-07-25 16:08:32 +00:00
core/debug: at start, wait for first layout to show up
This commit is contained in:
parent
f22f4d920e
commit
8d2ae142f3
@ -30,7 +30,7 @@ if __debug__:
|
|||||||
debuglink_decision_chan = loop.chan()
|
debuglink_decision_chan = loop.chan()
|
||||||
|
|
||||||
layout_change_chan = loop.chan()
|
layout_change_chan = loop.chan()
|
||||||
current_content = [] # type: List[str]
|
current_content = None # type: Optional[List[str]]
|
||||||
|
|
||||||
def notify_layout_change(layout: ui.Layout) -> None:
|
def notify_layout_change(layout: ui.Layout) -> None:
|
||||||
global current_content
|
global current_content
|
||||||
@ -95,7 +95,7 @@ if __debug__:
|
|||||||
m.passphrase_protection = has_passphrase()
|
m.passphrase_protection = has_passphrase()
|
||||||
m.reset_entropy = reset_internal_entropy
|
m.reset_entropy = reset_internal_entropy
|
||||||
|
|
||||||
if msg.wait_layout:
|
if msg.wait_layout or current_content is None:
|
||||||
m.layout_lines = await layout_change_chan.take()
|
m.layout_lines = await layout_change_chan.take()
|
||||||
else:
|
else:
|
||||||
m.layout_lines = current_content
|
m.layout_lines = current_content
|
||||||
|
Loading…
Reference in New Issue
Block a user