package o;

import android.view.View;
import com.google.android.gms.common.R;
import java.util.Set;

/* compiled from: r8-map-id-3b7cc9102578c509342fa2f0fabed2bfc72239cd258d579fc679bfcbc198b048 */
/* loaded from: classes.dex */
public final class Pm0 extends AbstractC0706aK implements SC {
    public final /* synthetic */ int m;
    public final /* synthetic */ Qm0 n;

    /* renamed from: o, reason: collision with root package name */
    public final /* synthetic */ SC f288o;

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public /* synthetic */ Pm0(Qm0 qm0, SC sc, int i) {
        super(2);
        this.m = i;
        this.n = qm0;
        this.f288o = sc;
    }

    @Override // o.SC
    public final Object f(Object obj, Object obj2) {
        switch (this.m) {
            case 0:
                C0321Mk c0321Mk = (C0321Mk) obj;
                int iIntValue = ((Number) obj2).intValue();
                if (c0321Mk.N(iIntValue & 1, (iIntValue & 3) != 2)) {
                    N3.a(this.n.l, this.f288o, c0321Mk, 0);
                } else {
                    c0321Mk.Q();
                }
                break;
            default:
                C0321Mk c0321Mk2 = (C0321Mk) obj;
                int iIntValue2 = ((Number) obj2).intValue();
                if (c0321Mk2.N(iIntValue2 & 1, (iIntValue2 & 3) != 2)) {
                    Qm0 qm0 = this.n;
                    C2207q3 c2207q3 = qm0.l;
                    Object tag = c2207q3.getTag(R.id.inspection_slot_table_set);
                    InterfaceC0220Im interfaceC0220Im = null;
                    Set set = (!(tag instanceof Set) || ((tag instanceof InterfaceC2989yJ) && !(tag instanceof BJ))) ? null : (Set) tag;
                    if (set == null) {
                        Object parent = c2207q3.getParent();
                        View view = parent instanceof View ? (View) parent : null;
                        Object tag2 = view != null ? view.getTag(R.id.inspection_slot_table_set) : null;
                        set = (!(tag2 instanceof Set) || ((tag2 instanceof InterfaceC2989yJ) && !(tag2 instanceof BJ))) ? null : (Set) tag2;
                    }
                    if (set != null) {
                        C0477Sk c0477Sk = c0321Mk2.S;
                        if (c0477Sk == null) {
                            c0477Sk = new C0477Sk(c0321Mk2.g);
                            c0321Mk2.S = c0477Sk;
                        }
                        set.add(c0477Sk);
                        c0321Mk2.p = true;
                        c0321Mk2.B = true;
                        c0321Mk2.c.b();
                        c0321Mk2.G.b();
                        C1365h90 c1365h90 = c0321Mk2.H;
                        C1077e90 c1077e90 = c1365h90.a;
                        c1365h90.e = c1077e90.u;
                        c1365h90.f = c1077e90.v;
                    }
                    boolean zH = c0321Mk2.h(qm0);
                    Object objK = c0321Mk2.K();
                    J7 j7 = C0140Fk.a;
                    if (zH || objK == j7) {
                        objK = new Om0(qm0, interfaceC0220Im, 0);
                        c0321Mk2.f0(objK);
                    }
                    AbstractC0249Jp.g(c2207q3, c0321Mk2, (SC) objK);
                    boolean zH2 = c0321Mk2.h(qm0);
                    Object objK2 = c0321Mk2.K();
                    if (zH2 || objK2 == j7) {
                        objK2 = new Om0(qm0, interfaceC0220Im, 1);
                        c0321Mk2.f0(objK2);
                    }
                    AbstractC0249Jp.g(c2207q3, c0321Mk2, (SC) objK2);
                    AbstractC2841wm0.b(TH.a.a(set), C2887xC.y(-280240369, new Pm0(qm0, this.f288o, 0), c0321Mk2), c0321Mk2, 56);
                } else {
                    c0321Mk2.Q();
                }
                break;
        }
        return Oh0.a;
    }
}
