From a12987512cd5712411a3279c14f173abdd55ad49 Mon Sep 17 00:00:00 2001 From: Nicolas Geoffray Date: Tue, 20 Apr 2021 15:15:06 +0100 Subject: bootanimation: ensure that if a percent is shown, we'll get to 100. Seeing 100 while booting is not finished, or seeing eg 90 while booting is not finished isn't user-friendly. Test: update ART module, see percent progress Change-Id: I5509c83f661f937f00a7d28c789df509e3528a37 --- cmds/bootanimation/BootAnimation.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'cmds/bootanimation/BootAnimation.h') diff --git a/cmds/bootanimation/BootAnimation.h b/cmds/bootanimation/BootAnimation.h index b52222c799b0..1b47fefc6866 100644 --- a/cmds/bootanimation/BootAnimation.h +++ b/cmds/bootanimation/BootAnimation.h @@ -187,7 +187,8 @@ private: void resizeSurface(int newWidth, int newHeight); void projectSceneToWindow(); - bool shouldStopPlayingPart(const Animation::Part& part, int fadedFramesCount); + bool shouldStopPlayingPart(const Animation::Part& part, int fadedFramesCount, + int lastDisplayedProgress); void checkExit(); void handleViewport(nsecs_t timestep); -- cgit v1.2.3-59-g8ed1b