You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since v5.0.1LottieAnimationView has a simple logic to prevent onRestoreInstanceState from overriding user-provided values. Those changes were introduced in this PR.
So the issue is about progress that won't be restored if user sets a value before state restoration - same logic as for other parameters. However, the progress is always set in the view init function called from a constructor. Therefore, progress restoration is always ignored.
Progress setter:
public void setProgress(@FloatRange(from = 0f, to = 1f) float progress) {
userActionsTaken.add(UserActionTaken.SET_PROGRESS);
lottieDrawable.setProgress(progress);
}
Progress restoration:
if (!userActionsTaken.contains(UserActionTaken.SET_PROGRESS)) {
setProgress(ss.progress);
}
Describe the bug
Since v5.0.1
LottieAnimationView
has a simple logic to preventonRestoreInstanceState
from overriding user-provided values. Those changes were introduced in this PR.So the issue is about
progress
that won't be restored if user sets a value before state restoration - same logic as for other parameters. However, the progress is always set in the viewinit
function called from a constructor. Therefore, progress restoration is always ignored.Progress setter:
Progress restoration:
Setting progress in the
init
function:Steps To Reproduce
Steps to reproduce the behavior:
LottieAnimationView
proving any animation (raw resource)The text was updated successfully, but these errors were encountered: