mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2025-12-02 14:14:12 +00:00
detachables: Use locale bitmaps instead of text
BUG=b:35585623 BRANCH=None TEST=reboot and make sure that the bitmaps show up Change-Id: I92a9cf7dc808a22c7ace25763d4ef49824a93054 Signed-off-by: Shelley Chen <shchen@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/457840
This commit is contained in:
@@ -647,7 +647,8 @@ VbError_t vb2_developer_menu(struct vb2_context *ctx, VbCommonParams *cparams)
|
||||
/* If dev mode is disabled, only allow TONORM */
|
||||
while (disable_dev_boot) {
|
||||
VB2_DEBUG("dev_disable_boot is set.\n");
|
||||
VbDisplayScreen(ctx, cparams, VB_SCREEN_DEVELOPER_TO_NORM, 0);
|
||||
VbDisplayScreen(ctx, cparams, VB_SCREEN_DEVELOPER_TO_NORM_MENU,
|
||||
0);
|
||||
VbExDisplayDebugInfo(dev_disable_msg);
|
||||
|
||||
/* Ignore space in VbUserConfirmsMenu()... */
|
||||
@@ -670,9 +671,7 @@ VbError_t vb2_developer_menu(struct vb2_context *ctx, VbCommonParams *cparams)
|
||||
}
|
||||
|
||||
/* Show the dev mode warning screen */
|
||||
//TODO: change this to blank screen?
|
||||
VbDisplayScreen(ctx, cparams, VB_SCREEN_BASE, 0);
|
||||
vb2_print_current_menu();
|
||||
vb2_draw_current_screen(ctx, cparams);
|
||||
|
||||
/* Get audio/delay context */
|
||||
audio = VbAudioOpen(cparams);
|
||||
@@ -729,11 +728,7 @@ VbError_t vb2_developer_menu(struct vb2_context *ctx, VbCommonParams *cparams)
|
||||
return VBERROR_SUCCESS;
|
||||
} else {
|
||||
/* Show dev mode warning screen again */
|
||||
VbDisplayScreen(ctx,
|
||||
cparams,
|
||||
VB_SCREEN_BASE,
|
||||
0);
|
||||
vb2_print_current_menu();
|
||||
vb2_draw_current_screen(ctx, cparams);
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -745,7 +740,6 @@ VbError_t vb2_developer_menu(struct vb2_context *ctx, VbCommonParams *cparams)
|
||||
if (current_menu_idx > 0)
|
||||
current_menu_idx--;
|
||||
vb2_draw_current_screen(ctx, cparams);
|
||||
vb2_print_current_menu();
|
||||
break;
|
||||
case VB_BUTTON_VOL_DOWN:
|
||||
case VB_KEY_DOWN:
|
||||
@@ -755,7 +749,6 @@ VbError_t vb2_developer_menu(struct vb2_context *ctx, VbCommonParams *cparams)
|
||||
if (current_menu_idx < menu_size-1)
|
||||
current_menu_idx++;
|
||||
vb2_draw_current_screen(ctx, cparams);
|
||||
vb2_print_current_menu();
|
||||
break;
|
||||
case VB_BUTTON_POWER:
|
||||
case '\r':
|
||||
@@ -767,9 +760,7 @@ VbError_t vb2_developer_menu(struct vb2_context *ctx, VbCommonParams *cparams)
|
||||
* artifacts from previous menu printing.
|
||||
*/
|
||||
VbDisplayScreen(ctx, cparams, VB_SCREEN_BLANK, 0);
|
||||
VbDisplayScreen(ctx, cparams,
|
||||
VB_SCREEN_BASE, 0);
|
||||
vb2_print_current_menu();
|
||||
vb2_draw_current_screen(ctx, cparams);
|
||||
|
||||
/* Probably shutting down */
|
||||
if (ret != VBERROR_SUCCESS) {
|
||||
@@ -822,17 +813,13 @@ VbError_t vb2_developer_menu(struct vb2_context *ctx, VbCommonParams *cparams)
|
||||
VbTryUsbMenu(ctx, cparams)) {
|
||||
VbAudioClose(audio);
|
||||
return VBERROR_SUCCESS;
|
||||
} else {
|
||||
} else
|
||||
/*
|
||||
* Show dev mode warning screen
|
||||
* again
|
||||
*/
|
||||
VbDisplayScreen(ctx,
|
||||
cparams,
|
||||
VB_SCREEN_BASE,
|
||||
0);
|
||||
vb2_print_current_menu();
|
||||
}
|
||||
vb2_draw_current_screen(ctx,
|
||||
cparams);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -985,12 +972,12 @@ VbError_t vb2_recovery_menu(struct vb2_context *ctx, VbCommonParams *cparams)
|
||||
|
||||
if (current_menu != VB_MENU_RECOVERY ||
|
||||
current_menu_idx != VB_RECOVERY_DBG_INFO) {
|
||||
VbDisplayScreen(ctx, cparams,
|
||||
VBERROR_NO_DISK_FOUND == retval ?
|
||||
VB_SCREEN_BASE :
|
||||
VB_SCREEN_RECOVERY_NO_GOOD,
|
||||
0);
|
||||
vb2_print_current_menu();
|
||||
if (retval == VBERROR_NO_DISK_FOUND)
|
||||
vb2_draw_current_screen(ctx, cparams);
|
||||
else
|
||||
VbDisplayScreen(ctx, cparams,
|
||||
VB_SCREEN_RECOVERY_NO_GOOD,
|
||||
0);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -1005,19 +992,19 @@ VbError_t vb2_recovery_menu(struct vb2_context *ctx, VbCommonParams *cparams)
|
||||
break;
|
||||
case VB_BUTTON_VOL_UP:
|
||||
case VB_KEY_UP:
|
||||
vb2_get_current_menu_size(current_menu, NULL, &menu_size);
|
||||
vb2_get_current_menu_size(current_menu, NULL,
|
||||
&menu_size);
|
||||
if (current_menu_idx > 0)
|
||||
current_menu_idx--;
|
||||
vb2_draw_current_screen(ctx, cparams);
|
||||
vb2_print_current_menu();
|
||||
break;
|
||||
case VB_BUTTON_VOL_DOWN:
|
||||
case VB_KEY_DOWN:
|
||||
vb2_get_current_menu_size(current_menu, NULL, &menu_size);
|
||||
vb2_get_current_menu_size(current_menu, NULL,
|
||||
&menu_size);
|
||||
if (current_menu_idx < menu_size-1)
|
||||
current_menu_idx++;
|
||||
vb2_draw_current_screen(ctx, cparams);
|
||||
vb2_print_current_menu();
|
||||
break;
|
||||
case VB_BUTTON_POWER:
|
||||
case '\r':
|
||||
@@ -1031,12 +1018,13 @@ VbError_t vb2_recovery_menu(struct vb2_context *ctx, VbCommonParams *cparams)
|
||||
* blanking to clear previous menus
|
||||
* printed.
|
||||
*/
|
||||
VbDisplayScreen(ctx, cparams, VB_SCREEN_BLANK, 0);
|
||||
VbDisplayScreen(ctx, cparams, VBERROR_NO_DISK_FOUND == retval ?
|
||||
VB_SCREEN_BASE :
|
||||
VB_SCREEN_RECOVERY_NO_GOOD,
|
||||
0);
|
||||
vb2_print_current_menu();
|
||||
if (retval == VBERROR_NO_DISK_FOUND)
|
||||
vb2_draw_current_screen(ctx,
|
||||
cparams);
|
||||
else
|
||||
VbDisplayScreen(ctx, cparams,
|
||||
VB_SCREEN_RECOVERY_NO_GOOD,
|
||||
0);
|
||||
}
|
||||
|
||||
/* Probably shutting down */
|
||||
|
||||
Reference in New Issue
Block a user