package zf;

import android.util.SparseIntArray;
import android.view.View;
import android.widget.Button;
import android.widget.LinearLayout;
import android.widget.TextView;
import androidx.databinding.n;
import ca.canadapost.core.common.ui.CpcFragmentContainerView;
import cg.a;

/* loaded from: classes4.dex */
public class d3 extends c3 implements a.InterfaceC0282a {
    private static final n.i J = null;
    private static final SparseIntArray K;
    private final CpcFragmentContainerView E;
    private final Button F;
    private final View.OnClickListener G;
    private final View.OnClickListener H;
    private long I;

    static {
        SparseIntArray sparseIntArray = new SparseIntArray();
        K = sparseIntArray;
        sparseIntArray.put(yf.d.f52487x, 3);
        sparseIntArray.put(yf.d.A1, 4);
    }

    public d3(androidx.databinding.e eVar, View view) {
        this(eVar, view, androidx.databinding.n.E(eVar, view, 5, J, K));
    }

    @Override // androidx.databinding.n
    public void B() {
        synchronized (this) {
            this.I = 2L;
        }
        J();
    }

    @Override // androidx.databinding.n
    protected boolean F(int i10, Object obj, int i11) {
        return false;
    }

    @Override // androidx.databinding.n
    public boolean Q(int i10, Object obj) {
        if (yf.a.f52373d != i10) {
            return false;
        }
        U((kg.d) obj);
        return true;
    }

    @Override // zf.c3
    public void U(kg.d dVar) {
        this.D = dVar;
        synchronized (this) {
            this.I |= 1;
        }
        f(yf.a.f52373d);
        super.J();
    }

    @Override // cg.a.InterfaceC0282a
    public final void a(int i10, View view) {
        if (i10 == 1) {
            kg.d dVar = this.D;
            if (dVar != null) {
                dVar.m0();
                return;
            }
            return;
        }
        if (i10 != 2) {
            return;
        }
        kg.d dVar2 = this.D;
        if (dVar2 != null) {
            dVar2.l0();
        }
    }

    @Override // androidx.databinding.n
    protected void n() {
        long j10;
        synchronized (this) {
            j10 = this.I;
            this.I = 0L;
        }
        if ((j10 & 2) != 0) {
            this.A.setOnClickListener(this.H);
            this.F.setOnClickListener(this.G);
        }
    }

    @Override // androidx.databinding.n
    public boolean z() {
        synchronized (this) {
            return this.I != 0;
        }
    }

    private d3(androidx.databinding.e eVar, View view, Object[] objArr) {
        super(eVar, view, 0, (Button) objArr[1], (LinearLayout) objArr[3], (TextView) objArr[4]);
        this.I = -1L;
        this.A.setTag(null);
        CpcFragmentContainerView cpcFragmentContainerView = (CpcFragmentContainerView) objArr[0];
        this.E = cpcFragmentContainerView;
        cpcFragmentContainerView.setTag(null);
        Button button = (Button) objArr[2];
        this.F = button;
        button.setTag(null);
        P(view);
        this.G = new cg.a(this, 2);
        this.H = new cg.a(this, 1);
        B();
    }
}
