summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2020-02-22 18:54:18 +0100
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2020-02-22 18:54:18 +0100
commit6a6471c8587cd4783685e20581fdd274c2cac3d2 (patch)
treea7cb2dba8a109be909a5f999319d7fcbbb60cb0b
parent[automerger skipped] Force package installation with FUSE unless the package stores on device am: ba27adbbb6 -s ours am: e00afc3fbf -s ours (diff)
parentMerge "Recovery UI meet issue if image size is too large" am: f5b94d6e9b (diff)
downloadandroid_bootable_recovery-6a6471c8587cd4783685e20581fdd274c2cac3d2.tar
android_bootable_recovery-6a6471c8587cd4783685e20581fdd274c2cac3d2.tar.gz
android_bootable_recovery-6a6471c8587cd4783685e20581fdd274c2cac3d2.tar.bz2
android_bootable_recovery-6a6471c8587cd4783685e20581fdd274c2cac3d2.tar.lz
android_bootable_recovery-6a6471c8587cd4783685e20581fdd274c2cac3d2.tar.xz
android_bootable_recovery-6a6471c8587cd4783685e20581fdd274c2cac3d2.tar.zst
android_bootable_recovery-6a6471c8587cd4783685e20581fdd274c2cac3d2.zip
-rw-r--r--recovery_ui/screen_ui.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/recovery_ui/screen_ui.cpp b/recovery_ui/screen_ui.cpp
index 087fc0e84..6dcb161fa 100644
--- a/recovery_ui/screen_ui.cpp
+++ b/recovery_ui/screen_ui.cpp
@@ -448,7 +448,9 @@ void ScreenRecoveryUI::draw_foreground_locked() {
int frame_height = gr_get_height(frame);
int frame_x = (ScreenWidth() - frame_width) / 2;
int frame_y = GetAnimationBaseline();
- DrawSurface(frame, 0, 0, frame_width, frame_height, frame_x, frame_y);
+ if (frame_x >= 0 && frame_y >= 0 && (frame_x + frame_width) < ScreenWidth() &&
+ (frame_y + frame_height) < ScreenHeight())
+ DrawSurface(frame, 0, 0, frame_width, frame_height, frame_x, frame_y);
}
if (progressBarType != EMPTY) {