mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-12-19 12:58:13 +00:00
chore(core): decrease code-size a little bit
[no changelog]
This commit is contained in:
parent
9db8ff1fae
commit
5b52db1ed3
@ -33,7 +33,7 @@ async def get_ecdh_session_key(msg: GetECDHSessionKey) -> ECDHSessionKey:
|
||||
await confirm_address(
|
||||
f"Decrypt {proto}",
|
||||
serialize_identity_without_proto(msg_identity),
|
||||
None,
|
||||
"",
|
||||
)
|
||||
# END require_confirm_ecdh_session_key
|
||||
|
||||
|
@ -765,7 +765,7 @@ async def confirm_blob(
|
||||
br_type: str,
|
||||
title: str,
|
||||
data: bytes | str,
|
||||
description: str | None = None,
|
||||
description: str = "",
|
||||
verb: str = "CONFIRM",
|
||||
verb_cancel: str | None = "", # icon
|
||||
hold: bool = False,
|
||||
@ -774,7 +774,6 @@ async def confirm_blob(
|
||||
chunkify: bool = False,
|
||||
) -> None:
|
||||
title = title.upper()
|
||||
description = description or ""
|
||||
layout = RustLayout(
|
||||
trezorui2.confirm_blob(
|
||||
title=title,
|
||||
@ -848,7 +847,7 @@ async def _confirm_ask_pagination(
|
||||
def confirm_address(
|
||||
title: str,
|
||||
address: str,
|
||||
description: str | None = "Address:",
|
||||
description: str = "Address:",
|
||||
br_type: str = "confirm_address",
|
||||
br_code: ButtonRequestType = BR_TYPE_OTHER,
|
||||
) -> Awaitable[None]:
|
||||
|
@ -744,7 +744,7 @@ async def confirm_blob(
|
||||
br_type: str,
|
||||
title: str,
|
||||
data: bytes | str,
|
||||
description: str | None = None,
|
||||
description: str = "",
|
||||
verb: str = "CONFIRM",
|
||||
verb_cancel: str | None = None,
|
||||
hold: bool = False,
|
||||
@ -753,7 +753,6 @@ async def confirm_blob(
|
||||
chunkify: bool = False,
|
||||
) -> None:
|
||||
title = title.upper()
|
||||
description = description or ""
|
||||
layout = RustLayout(
|
||||
trezorui2.confirm_blob(
|
||||
title=title,
|
||||
@ -1019,11 +1018,11 @@ async def confirm_metadata(
|
||||
|
||||
async def confirm_replacement(title: str, txid: str) -> None:
|
||||
await confirm_blob(
|
||||
title=title.upper(),
|
||||
data=txid,
|
||||
description="Transaction ID:",
|
||||
verb="CONTINUE",
|
||||
br_type="confirm_replacement",
|
||||
"confirm_replacement",
|
||||
title.upper(),
|
||||
txid,
|
||||
"Transaction ID:",
|
||||
"CONTINUE",
|
||||
br_code=ButtonRequestType.SignTx,
|
||||
)
|
||||
|
||||
@ -1148,10 +1147,10 @@ async def confirm_sign_identity(
|
||||
proto: str, identity: str, challenge_visual: str | None
|
||||
) -> None:
|
||||
await confirm_blob(
|
||||
title=f"Sign {proto}",
|
||||
data=identity,
|
||||
description=challenge_visual + "\n" if challenge_visual else "",
|
||||
br_type="sign_identity",
|
||||
"sign_identity",
|
||||
f"Sign {proto}",
|
||||
identity,
|
||||
challenge_visual + "\n" if challenge_visual else "",
|
||||
br_code=BR_TYPE_OTHER,
|
||||
)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user