package com.airbnb.lottie.animation.keyframe; import com.airbnb.lottie.model.DocumentData; import com.airbnb.lottie.value.Keyframe; import com.airbnb.lottie.value.LottieFrameInfo; import com.airbnb.lottie.value.LottieValueCallback; import java.util.List; /* loaded from: classes2.dex */ public class TextKeyframeAnimation extends KeyframeAnimation { @Override // com.airbnb.lottie.animation.keyframe.BaseKeyframeAnimation /* bridge */ /* synthetic */ Object getValue(Keyframe keyframe, float f) { return getValue((Keyframe) keyframe, f); } public TextKeyframeAnimation(List> list) { super(list); } @Override // com.airbnb.lottie.animation.keyframe.BaseKeyframeAnimation DocumentData getValue(Keyframe keyframe, float f) { if (this.valueCallback != null) { return (DocumentData) this.valueCallback.getValueInternal(keyframe.startFrame, keyframe.endFrame == null ? Float.MAX_VALUE : keyframe.endFrame.floatValue(), keyframe.startValue, keyframe.endValue == null ? keyframe.startValue : keyframe.endValue, f, getInterpolatedCurrentKeyframeProgress(), getProgress()); } if (f != 1.0f || keyframe.endValue == null) { return keyframe.startValue; } return keyframe.endValue; } public void setStringValueCallback(final LottieValueCallback lottieValueCallback) { final LottieFrameInfo lottieFrameInfo = new LottieFrameInfo(); final DocumentData documentData = new DocumentData(); super.setValueCallback(new LottieValueCallback() { // from class: com.airbnb.lottie.animation.keyframe.TextKeyframeAnimation.1 /* JADX WARN: Can't rename method to resolve collision */ @Override // com.airbnb.lottie.value.LottieValueCallback public DocumentData getValue(LottieFrameInfo lottieFrameInfo2) { lottieFrameInfo.set(lottieFrameInfo2.getStartFrame(), lottieFrameInfo2.getEndFrame(), lottieFrameInfo2.getStartValue().text, lottieFrameInfo2.getEndValue().text, lottieFrameInfo2.getLinearKeyframeProgress(), lottieFrameInfo2.getInterpolatedKeyframeProgress(), lottieFrameInfo2.getOverallProgress()); String str = (String) lottieValueCallback.getValue(lottieFrameInfo); DocumentData endValue = lottieFrameInfo2.getInterpolatedKeyframeProgress() == 1.0f ? lottieFrameInfo2.getEndValue() : lottieFrameInfo2.getStartValue(); documentData.set(str, endValue.fontName, endValue.size, endValue.justification, endValue.tracking, endValue.lineHeight, endValue.baselineShift, endValue.color, endValue.strokeColor, endValue.strokeWidth, endValue.strokeOverFill, endValue.boxPosition, endValue.boxSize); return documentData; } }); } }