Fix boot UI overlap && optimize GIF memory management#405
Fix boot UI overlap && optimize GIF memory management#405lihuanhuan merged 4 commits intoOneKeyHQ:mainfrom
Conversation
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
WalkthroughFirmware build naming updated for Bitcoin-only mode. Progress bar visibility tracking refactored across bootloader and EMMC modules. Bootloader navigation input scheme changed from PREVIOUS/RESTART to CANCEL/CONFIRM. LCD rectangle boundary computation adjusted for inclusive bounds. LVGL submodule version updated. Changes
Estimated code review effort🎯 4 (Complex) | ⏱️ ~50 minutes Pre-merge checks and finishing touches❌ Failed checks (2 warnings)
✅ Passed checks (1 passed)
✨ Finishing touches
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (1)
core/embed/emmc_wrapper/emmc_commands.c (1)
30-40: Duplicate code in branches.Both branches call
ui_screen_progress_bar_updatewith the same arguments.Proposed simplification
- if ( percentage < 100 ) - { - ui_screen_progress_bar_update(progress_title, NULL, percentage); - } - else - { - ui_screen_progress_bar_update(progress_title, NULL, percentage); + ui_screen_progress_bar_update(progress_title, NULL, percentage); + if ( percentage >= 100 ) + { ui_fadeout(); ui_bootloader_first(NULL); ui_fadein(); }
📜 Review details
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Cache: Disabled due to data retention organization setting
Knowledge base: Disabled due to data retention organization setting
Disabled knowledge base sources:
- Jira integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (8)
core/Makefilecore/embed/bootloader/bootui.ccore/embed/bootloader/bootui.hcore/embed/bootloader/main.ccore/embed/emmc_wrapper/emmc_commands.ccore/embed/emmc_wrapper/emmc_commands.hcore/embed/extmod/modtrezorui/mipi_lcd.cvendor/lvgl_mp
💤 Files with no reviewable changes (2)
- core/embed/emmc_wrapper/emmc_commands.h
- core/embed/bootloader/main.c
🧰 Additional context used
🧬 Code graph analysis (2)
core/embed/bootloader/bootui.h (1)
core/embed/bootloader/bootui.c (1)
ui_progress_bar_visible_clear(410-410)
core/embed/emmc_wrapper/emmc_commands.c (2)
core/embed/bootloader/bootui.c (5)
ui_screen_progress_bar_update(386-408)ui_fadeout(543-546)ui_bootloader_first(983-1042)ui_fadein(541-541)ui_progress_bar_visible_clear(410-410)core/embed/extmod/modtrezorui/display.c (1)
display_clear(170-172)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
- GitHub Check: Gen check
- GitHub Check: Defs check
- GitHub Check: Style check
🔇 Additional comments (12)
vendor/lvgl_mp (1)
1-1: Verify the LVGL submodule commit and its changes.Confirm the submodule commit is valid and aligns with the PR objectives (UI overlap fix, GIF memory optimization). Document what changed between the two commits.
core/embed/bootloader/bootui.h (1)
58-58: LGTM!Declaration matches the implementation.
core/Makefile (1)
57-58: LGTM!Shorter suffix. Cleaner.
core/embed/extmod/modtrezorui/mipi_lcd.c (1)
480-481: LGTM!Offset now reflects actual drawn width after clamping.
core/embed/emmc_wrapper/emmc_commands.c (2)
1735-1744: LGTM!Progress handling is now encapsulated.
1845-1854: LGTM!Same pattern as read handler.
core/embed/bootloader/bootui.c (6)
363-364: LGTM!Static state flag for progress visibility.
375-384: LGTM!Sets visible flag and renders initial state.
386-408: LGTM!Visibility check prevents redundant fade transitions.
410-411: LGTM!Simple and clear.
988-989: LGTM!Resets progress state on first screen.
1311-1318: LGTM!Input scheme now uses Cancel/Confirm. Consistent with button labels in
ui_bootloader_device_testat line 1252.
Summary by CodeRabbit
Improvements
Bug Fixes
Chores
✏️ Tip: You can customize this high-level summary in your review settings.