summaryrefslogtreecommitdiffstats
path: root/wear_ui.cpp
diff options
context:
space:
mode:
authorDamien Bargiacchi <drb@google.com>2016-08-24 22:36:35 +0200
committerAndroid (Google) Code Review <android-gerrit@google.com>2016-08-24 22:36:36 +0200
commit929ffefdccf3f7b6e2810cc47efaf93626f9a2cc (patch)
tree7fba041af0f98ba2a037d3f22b5e7744d4d7e2f5 /wear_ui.cpp
parent"view recovery logs" will show /tmp/recovery.log (diff)
parentSupport use of custom fonts in miniui (diff)
downloadandroid_bootable_recovery-929ffefdccf3f7b6e2810cc47efaf93626f9a2cc.tar
android_bootable_recovery-929ffefdccf3f7b6e2810cc47efaf93626f9a2cc.tar.gz
android_bootable_recovery-929ffefdccf3f7b6e2810cc47efaf93626f9a2cc.tar.bz2
android_bootable_recovery-929ffefdccf3f7b6e2810cc47efaf93626f9a2cc.tar.lz
android_bootable_recovery-929ffefdccf3f7b6e2810cc47efaf93626f9a2cc.tar.xz
android_bootable_recovery-929ffefdccf3f7b6e2810cc47efaf93626f9a2cc.tar.zst
android_bootable_recovery-929ffefdccf3f7b6e2810cc47efaf93626f9a2cc.zip
Diffstat (limited to 'wear_ui.cpp')
-rw-r--r--wear_ui.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/wear_ui.cpp b/wear_ui.cpp
index b437fd0ae..f9727af01 100644
--- a/wear_ui.cpp
+++ b/wear_ui.cpp
@@ -177,7 +177,7 @@ void WearRecoveryUI::draw_screen_locked()
// items don't fit on the screen.
if (menu_items > menu_end - menu_start) {
sprintf(cur_selection_str, "Current item: %d/%d", menu_sel + 1, menu_items);
- gr_text(x+4, y, cur_selection_str, 1);
+ gr_text(gr_sys_font(), x+4, y, cur_selection_str, 1);
y += char_height_+4;
}
@@ -192,10 +192,10 @@ void WearRecoveryUI::draw_screen_locked()
gr_fill(x, y-2, gr_fb_width()-x, y+char_height_+2);
// white text of selected item
SetColor(MENU_SEL_FG);
- if (menu[i][0]) gr_text(x+4, y, menu[i], 1);
+ if (menu[i][0]) gr_text(gr_sys_font(), x+4, y, menu[i], 1);
SetColor(MENU);
- } else {
- if (menu[i][0]) gr_text(x+4, y, menu[i], 0);
+ } else if (menu[i][0]) {
+ gr_text(gr_sys_font(), x+4, y, menu[i], 0);
}
y += char_height_+4;
}
@@ -216,7 +216,7 @@ void WearRecoveryUI::draw_screen_locked()
for (int ty = gr_fb_height() - char_height_ - outer_height;
ty > y+2 && count < text_rows;
ty -= char_height_, ++count) {
- gr_text(x+4, ty, text[row], 0);
+ gr_text(gr_sys_font(), x+4, ty, text[row], 0);
--row;
if (row < 0) row = text_rows-1;
}
@@ -285,7 +285,7 @@ void WearRecoveryUI::Init()
{
gr_init();
- gr_font_size(&char_width_, &char_height_);
+ gr_font_size(gr_sys_font(), &char_width_, &char_height_);
text_col = text_row = 0;
text_rows = (gr_fb_height()) / char_height_;