aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorElliott Hughes2015-04-13 16:36:02 -0500
committerElliott Hughes2015-04-13 17:46:15 -0500
commit8fd86d77f1a2f15c6fa95bc390bcbe646374873a (patch)
treefa39003f9127c243b686264b48d5d2671e2ce8ac /screen_ui.h
parent17b032e159779886f0151641a9aad5003debdce2 (diff)
downloadplatform-bootable-recovery-8fd86d77f1a2f15c6fa95bc390bcbe646374873a.tar.gz
platform-bootable-recovery-8fd86d77f1a2f15c6fa95bc390bcbe646374873a.tar.xz
platform-bootable-recovery-8fd86d77f1a2f15c6fa95bc390bcbe646374873a.zip
Move the menu header out of the menu.
This makes it easier for us to deal with arbitrary information at the top, and means that headers added by specific commands don't overwrite the default ones. Add the fingerprint back, but broken up so it fits even on sprout's display. Change-Id: Id71da79ab1aa455a611d72756a3100a97ceb4c1c
Diffstat (limited to 'screen_ui.h')
-rw-r--r--screen_ui.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/screen_ui.h b/screen_ui.h
index 50a45642..d473b8e9 100644
--- a/screen_ui.h
+++ b/screen_ui.h
@@ -61,7 +61,9 @@ class ScreenRecoveryUI : public RecoveryUI {
61 61
62 void Redraw(); 62 void Redraw();
63 63
64 enum UIElement { HEADER, MENU, MENU_SEL_BG, MENU_SEL_BG_ACTIVE, MENU_SEL_FG, LOG, TEXT_FILL }; 64 enum UIElement {
65 HEADER, MENU, MENU_SEL_BG, MENU_SEL_BG_ACTIVE, MENU_SEL_FG, LOG, TEXT_FILL, INFO
66 };
65 void SetColor(UIElement e); 67 void SetColor(UIElement e);
66 68
67 private: 69 private:
@@ -95,8 +97,9 @@ class ScreenRecoveryUI : public RecoveryUI {
95 bool show_text_ever; // has show_text ever been true? 97 bool show_text_ever; // has show_text ever been true?
96 98
97 char** menu; 99 char** menu;
100 const char* const* menu_headers;
98 bool show_menu; 101 bool show_menu;
99 int menu_top, menu_items, menu_sel; 102 int menu_items, menu_sel;
100 103
101 pthread_t progress_thread_; 104 pthread_t progress_thread_;
102 105
@@ -121,6 +124,8 @@ class ScreenRecoveryUI : public RecoveryUI {
121 void ClearText(); 124 void ClearText();
122 125
123 void DrawHorizontalRule(int* y); 126 void DrawHorizontalRule(int* y);
127 void DrawTextLine(int* y, const char* line, bool bold);
128 void DrawTextLines(int* y, const char* const* lines);
124 129
125 void LoadBitmap(const char* filename, gr_surface* surface); 130 void LoadBitmap(const char* filename, gr_surface* surface);
126 void LoadBitmapArray(const char* filename, int* frames, gr_surface** surface); 131 void LoadBitmapArray(const char* filename, int* frames, gr_surface** surface);