package a0;

import a0.i;
import c3.o;
import com.google.firebase.crashlytics.internal.metadata.UserMetadata;
import dn.l;
import dn.p;
import h2.e0;
import j2.g;
import kotlin.jvm.internal.t;
import kotlin.jvm.internal.v;
import rm.n0;
import y0.d4;
import y0.l2;
import y0.m;
import y0.x2;
import y0.y;

/* loaded from: classes.dex */
public abstract class a {

    /* JADX INFO: Access modifiers changed from: package-private */
    /* renamed from: a0.a$a, reason: collision with other inner class name */
    /* loaded from: classes.dex */
    public static final class C0002a extends v implements p {

        /* renamed from: p, reason: collision with root package name */
        final /* synthetic */ i f10p;

        /* renamed from: q, reason: collision with root package name */
        final /* synthetic */ dn.a f11q;

        /* renamed from: r, reason: collision with root package name */
        final /* synthetic */ l1.i f12r;

        /* renamed from: s, reason: collision with root package name */
        final /* synthetic */ l f13s;

        /* renamed from: t, reason: collision with root package name */
        final /* synthetic */ int f14t;

        /* renamed from: u, reason: collision with root package name */
        final /* synthetic */ int f15u;

        /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
        C0002a(i iVar, dn.a aVar, l1.i iVar2, l lVar, int i10, int i11) {
            super(2);
            this.f10p = iVar;
            this.f11q = aVar;
            this.f12r = iVar2;
            this.f13s = lVar;
            this.f14t = i10;
            this.f15u = i11;
        }

        public final void a(m mVar, int i10) {
            a.a(this.f10p, this.f11q, this.f12r, this.f13s, mVar, l2.a(this.f14t | 1), this.f15u);
        }

        @Override // dn.p
        public /* bridge */ /* synthetic */ Object invoke(Object obj, Object obj2) {
            a((m) obj, ((Number) obj2).intValue());
            return n0.f34904a;
        }
    }

    /* JADX INFO: Access modifiers changed from: package-private */
    /* loaded from: classes.dex */
    public static final class b extends v implements p {

        /* renamed from: p, reason: collision with root package name */
        final /* synthetic */ i f16p;

        /* renamed from: q, reason: collision with root package name */
        final /* synthetic */ dn.a f17q;

        /* renamed from: r, reason: collision with root package name */
        final /* synthetic */ l1.i f18r;

        /* renamed from: s, reason: collision with root package name */
        final /* synthetic */ l f19s;

        /* renamed from: t, reason: collision with root package name */
        final /* synthetic */ int f20t;

        /* renamed from: u, reason: collision with root package name */
        final /* synthetic */ int f21u;

        /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
        b(i iVar, dn.a aVar, l1.i iVar2, l lVar, int i10, int i11) {
            super(2);
            this.f16p = iVar;
            this.f17q = aVar;
            this.f18r = iVar2;
            this.f19s = lVar;
            this.f20t = i10;
            this.f21u = i11;
        }

        public final void a(m mVar, int i10) {
            a.a(this.f16p, this.f17q, this.f18r, this.f19s, mVar, l2.a(this.f20t | 1), this.f21u);
        }

        @Override // dn.p
        public /* bridge */ /* synthetic */ Object invoke(Object obj, Object obj2) {
            a((m) obj, ((Number) obj2).intValue());
            return n0.f34904a;
        }
    }

    /* JADX INFO: Access modifiers changed from: package-private */
    /* loaded from: classes.dex */
    public static final class c extends v implements p {

        /* renamed from: p, reason: collision with root package name */
        final /* synthetic */ i f22p;

        /* renamed from: q, reason: collision with root package name */
        final /* synthetic */ dn.a f23q;

        /* renamed from: r, reason: collision with root package name */
        final /* synthetic */ l f24r;

        /* renamed from: s, reason: collision with root package name */
        final /* synthetic */ l1.i f25s;

        /* renamed from: t, reason: collision with root package name */
        final /* synthetic */ boolean f26t;

        /* renamed from: u, reason: collision with root package name */
        final /* synthetic */ p f27u;

        /* renamed from: v, reason: collision with root package name */
        final /* synthetic */ int f28v;

        /* renamed from: w, reason: collision with root package name */
        final /* synthetic */ int f29w;

        /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
        c(i iVar, dn.a aVar, l lVar, l1.i iVar2, boolean z10, p pVar, int i10, int i11) {
            super(2);
            this.f22p = iVar;
            this.f23q = aVar;
            this.f24r = lVar;
            this.f25s = iVar2;
            this.f26t = z10;
            this.f27u = pVar;
            this.f28v = i10;
            this.f29w = i11;
        }

        public final void a(m mVar, int i10) {
            a.b(this.f22p, this.f23q, this.f24r, this.f25s, this.f26t, this.f27u, mVar, l2.a(this.f28v | 1), this.f29w);
        }

        @Override // dn.p
        public /* bridge */ /* synthetic */ Object invoke(Object obj, Object obj2) {
            a((m) obj, ((Number) obj2).intValue());
            return n0.f34904a;
        }
    }

    public static final void a(i iVar, dn.a aVar, l1.i iVar2, l lVar, m mVar, int i10, int i11) {
        int i12;
        m r10 = mVar.r(645832757);
        if ((i11 & 1) != 0) {
            i12 = i10 | 6;
        } else if ((i10 & 6) == 0) {
            i12 = (r10.R(iVar) ? 4 : 2) | i10;
        } else {
            i12 = i10;
        }
        if ((i11 & 2) != 0) {
            i12 |= 48;
        } else if ((i10 & 48) == 0) {
            i12 |= r10.m(aVar) ? 32 : 16;
        }
        int i13 = i11 & 4;
        if (i13 != 0) {
            i12 |= 384;
        } else if ((i10 & 384) == 0) {
            i12 |= r10.R(iVar2) ? 256 : 128;
        }
        if ((i11 & 8) != 0) {
            i12 |= 3072;
        } else if ((i10 & 3072) == 0) {
            i12 |= r10.m(lVar) ? 2048 : UserMetadata.MAX_ATTRIBUTE_SIZE;
        }
        if ((i12 & 1171) == 1170 && r10.v()) {
            r10.A();
        } else {
            if (i13 != 0) {
                iVar2 = l1.i.f27362a;
            }
            if (y0.p.H()) {
                y0.p.Q(645832757, i12, -1, "androidx.compose.foundation.contextmenu.ContextMenu (ContextMenuArea.android.kt:63)");
            }
            i.a a10 = iVar.a();
            if (!(a10 instanceof i.a.b)) {
                if (y0.p.H()) {
                    y0.p.P();
                }
                x2 y10 = r10.y();
                if (y10 != null) {
                    y10.a(new C0002a(iVar, aVar, iVar2, lVar, i10, i11));
                    return;
                }
                return;
            }
            boolean R = r10.R(a10);
            Object f10 = r10.f();
            if (R || f10 == m.f51621a.a()) {
                f10 = new e(o.d(((i.a.b) a10).a()), null);
                r10.I(f10);
            }
            k.d((e) f10, aVar, iVar2, lVar, r10, (i12 & 112) | (i12 & 896) | (i12 & 7168), 0);
            if (y0.p.H()) {
                y0.p.P();
            }
        }
        l1.i iVar3 = iVar2;
        x2 y11 = r10.y();
        if (y11 != null) {
            y11.a(new b(iVar, aVar, iVar3, lVar, i10, i11));
        }
    }

    /* JADX WARN: Removed duplicated region for block: B:16:0x007c  */
    /* JADX WARN: Removed duplicated region for block: B:20:0x009a  */
    /* JADX WARN: Removed duplicated region for block: B:23:0x00b5  */
    /* JADX WARN: Removed duplicated region for block: B:28:0x0192  */
    /* JADX WARN: Removed duplicated region for block: B:31:? A[RETURN, SYNTHETIC] */
    /* JADX WARN: Removed duplicated region for block: B:33:0x00c4  */
    /* JADX WARN: Removed duplicated region for block: B:36:0x00cc  */
    /* JADX WARN: Removed duplicated region for block: B:39:0x00d5  */
    /* JADX WARN: Removed duplicated region for block: B:41:0x00dd  */
    /* JADX WARN: Removed duplicated region for block: B:44:0x0108  */
    /* JADX WARN: Removed duplicated region for block: B:47:0x0114  */
    /* JADX WARN: Removed duplicated region for block: B:50:0x0137  */
    /* JADX WARN: Removed duplicated region for block: B:54:0x0187  */
    /* JADX WARN: Removed duplicated region for block: B:57:0x0118  */
    /* JADX WARN: Removed duplicated region for block: B:58:0x00e2  */
    /* JADX WARN: Removed duplicated region for block: B:59:0x00ce  */
    /* JADX WARN: Removed duplicated region for block: B:60:0x00c8  */
    /* JADX WARN: Removed duplicated region for block: B:61:0x009c  */
    /* JADX WARN: Removed duplicated region for block: B:68:0x007f  */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
    */
    public static final void b(i iVar, dn.a aVar, l lVar, l1.i iVar2, boolean z10, p pVar, m mVar, int i10, int i11) {
        int i12;
        l1.i iVar3;
        int i13;
        boolean z11;
        int a10;
        m a11;
        l1.i iVar4;
        x2 y10;
        m r10 = mVar.r(-84584070);
        if ((i11 & 1) != 0) {
            i12 = i10 | 6;
        } else if ((i10 & 6) == 0) {
            i12 = (r10.R(iVar) ? 4 : 2) | i10;
        } else {
            i12 = i10;
        }
        if ((i11 & 2) != 0) {
            i12 |= 48;
        } else if ((i10 & 48) == 0) {
            i12 |= r10.m(aVar) ? 32 : 16;
        }
        if ((i11 & 4) != 0) {
            i12 |= 384;
        } else if ((i10 & 384) == 0) {
            i12 |= r10.m(lVar) ? 256 : 128;
        }
        int i14 = i11 & 8;
        if (i14 != 0) {
            i12 |= 3072;
        } else if ((i10 & 3072) == 0) {
            iVar3 = iVar2;
            i12 |= r10.R(iVar3) ? 2048 : UserMetadata.MAX_ATTRIBUTE_SIZE;
            i13 = i11 & 16;
            if (i13 == 0) {
                i12 |= 24576;
            } else if ((i10 & 24576) == 0) {
                z11 = z10;
                i12 |= r10.c(z11) ? 16384 : UserMetadata.MAX_INTERNAL_KEY_SIZE;
                if ((i11 & 32) != 0) {
                    i12 |= 196608;
                } else if ((i10 & 196608) == 0) {
                    i12 |= r10.m(pVar) ? 131072 : 65536;
                }
                if ((74899 & i12) == 74898 || !r10.v()) {
                    l1.i iVar5 = i14 != 0 ? l1.i.f27362a : iVar3;
                    boolean z12 = i13 != 0 ? true : z11;
                    if (y0.p.H()) {
                        y0.p.Q(-84584070, i12, -1, "androidx.compose.foundation.contextmenu.ContextMenuArea (ContextMenuArea.android.kt:44)");
                    }
                    l1.i c10 = z12 ? a0.c.c(iVar5, iVar) : iVar5;
                    e0 h10 = androidx.compose.foundation.layout.b.h(l1.c.f27332a.o(), true);
                    a10 = y0.j.a(r10, 0);
                    y D = r10.D();
                    l1.i e10 = l1.h.e(r10, c10);
                    g.a aVar2 = j2.g.f23616d;
                    dn.a a12 = aVar2.a();
                    if (!(r10.w() instanceof y0.f)) {
                        y0.j.c();
                    }
                    r10.u();
                    if (r10.n()) {
                        r10.o(a12);
                    } else {
                        r10.F();
                    }
                    a11 = d4.a(r10);
                    d4.b(a11, h10, aVar2.c());
                    d4.b(a11, D, aVar2.e());
                    p b10 = aVar2.b();
                    if (!a11.n() || !t.b(a11.f(), Integer.valueOf(a10))) {
                        a11.I(Integer.valueOf(a10));
                        a11.l(Integer.valueOf(a10), b10);
                    }
                    d4.b(a11, e10, aVar2.d());
                    androidx.compose.foundation.layout.d dVar = androidx.compose.foundation.layout.d.f1828a;
                    pVar.invoke(r10, Integer.valueOf((i12 >> 15) & 14));
                    a(iVar, aVar, null, lVar, r10, (i12 & 14) | (i12 & 112) | ((i12 << 3) & 7168), 4);
                    r10.O();
                    if (y0.p.H()) {
                        y0.p.P();
                    }
                    iVar4 = iVar5;
                    z11 = z12;
                } else {
                    r10.A();
                    iVar4 = iVar3;
                }
                y10 = r10.y();
                if (y10 != null) {
                    y10.a(new c(iVar, aVar, lVar, iVar4, z11, pVar, i10, i11));
                    return;
                }
                return;
            }
            z11 = z10;
            if ((i11 & 32) != 0) {
            }
            if ((74899 & i12) == 74898) {
            }
            if (i14 != 0) {
            }
            if (i13 != 0) {
            }
            if (y0.p.H()) {
            }
            if (z12) {
            }
            e0 h102 = androidx.compose.foundation.layout.b.h(l1.c.f27332a.o(), true);
            a10 = y0.j.a(r10, 0);
            y D2 = r10.D();
            l1.i e102 = l1.h.e(r10, c10);
            g.a aVar22 = j2.g.f23616d;
            dn.a a122 = aVar22.a();
            if (!(r10.w() instanceof y0.f)) {
            }
            r10.u();
            if (r10.n()) {
            }
            a11 = d4.a(r10);
            d4.b(a11, h102, aVar22.c());
            d4.b(a11, D2, aVar22.e());
            p b102 = aVar22.b();
            if (!a11.n()) {
            }
            a11.I(Integer.valueOf(a10));
            a11.l(Integer.valueOf(a10), b102);
            d4.b(a11, e102, aVar22.d());
            androidx.compose.foundation.layout.d dVar2 = androidx.compose.foundation.layout.d.f1828a;
            pVar.invoke(r10, Integer.valueOf((i12 >> 15) & 14));
            a(iVar, aVar, null, lVar, r10, (i12 & 14) | (i12 & 112) | ((i12 << 3) & 7168), 4);
            r10.O();
            if (y0.p.H()) {
            }
            iVar4 = iVar5;
            z11 = z12;
            y10 = r10.y();
            if (y10 != null) {
            }
        }
        iVar3 = iVar2;
        i13 = i11 & 16;
        if (i13 == 0) {
        }
        z11 = z10;
        if ((i11 & 32) != 0) {
        }
        if ((74899 & i12) == 74898) {
        }
        if (i14 != 0) {
        }
        if (i13 != 0) {
        }
        if (y0.p.H()) {
        }
        if (z12) {
        }
        e0 h1022 = androidx.compose.foundation.layout.b.h(l1.c.f27332a.o(), true);
        a10 = y0.j.a(r10, 0);
        y D22 = r10.D();
        l1.i e1022 = l1.h.e(r10, c10);
        g.a aVar222 = j2.g.f23616d;
        dn.a a1222 = aVar222.a();
        if (!(r10.w() instanceof y0.f)) {
        }
        r10.u();
        if (r10.n()) {
        }
        a11 = d4.a(r10);
        d4.b(a11, h1022, aVar222.c());
        d4.b(a11, D22, aVar222.e());
        p b1022 = aVar222.b();
        if (!a11.n()) {
        }
        a11.I(Integer.valueOf(a10));
        a11.l(Integer.valueOf(a10), b1022);
        d4.b(a11, e1022, aVar222.d());
        androidx.compose.foundation.layout.d dVar22 = androidx.compose.foundation.layout.d.f1828a;
        pVar.invoke(r10, Integer.valueOf((i12 >> 15) & 14));
        a(iVar, aVar, null, lVar, r10, (i12 & 14) | (i12 & 112) | ((i12 << 3) & 7168), 4);
        r10.O();
        if (y0.p.H()) {
        }
        iVar4 = iVar5;
        z11 = z12;
        y10 = r10.y();
        if (y10 != null) {
        }
    }
}
