package com.google.android.material.textfield;

import android.animation.Animator;
import android.animation.AnimatorListenerAdapter;
import android.widget.TextView;

/* JADX INFO: loaded from: classes2.dex */
public final class r extends AnimatorListenerAdapter {

    /* JADX INFO: renamed from: a, reason: collision with root package name */
    public final /* synthetic */ int f23443a;

    /* JADX INFO: renamed from: b, reason: collision with root package name */
    public final /* synthetic */ TextView f23444b;

    /* JADX INFO: renamed from: c, reason: collision with root package name */
    public final /* synthetic */ int f23445c;

    /* JADX INFO: renamed from: d, reason: collision with root package name */
    public final /* synthetic */ TextView f23446d;

    /* JADX INFO: renamed from: e, reason: collision with root package name */
    public final /* synthetic */ s f23447e;

    public r(s sVar, int i10, TextView textView, int i11, TextView textView2) {
        this.f23447e = sVar;
        this.f23443a = i10;
        this.f23444b = textView;
        this.f23445c = i11;
        this.f23446d = textView2;
    }

    @Override // android.animation.AnimatorListenerAdapter, android.animation.Animator.AnimatorListener
    public final void onAnimationEnd(Animator animator) {
        int i10 = this.f23443a;
        s sVar = this.f23447e;
        sVar.f23460m = i10;
        sVar.captionAnimator = null;
        TextView textView = this.f23444b;
        if (textView != null) {
            textView.setVisibility(4);
            if (this.f23445c == 1 && sVar.errorView != null) {
                sVar.errorView.setText((CharSequence) null);
            }
        }
        TextView textView2 = this.f23446d;
        if (textView2 != null) {
            textView2.setTranslationY(0.0f);
            textView2.setAlpha(1.0f);
        }
    }

    @Override // android.animation.AnimatorListenerAdapter, android.animation.Animator.AnimatorListener
    public final void onAnimationStart(Animator animator) {
        TextView textView = this.f23446d;
        if (textView != null) {
            textView.setVisibility(0);
            textView.setAlpha(0.0f);
        }
    }
}
