ui: Boot from default target altfw after timeout

When the default boot target is alternate bootloader (altfw), in the
current implementation the device won't boot from altfw after timeout.
Instead, it will simply enter the bootloader selection screen (assuming
there is available altfw). This is a regression when implementing menu
UI.

To fix it, when developer screen timeout, instead of selecting the
current menu item, call the corresponding boot function (such as
ui_developer_mode_boot_external_action()). Also split
ui_developer_mode_boot_altfw_action() to two versions: one for the
default altfw (for Ctrl+L shortcut and auto boot after timeout), and the
other for manually selected altfw.

BUG=b:200898240
TEST=make unit-tests
BRANCH=none

Change-Id: Ibcf81bcd7dcfe2f59940760d0f26ca4e5f678143
Signed-off-by: Yu-Ping Wu <yupingso@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/depthcharge/+/3240686
Reviewed-by: Evan Green <evgreen@chromium.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
3 files changed