summaryrefslogtreecommitdiffstats
path: root/screen_ui.cpp
diff options
context:
space:
mode:
authorTianjie Xu <xunchang@google.com>2016-04-29 03:06:26 +0200
committerTianjie Xu <xunchang@google.com>2016-04-29 21:19:43 +0200
commit35926c4b89f9dc51f3e55ef03a61e4da6dcb34be (patch)
tree40b27d4d1fcd410295d64bc7a33002adb230ac6e /screen_ui.cpp
parentMerge "Improve the layout-related comments." into nyc-dev (diff)
downloadandroid_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.tar
android_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.tar.gz
android_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.tar.bz2
android_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.tar.lz
android_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.tar.xz
android_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.tar.zst
android_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.zip
Diffstat (limited to 'screen_ui.cpp')
-rw-r--r--screen_ui.cpp15
1 files changed, 14 insertions, 1 deletions
diff --git a/screen_ui.cpp b/screen_ui.cpp
index ccff5bae5..85f789f3f 100644
--- a/screen_ui.cpp
+++ b/screen_ui.cpp
@@ -425,6 +425,16 @@ static char** Alloc2d(size_t rows, size_t cols) {
return result;
}
+// Choose the right background string to display during update.
+void ScreenRecoveryUI::SetSystemUpdateText(bool security_update) {
+ if (security_update) {
+ LoadLocalizedBitmap("installing_security_text", &installing_text);
+ } else {
+ LoadLocalizedBitmap("installing_text", &installing_text);
+ }
+ Redraw();
+}
+
void ScreenRecoveryUI::Init() {
gr_init();
@@ -450,7 +460,10 @@ void ScreenRecoveryUI::Init() {
LoadBitmap("stage_empty", &stageMarkerEmpty);
LoadBitmap("stage_fill", &stageMarkerFill);
- LoadLocalizedBitmap("installing_text", &installing_text);
+ // Background text for "installing_update" could be "installing update"
+ // or "installing security update". It will be set after UI init according
+ // to commands in BCB.
+ installing_text = nullptr;
LoadLocalizedBitmap("erasing_text", &erasing_text);
LoadLocalizedBitmap("no_command_text", &no_command_text);
LoadLocalizedBitmap("error_text", &error_text);