Closed mariuspena closed 7 years ago
Hi!
Could you please try modify your createAnimator
@Nullable
@Override
public Animator createAnimator(@NonNull ViewGroup sceneRoot, @Nullable TransitionValues startValues, @Nullable TransitionValues endValues) {
Float startValue = Float.parseFloat(startValues.values.get(PROPNAME_TRANSLATIONY).toString());
Float endValue = Float.parseFloat(endValues.values.get(PROPNAME_TRANSLATIONY).toString());
startValues.view.setTranslationY(startValue);
ObjectAnimator mover = ObjectAnimator.ofFloat(startValues.view, "translationY", startValue, endValue);
return mover;
}
We are doing it in such way in all other transitions, looks like a forgot about it in TranslationTransition. So we are manually applying proper initial state.
thanks a lot! worked like a charm
Hi
It appears that setTranslationY in TranslationTransition is applied immediately and then the animation is triggered correctly. Do you have any info on this?
PS: I also wrote on your blog before thinking of this place..