chore(core): rename screen_connect parameters to better reflect functionality
What changed, and why it matters
This is a simple code cleanup change that renames a parameter from 'auto_update' to 'show_menu' across several files. The functionality remains exactly the same; only the variable name has been changed to better describe what it actually controls (whether a menu button is shown on the bootloader connection screen). There is no security impact.
No security action required. This is a non-functional refactor.
Security signals we found
No strong security signals were identified.
Evidence from the diff
Pure identifier rename refactor in the bootloader UI code. The boolean parameter previously called ‘auto_update’ is renamed to ‘show_menu’ in the C header, Rust FFI wrapper, trait definition, and all model-specific implementations. No logic, control flow, or behavior changes are present in the diff.
Changed components
core/embed/rust/rust_ui_bootloader.hcore/embed/rust/src/ui/api/bootloader_c.rscore/embed/rust/src/ui/layout_bolt/bootloader/connect.rscore/embed/rust/src/ui/layout_bolt/bootloader/mod.rscore/embed/rust/src/ui/layout_caesar/bootloader/mod.rscore/embed/rust/src/ui/layout_delizia/bootloader/mod.rscore/embed/rust/src/ui/layout_eckhart/ui_bootloader.rscore/embed/rust/src/ui/ui_bootloader.rsInspect captured patch +12 / −12
diff --git a/core/embed/rust/rust_ui_bootloader.h b/core/embed/rust/rust_ui_bootloader.h
index 471f5ee6..d8c755a1 100644
--- a/core/embed/rust/rust_ui_bootloader.h
+++ b/core/embed/rust/rust_ui_bootloader.h
@@ -77,7 +77,7 @@ typedef enum {
CONNECT_PAIRING_MODE = 2,
CONNECT_MENU = 3,
} connect_result_t;
-uint32_t screen_connect(bool initial_setup, bool auto_update,
+uint32_t screen_connect(bool initial_setup, bool show_menu,
uint32_t* ui_result);
typedef enum {
diff --git a/core/embed/rust/src/ui/api/bootloader_c.rs b/core/embed/rust/src/ui/api/bootloader_c.rs
index 89855e89..f6db1206 100644
--- a/core/embed/rust/src/ui/api/bootloader_c.rs
+++ b/core/embed/rust/src/ui/api/bootloader_c.rs
@@ -151,10 +151,10 @@ extern "C" fn screen_install_progress(
#[no_mangle]
extern "C" fn screen_connect(
initial_setup: bool,
- auto_update: bool,
+ show_menu: bool,
ui_action_result: *mut u32,
) -> u32 {
- let (res, ui_res) = ModelUI::screen_connect(initial_setup, auto_update);
+ let (res, ui_res) = ModelUI::screen_connect(initial_setup, show_menu);
unsafe {
*ui_action_result = ui_res;
}
diff --git a/core/embed/rust/src/ui/layout_bolt/bootloader/connect.rs b/core/embed/rust/src/ui/layout_bolt/bootloader/connect.rs
index 236986ef..a4b08999 100644
--- a/core/embed/rust/src/ui/layout_bolt/bootloader/connect.rs
+++ b/core/embed/rust/src/ui/layout_bolt/bootloader/connect.rs
@@ -35,7 +35,7 @@ pub struct Connect {
}
impl Connect {
- pub fn new<T>(message: T, font: Font, fg: Color, initial_setup: bool, auto_update: bool) -> Self
+ pub fn new<T>(message: T, font: Font, fg: Color, initial_setup: bool, show_menu: bool) -> Self
where
T: Into<TString<'static>>,
{
@@ -57,7 +57,7 @@ impl Connect {
)
};
- let menu = if auto_update { Some(menu_btn) } else { None };
+ let menu = if show_menu { Some(menu_btn) } else { None };
let mut instance = Self {
fg,
diff --git a/core/embed/rust/src/ui/layout_bolt/bootloader/mod.rs b/core/embed/rust/src/ui/layout_bolt/bootloader/mod.rs
index e308392f..57545740 100644
--- a/core/embed/rust/src/ui/layout_bolt/bootloader/mod.rs
+++ b/core/embed/rust/src/ui/layout_bolt/bootloader/mod.rs
@@ -149,13 +149,13 @@ impl BootloaderUI for UIBolt {
run(&mut frame, true, communication)
}
- fn screen_connect(initial_setup: bool, auto_update: bool) -> (u32, u32) {
+ fn screen_connect(initial_setup: bool, show_menu: bool) -> (u32, u32) {
let mut frame = Connect::new(
"Waiting for host...",
fonts::FONT_NORMAL,
BLD_TITLE_COLOR,
initial_setup,
- auto_update,
+ show_menu,
);
run(&mut frame, true, true)
}
diff --git a/core/embed/rust/src/ui/layout_caesar/bootloader/mod.rs b/core/embed/rust/src/ui/layout_caesar/bootloader/mod.rs
index 622acfd0..32564be7 100644
--- a/core/embed/rust/src/ui/layout_caesar/bootloader/mod.rs
+++ b/core/embed/rust/src/ui/layout_caesar/bootloader/mod.rs
@@ -104,7 +104,7 @@ impl BootloaderUI for UICaesar {
run(&mut frame, true, communication)
}
- fn screen_connect(_initial_setup: bool, _auto_update: bool) -> (u32, u32) {
+ fn screen_connect(_initial_setup: bool, _show_menu: bool) -> (u32, u32) {
let mut frame = Connect::new("Waiting for host...", fonts::FONT_NORMAL, BLD_FG, BLD_BG);
run(&mut frame, true, true)
diff --git a/core/embed/rust/src/ui/layout_delizia/bootloader/mod.rs b/core/embed/rust/src/ui/layout_delizia/bootloader/mod.rs
index 9205374f..c8f315ad 100644
--- a/core/embed/rust/src/ui/layout_delizia/bootloader/mod.rs
+++ b/core/embed/rust/src/ui/layout_delizia/bootloader/mod.rs
@@ -134,7 +134,7 @@ impl BootloaderUI for UIDelizia {
run(&mut frame, true, communication)
}
- fn screen_connect(_initial_setup: bool, _auto_update: bool) -> (u32, u32) {
+ fn screen_connect(_initial_setup: bool, _show_menu: bool) -> (u32, u32) {
let mut frame = Connect::new(
"Waiting for host...",
fonts::FONT_DEMIBOLD,
diff --git a/core/embed/rust/src/ui/layout_eckhart/ui_bootloader.rs b/core/embed/rust/src/ui/layout_eckhart/ui_bootloader.rs
index a568e902..04555843 100644
--- a/core/embed/rust/src/ui/layout_eckhart/ui_bootloader.rs
+++ b/core/embed/rust/src/ui/layout_eckhart/ui_bootloader.rs
@@ -106,9 +106,9 @@ impl BootloaderUI for UIEckhart {
run(&mut screen, true, communication)
}
- fn screen_connect(initial_setup: bool, auto_update: bool) -> (u32, u32) {
+ fn screen_connect(initial_setup: bool, show_menu: bool) -> (u32, u32) {
let mut screen = ConnectScreen::new(initial_setup);
- if auto_update {
+ if show_menu {
screen = screen.with_header(BldHeader::new("Bootloader".into()).with_menu_button());
}
if !initial_setup {
diff --git a/core/embed/rust/src/ui/ui_bootloader.rs b/core/embed/rust/src/ui/ui_bootloader.rs
index b5bbdadd..6a25d3b1 100644
--- a/core/embed/rust/src/ui/ui_bootloader.rs
+++ b/core/embed/rust/src/ui/ui_bootloader.rs
@@ -3,7 +3,7 @@ pub trait BootloaderUI {
fn screen_menu(initial_setup: bool, communication: bool) -> (u32, u32);
- fn screen_connect(initial_setup: bool, auto_update: bool) -> (u32, u32);
+ fn screen_connect(initial_setup: bool, show_menu: bool) -> (u32, u32);
#[cfg(feature = "ble")]
fn screen_pairing_mode(_initial_setup: bool, _name: &'static str) -> (u32, u32) {
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.