package com.ss.android.ugc.aweme.relation.auth.widget.cell;

import X.AqE;
import X.C1481DaP;
import X.C4000EZw;
import X.C4004Ea0;
import X.C4213EdN;
import X.CbG;
import X.M12;
import X.QHW;
import X.QJt;
import X.Qeg;
import android.net.Uri;
import android.view.View;
import com.bytedance.covode.number.Covode;
import com.bytedance.ies.powerlist.PowerCell;
import com.ss.android.ugc.aweme.relation.auth.widget.contact.ContactMaFWidgetVM;
import kotlin.h.b.n;

public final class ContactUnRegisterCell extends PowerCell<C4004Ea0> {
    public C4213EdN LIZ;
    public CbG LIZIZ;
    public Qeg LJIIIZ;
    public Qeg LJIIJ;

    static {
        Covode.recordClassIndex(102560);
    }

    public final int bB_() {
        return 2131558556;
    }

    public final void bD_() {
        super.bD_();
        View findViewById = this.itemView.findViewById(2131362546);
        n.LIZIZ(findViewById, "");
        this.LIZ = (C4213EdN) findViewById;
        Qeg findViewById2 = this.itemView.findViewById(2131368820);
        n.LIZIZ(findViewById2, "");
        this.LJIIIZ = findViewById2;
        Qeg findViewById3 = this.itemView.findViewById(2131369976);
        n.LIZIZ(findViewById3, "");
        this.LJIIJ = findViewById3;
        CbG findViewById4 = this.itemView.findViewById(2131366134);
        n.LIZIZ(findViewById4, "");
        this.LIZIZ = findViewById4;
    }

    public final /* synthetic */ void LIZ(C1481DaP daP) {
        C4004Ea0 ea0 = (C4004Ea0) daP;
        M12.LIZ(ea0);
        super.LIZ(ea0);
        AqE aqE = ea0.LIZIZ;
        if (aqE.getPhotoUri() != null) {
            QJt LIZ2 = QHW.LIZ(Uri.parse(aqE.getPhotoUri()));
            C4213EdN edN = this.LIZ;
            if (edN == null) {
                n.LIZ("");
            }
            LIZ2.LJJIIZ = edN;
            LIZ2.LIZJ();
        } else {
            C4213EdN edN2 = this.LIZ;
            if (edN2 == null) {
                n.LIZ("");
            }
            edN2.setActualImageResource(2131232823);
        }
        Qeg qeg = this.LJIIIZ;
        if (qeg == null) {
            n.LIZ("");
        }
        qeg.setText(aqE.getContactName());
        Qeg qeg2 = this.LJIIJ;
        if (qeg2 == null) {
            n.LIZ("");
        }
        qeg2.setText(aqE.getPhoneNumber());
        if (!ea0.LIZJ) {
            CbG cbG = this.LIZIZ;
            if (cbG == null) {
                n.LIZ("");
            }
            cbG.setButtonVariant(0);
            CbG cbG2 = this.LIZIZ;
            if (cbG2 == null) {
                n.LIZ("");
            }
            cbG2.setText(2131826296);
            ContactMaFWidgetVM LIZ3 = ContactMaFWidgetVM.LJII.LIZ(ea0.LIZLLL);
            CbG cbG3 = this.LIZIZ;
            if (cbG3 == null) {
                n.LIZ("");
            }
            cbG3.setOnClickListener(new C4000EZw(LIZ3, ea0));
            return;
        }
        CbG cbG4 = this.LIZIZ;
        if (cbG4 == null) {
            n.LIZ("");
        }
        cbG4.setButtonVariant(1);
        CbG cbG5 = this.LIZIZ;
        if (cbG5 == null) {
            n.LIZ("");
        }
        cbG5.setEnabled(false);
        CbG cbG6 = this.LIZIZ;
        if (cbG6 == null) {
            n.LIZ("");
        }
        cbG6.setText(2131826313);
        CbG cbG7 = this.LIZIZ;
        if (cbG7 == null) {
            n.LIZ("");
        }
        cbG7.setOnClickListener((View.OnClickListener) null);
    }
}
