diff --git a/LottieUWP/Value/Keyframe.cs b/LottieUWP/Value/Keyframe.cs index fee1893..d136884 100644 --- a/LottieUWP/Value/Keyframe.cs +++ b/LottieUWP/Value/Keyframe.cs @@ -6,7 +6,8 @@ public class Keyframe { private readonly LottieComposition _composition; public T StartValue { get; } - public T EndValue { get; } + private T _endValue; + public T EndValue => _endValue == null ? StartValue : _endValue; public IInterpolator Interpolator { get; } public float? StartFrame { get; } public float? EndFrame { get; internal set; } @@ -23,7 +24,7 @@ public Keyframe(LottieComposition composition, T startValue, T endValue, IInterp { _composition = composition; StartValue = startValue; - EndValue = endValue; + _endValue = endValue; Interpolator = interpolator; StartFrame = startFrame; EndFrame = endFrame; @@ -37,7 +38,7 @@ public Keyframe(T value) { _composition = null; StartValue = value; - EndValue = value; + _endValue = value; Interpolator = null; StartFrame = float.MinValue; EndFrame = float.MaxValue;