diff options
author | Nicolas Geoffray <ngeoffray@google.com> | 2020-12-15 10:50:29 +0000 |
---|---|---|
committer | Nicolas Geoffray <ngeoffray@google.com> | 2021-01-11 13:56:21 +0000 |
commit | bbb00e78ef87e45ffb25b9347c648a04fac00b6e (patch) | |
tree | 7acc8eb1f95867ac3da39e2a7bde0f01bd91b957 /cmds/bootanimation/BootAnimation.h | |
parent | 73218cd5b212eef9065eed47168809ec4f97b228 (diff) |
Support for showing percent progress in boot animation.
Bug: 175686819
Test: boot with manual changes updating the progress
Change-Id: I2d936e3391f56796308c90deb39ecacc58797721
Merged-In: I2d936e3391f56796308c90deb39ecacc58797721
Diffstat (limited to 'cmds/bootanimation/BootAnimation.h')
-rw-r--r-- | cmds/bootanimation/BootAnimation.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/cmds/bootanimation/BootAnimation.h b/cmds/bootanimation/BootAnimation.h index aee385387f57..b52222c799b0 100644 --- a/cmds/bootanimation/BootAnimation.h +++ b/cmds/bootanimation/BootAnimation.h @@ -100,11 +100,13 @@ public: int fps; int width; int height; + bool progressEnabled; Vector<Part> parts; String8 audioConf; String8 fileName; ZipFileRO* zip; Font clockFont; + Font progressFont; }; // All callbacks will be called from this class's internal thread. @@ -168,6 +170,7 @@ private: bool movie(); void drawText(const char* str, const Font& font, bool bold, int* x, int* y); void drawClock(const Font& font, const int xPos, const int yPos); + void drawProgress(int percent, const Font& font, const int xPos, const int yPos); void fadeFrame(int frameLeft, int frameBottom, int frameWidth, int frameHeight, const Animation::Part& part, int fadedFramesCount); bool validClock(const Animation::Part& part); |