summaryrefslogtreecommitdiffstats
path: root/wear_ui.cpp
diff options
context:
space:
mode:
authorTao Bao <tbao@google.com>2018-10-22 08:36:26 +0200
committerTao Bao <tbao@google.com>2018-11-05 19:15:59 +0100
commitda409fb8d615c3e1aac6505827026843aee25324 (patch)
treee7ccaaf6b4916f8923785bdbd04405d0b2085d3a /wear_ui.cpp
parentMerge "Make the text image readable under recovery" (diff)
downloadandroid_bootable_recovery-da409fb8d615c3e1aac6505827026843aee25324.tar
android_bootable_recovery-da409fb8d615c3e1aac6505827026843aee25324.tar.gz
android_bootable_recovery-da409fb8d615c3e1aac6505827026843aee25324.tar.bz2
android_bootable_recovery-da409fb8d615c3e1aac6505827026843aee25324.tar.lz
android_bootable_recovery-da409fb8d615c3e1aac6505827026843aee25324.tar.xz
android_bootable_recovery-da409fb8d615c3e1aac6505827026843aee25324.tar.zst
android_bootable_recovery-da409fb8d615c3e1aac6505827026843aee25324.zip
Diffstat (limited to '')
-rw-r--r--wear_ui.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/wear_ui.cpp b/wear_ui.cpp
index 0611f94c9..6da84c924 100644
--- a/wear_ui.cpp
+++ b/wear_ui.cpp
@@ -51,8 +51,8 @@ void WearRecoveryUI::draw_background_locked() {
gr_color(0, 0, 0, 255);
gr_fill(0, 0, gr_fb_width(), gr_fb_height());
- if (currentIcon != NONE) {
- GRSurface* frame = GetCurrentFrame();
+ if (current_icon_ != NONE) {
+ const auto& frame = GetCurrentFrame();
int frame_width = gr_get_width(frame);
int frame_height = gr_get_height(frame);
int frame_x = (gr_fb_width() - frame_width) / 2;
@@ -60,7 +60,7 @@ void WearRecoveryUI::draw_background_locked() {
gr_blit(frame, 0, 0, frame_width, frame_height, frame_x, frame_y);
// Draw recovery text on screen above progress bar.
- GRSurface* text = GetCurrentText();
+ const auto& text = GetCurrentText();
int text_x = (ScreenWidth() - gr_get_width(text)) / 2;
int text_y = GetProgressBaseline() - gr_get_height(text) - 10;
gr_color(255, 255, 255, 255);