diff --git a/core/embed/rust/librust_qstr.h b/core/embed/rust/librust_qstr.h index d04460c4a29..c5e0e56599e 100644 --- a/core/embed/rust/librust_qstr.h +++ b/core/embed/rust/librust_qstr.h @@ -742,7 +742,6 @@ static void _librust_qstrs(void) { MP_QSTR_value; MP_QSTR_verb; MP_QSTR_verb_cancel; - MP_QSTR_verb_info; MP_QSTR_verify; MP_QSTR_version; MP_QSTR_warning; diff --git a/core/embed/rust/src/ui/model_mercury/layout.rs b/core/embed/rust/src/ui/model_mercury/layout.rs index a810ad160b5..787cc3b325c 100644 --- a/core/embed/rust/src/ui/model_mercury/layout.rs +++ b/core/embed/rust/src/ui/model_mercury/layout.rs @@ -269,7 +269,6 @@ extern "C" fn new_confirm_blob(n_args: usize, args: *const Obj, kwargs: *mut Map .get(Qstr::MP_QSTR_description) .unwrap_or_else(|_| Obj::const_none()) .try_into_option()?; - let text_mono: bool = kwargs.get_or(Qstr::MP_QSTR_text_mono, true)?; let extra: Option = kwargs .get(Qstr::MP_QSTR_extra) .unwrap_or_else(|_| Obj::const_none()) @@ -286,10 +285,6 @@ extern "C" fn new_confirm_blob(n_args: usize, args: *const Obj, kwargs: *mut Map .get(Qstr::MP_QSTR_verb_cancel) .unwrap_or_else(|_| Obj::const_none()) .try_into_option()?; - let verb_info: Option = kwargs - .get(Qstr::MP_QSTR_verb_info) - .unwrap_or_else(|_| Obj::const_none()) - .try_into_option()?; let info: bool = kwargs.get_or(Qstr::MP_QSTR_info, true)?; let hold: bool = kwargs.get_or(Qstr::MP_QSTR_hold, false)?; let chunkify: bool = kwargs.get_or(Qstr::MP_QSTR_chunkify, false)?; @@ -298,15 +293,10 @@ extern "C" fn new_confirm_blob(n_args: usize, args: *const Obj, kwargs: *mut Map let cancel: bool = kwargs.get_or(Qstr::MP_QSTR_cancel, false)?; ConfirmBlobParams::new(title, data, description) - .with_text_mono(text_mono) .with_subtitle(subtitle) .with_verb(verb) .with_verb_cancel(verb_cancel.unwrap_or(TR::buttons__cancel.into())) - .with_verb_info(if info { - Some(verb_info.unwrap_or(TR::words__title_information.into())) - } else { - None - }) + .with_verb_info(if info { Some(TR::words__title_information.into()) } else { None }) .with_extra(extra) .with_chunkify(chunkify) .with_page_counter(page_counter) @@ -1589,12 +1579,10 @@ pub static mp_module_trezorui2: Module = obj_module! { /// title: str, /// data: str | bytes, /// description: str | None, - /// text_mono: bool = True, /// extra: str | None = None, /// subtitle: str | None = None, /// verb: str | None = None, /// verb_cancel: str | None = None, - /// verb_info: str | None = None, /// info: bool = True, /// hold: bool = False, /// chunkify: bool = False, diff --git a/core/embed/rust/src/ui/model_tr/layout.rs b/core/embed/rust/src/ui/model_tr/layout.rs index 9c32929da52..1c997bb5444 100644 --- a/core/embed/rust/src/ui/model_tr/layout.rs +++ b/core/embed/rust/src/ui/model_tr/layout.rs @@ -1700,12 +1700,10 @@ pub static mp_module_trezorui2: Module = obj_module! { /// title: str, /// data: str | bytes, /// description: str | None, - /// text_mono: bool = True, /// extra: str | None = None, /// subtitle: str | None = None, /// verb: str = "CONFIRM", /// verb_cancel: str | None = None, - /// verb_info: str | None = None, /// info: bool = True, /// hold: bool = False, /// chunkify: bool = False, diff --git a/core/embed/rust/src/ui/model_tt/layout.rs b/core/embed/rust/src/ui/model_tt/layout.rs index 46b645d8aa8..3485a5c5a9a 100644 --- a/core/embed/rust/src/ui/model_tt/layout.rs +++ b/core/embed/rust/src/ui/model_tt/layout.rs @@ -509,7 +509,6 @@ extern "C" fn new_confirm_blob(n_args: usize, args: *const Obj, kwargs: *mut Map let data: Obj = kwargs.get(Qstr::MP_QSTR_data)?; let description: Option = kwargs.get(Qstr::MP_QSTR_description)?.try_into_option()?; - let text_mono: bool = kwargs.get_or(Qstr::MP_QSTR_text_mono, true)?; let extra: Option = kwargs .get(Qstr::MP_QSTR_extra) .unwrap_or_else(|_| Obj::const_none()) @@ -527,7 +526,6 @@ extern "C" fn new_confirm_blob(n_args: usize, args: *const Obj, kwargs: *mut Map let chunkify: bool = kwargs.get_or(Qstr::MP_QSTR_chunkify, false)?; ConfirmBlobParams::new(title, data, description, verb, verb_cancel, hold) - .with_text_mono(text_mono) .with_extra(extra) .with_chunkify(chunkify) .with_info_button(info) @@ -1781,12 +1779,10 @@ pub static mp_module_trezorui2: Module = obj_module! { /// title: str, /// data: str | bytes, /// description: str | None, - /// text_mono: bool = True, /// extra: str | None = None, /// subtitle: str | None = None, /// verb: str | None = None, /// verb_cancel: str | None = None, - /// verb_info: str | None = None, /// info: bool = True, /// hold: bool = False, /// chunkify: bool = False, diff --git a/core/mocks/generated/trezorui2.pyi b/core/mocks/generated/trezorui2.pyi index e7aadccea98..c2fe0f27618 100644 --- a/core/mocks/generated/trezorui2.pyi +++ b/core/mocks/generated/trezorui2.pyi @@ -59,12 +59,10 @@ def confirm_blob( title: str, data: str | bytes, description: str | None, - text_mono: bool = True, extra: str | None = None, subtitle: str | None = None, verb: str | None = None, verb_cancel: str | None = None, - verb_info: str | None = None, info: bool = True, hold: bool = False, chunkify: bool = False, @@ -636,12 +634,10 @@ def confirm_blob( title: str, data: str | bytes, description: str | None, - text_mono: bool = True, extra: str | None = None, subtitle: str | None = None, verb: str = "CONFIRM", verb_cancel: str | None = None, - verb_info: str | None = None, info: bool = True, hold: bool = False, chunkify: bool = False, @@ -1208,12 +1204,10 @@ def confirm_blob( title: str, data: str | bytes, description: str | None, - text_mono: bool = True, extra: str | None = None, subtitle: str | None = None, verb: str | None = None, verb_cancel: str | None = None, - verb_info: str | None = None, info: bool = True, hold: bool = False, chunkify: bool = False, diff --git a/core/src/trezor/ui/layouts/mercury/__init__.py b/core/src/trezor/ui/layouts/mercury/__init__.py index d7a7a010d8b..9cb442201d8 100644 --- a/core/src/trezor/ui/layouts/mercury/__init__.py +++ b/core/src/trezor/ui/layouts/mercury/__init__.py @@ -470,12 +470,9 @@ def confirm_blob( title: str, data: bytes | str, description: str | None = None, - text_mono: bool = True, subtitle: str | None = None, verb: str | None = None, verb_cancel: str | None = None, - info: bool = True, - hold: bool = False, br_code: ButtonRequestType = BR_CODE_OTHER, ask_pagination: bool = False, chunkify: bool = False, @@ -498,7 +495,6 @@ def confirm_blob( verb=None, verb_cancel=verb_cancel, info=False, - hold=False, chunkify=chunkify, page_counter=True, prompt_screen=False, @@ -518,12 +514,9 @@ def confirm_blob( title=title, data=data, description=description, - text_mono=text_mono, subtitle=subtitle, verb=verb, verb_cancel=verb_cancel, - info=info, - hold=hold, chunkify=chunkify, prompt_screen=prompt_screen, ) diff --git a/core/src/trezor/ui/layouts/tr/__init__.py b/core/src/trezor/ui/layouts/tr/__init__.py index 2cbed8ec162..236379927ef 100644 --- a/core/src/trezor/ui/layouts/tr/__init__.py +++ b/core/src/trezor/ui/layouts/tr/__init__.py @@ -579,8 +579,6 @@ def confirm_blob( subtitle: str | None = None, verb: str | None = None, verb_cancel: str | None = None, # icon - info: bool = True, - hold: bool = False, br_code: ButtonRequestType = BR_CODE_OTHER, ask_pagination: bool = False, chunkify: bool = False, @@ -593,12 +591,10 @@ def confirm_blob( data=data, verb=verb, verb_cancel="", - hold=hold, chunkify=chunkify, ) if ask_pagination and layout.page_count() > 1: - assert not hold return _confirm_ask_pagination(br_name, title, data, description or "", br_code) else: return raise_if_not_confirmed(layout, br_name, br_code) diff --git a/core/src/trezor/ui/layouts/tt/__init__.py b/core/src/trezor/ui/layouts/tt/__init__.py index 0f07a4298d2..7eebc0a1da1 100644 --- a/core/src/trezor/ui/layouts/tt/__init__.py +++ b/core/src/trezor/ui/layouts/tt/__init__.py @@ -572,12 +572,9 @@ def confirm_blob( title: str, data: bytes | str, description: str | None = None, - text_mono: bool = True, subtitle: str | None = None, verb: str | None = None, verb_cancel: str | None = None, - info: bool = True, - hold: bool = False, br_code: ButtonRequestType = BR_CODE_OTHER, ask_pagination: bool = False, chunkify: bool = False, @@ -587,16 +584,13 @@ def confirm_blob( layout = trezorui2.confirm_blob( title=title, description=description, - text_mono=text_mono, data=data, - hold=hold, verb=verb, verb_cancel=None, chunkify=chunkify, ) if ask_pagination and layout.page_count() > 1: - assert not hold return _confirm_ask_pagination(br_name, title, data, description or "", br_code) else: return raise_if_not_confirmed(