diff options
author | Tom Marshall <tdm@cyngn.com> | 2014-11-21 16:13:22 -0800 |
---|---|---|
committer | Tom Marshall <tdm@cyngn.com> | 2015-11-25 15:35:22 -0800 |
commit | 1ac4efa02d0023b219e54af34d154122be3dbead (patch) | |
tree | aa98aa37c7f21a55000be050b92b43e68c2aa87f | |
parent | 8c0781743356e84e3b3e248d99ba09c44456bd9c (diff) | |
download | bootable_recovery-1ac4efa02d0023b219e54af34d154122be3dbead.zip bootable_recovery-1ac4efa02d0023b219e54af34d154122be3dbead.tar.gz bootable_recovery-1ac4efa02d0023b219e54af34d154122be3dbead.tar.bz2 |
recovery: New icon type VIEWING_LOG
* Fixes "View recovery logs"
This is probably not the best solution, perhaps find a different way?
Change-Id: Ibd901ce7f69ec05c4d26cdb027e51b7e5b826034
-rw-r--r-- | screen_ui.cpp | 4 | ||||
-rw-r--r-- | ui.h | 2 |
2 files changed, 4 insertions, 2 deletions
diff --git a/screen_ui.cpp b/screen_ui.cpp index f5c4916..5ed74a6 100644 --- a/screen_ui.cpp +++ b/screen_ui.cpp @@ -350,7 +350,7 @@ void ScreenRecoveryUI::draw_screen_locked() { gr_color(0, 0, 0, 255); gr_clear(); - if (currentIcon == INSTALLING_UPDATE) { + if (currentIcon == INSTALLING_UPDATE || currentIcon == VIEWING_LOG) { size_t y = header_height_ + 4; draw_background_locked(currentIcon); @@ -688,6 +688,8 @@ void ScreenRecoveryUI::ShowFile(FILE* fp) { offsets.push_back(ftell(fp)); ClearText(); + SetBackground(RecoveryUI::VIEWING_LOG); + struct stat sb; fstat(fileno(fp), &sb); @@ -106,7 +106,7 @@ class RecoveryUI { virtual void SetLocale(const char* locale) = 0; // Set the overall recovery state ("background image"). - enum Icon { NONE, INSTALLING_UPDATE, ERASING, NO_COMMAND, D_INFO, D_ERROR, NR_ICONS }; + enum Icon { NONE, INSTALLING_UPDATE, VIEWING_LOG, ERASING, NO_COMMAND, D_INFO, D_ERROR, NR_ICONS }; virtual void SetBackground(Icon icon) = 0; // --- progress indicator --- |