package K;

import B.C0053c;
import B.f1;
import B.h1;
import C0.C0109j;
import C0.C0124z;
import D.C0135f;
import F1.C0180i;
import M2.AbstractC0504e;
import M2.C0556x0;
import T0.AbstractC0602m;
import T0.C0594e;
import T0.C0596g;
import T0.C0604o;
import V2.AbstractC0693m0;
import V2.C0736x;
import V2.C0745z0;
import V2.R2;
import V4.InterfaceC0765i0;
import X0.AbstractC0808v;
import Z0.C0860a;
import a0.x2;
import android.R;
import android.app.RemoteAction;
import android.content.Context;
import android.content.res.Resources;
import android.graphics.drawable.Drawable;
import android.os.Build;
import android.view.ViewGroup;
import android.view.textclassifier.TextClassification;
import android.webkit.CookieManager;
import android.webkit.WebChromeClient;
import android.webkit.WebView;
import android.webkit.WebViewClient;
import androidx.compose.runtime.DisposableEffectScope;
import androidx.compose.runtime.MutableIntState;
import androidx.compose.runtime.MutableState;
import androidx.compose.runtime.State;
import androidx.compose.runtime.internal.ComposableLambdaKt;
import androidx.lifecycle.InterfaceC1113w;
import androidx.media3.extractor.AacUtil;
import androidx.media3.extractor.flac.FlacConstants;
import androidx.media3.extractor.ts.TsExtractor;
import b1.C1187b;
import c0.C1218s;
import coil.compose.AsyncImagePainter;
import coil.compose.UtilsKt;
import com.debridstream.tv.HomeSection;
import com.debridstream.tv.ProfileViewModel;
import com.google.firebase.firestore.index.FirestoreIndexValueWriter;
import d.AbstractActivityC1833l;
import f1.C2013a;
import f1.C2024l;
import f1.C2026n;
import f1.C2028p;
import f1.InterfaceC2027o;
import h3.AbstractC2190s4;
import h3.C2099d2;
import h3.C2209w;
import h3.EnumC2203v;
import h3.Z1;
import h3.o5;
import h3.p5;
import i0.InterfaceC2240d;
import j3.C2359k;
import java.util.List;
import java.util.concurrent.atomic.AtomicBoolean;
import n2.AbstractC2612c;
import o0.C2632c;
import p0.AbstractC2711q;
import p0.C2714u;
import p0.InterfaceC2712s;
import q.AbstractC2761L;
import q.C2785l;
import r0.C2863b;
import r0.InterfaceC2864c;
import r0.InterfaceC2866e;
import u0.AbstractC2959b;
import w.AbstractC3130b;
import w.C3132d;
import w4.C3137A;
import x.C3158e1;
import x.C3167h1;
import x.C3171j;
import x.L1;

/* JADX INFO: renamed from: K.l, reason: case insensitive filesystem */
/* JADX INFO: loaded from: classes.dex */
public final /* synthetic */ class C0463l implements J4.c {

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

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

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

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

    public /* synthetic */ C0463l(Object obj, Object obj2, J4.c cVar, int i6) {
        this.f3883a = i6;
        this.f3885c = obj;
        this.f3886d = obj2;
        this.f3884b = cVar;
    }

    private final Object a(Object obj) {
        if (((Float) obj).floatValue() == 0.0f && ((Boolean) ((State) this.f3885c).getValue()).booleanValue() && kotlin.jvm.internal.o.c((String) ((State) this.f3886d).getValue(), "main_tabs")) {
            ((ProfileViewModel) this.f3884b).onProfileEntryBufferRevealFinished();
        }
        return C3137A.f25453a;
    }

    private final Object b(Object obj) {
        R2 profile = (R2) obj;
        kotlin.jvm.internal.o.h(profile, "profile");
        q.F0 f0 = AbstractC0693m0.f7892a;
        if (((C0745z0) ((State) this.f3886d).getValue()).f8199a != null) {
            ((ProfileViewModel) this.f3884b).requestProfilePickerAutoSelect(profile.f7513a);
            ((androidx.navigation.H) this.f3885c).m("profile_selector", new C0736x(11));
        }
        return C3137A.f25453a;
    }

    /* JADX WARN: Multi-variable type inference failed */
    private final Object c(Object obj) {
        C2785l c2785l = (C2785l) obj;
        float fFloatValue = ((Number) c2785l.f23381e.getValue()).floatValue();
        kotlin.jvm.internal.z zVar = (kotlin.jvm.internal.z) this.f3884b;
        float f6 = fFloatValue - zVar.f20131a;
        x2 x2Var = (x2) this.f3885c;
        float floatValue = x2Var.f10328c.getFloatValue();
        x2Var.b(floatValue + f6);
        float fAbs = Math.abs(floatValue - x2Var.f10328c.getFloatValue());
        zVar.f20131a = ((Number) c2785l.f23381e.getValue()).floatValue();
        ((kotlin.jvm.internal.z) this.f3886d).f20131a = ((Number) c2785l.f23377a.f23172b.invoke(c2785l.f23382f)).floatValue();
        if (Math.abs(f6 - fAbs) > 0.5f) {
            c2785l.a();
        }
        return C3137A.f25453a;
    }

    private final Object d(Object obj) {
        InterfaceC2864c interfaceC2864c = (InterfaceC2864c) obj;
        long j4 = ((o0.e) ((C1218s) this.f3884b).get()).f21799a;
        float fIntBitsToFloat = Float.intBitsToFloat((int) (j4 >> 32));
        if (fIntBitsToFloat > 0.0f) {
            I0.J j6 = (I0.J) interfaceC2864c;
            float fY = j6.Y(a0.M0.f9547a);
            h1.m layoutDirection = j6.getLayoutDirection();
            B.J0 j02 = (B.J0) this.f3885c;
            float fY2 = j6.Y(j02.b(layoutDirection));
            float fY3 = j6.Y(j02.d(j6.getLayoutDirection()));
            int iD0 = L4.a.d0(fIntBitsToFloat);
            C2863b c2863b = j6.f2210a;
            float fA = ((InterfaceC2240d) this.f3886d).a(iD0, L4.a.d0((Float.intBitsToFloat((int) (c2863b.c() >> 32)) - fY2) - fY3), j6.getLayoutDirection()) + fY2;
            float f6 = 2;
            float f7 = fIntBitsToFloat / f6;
            float f8 = fA + f7;
            float f9 = (f8 - f7) - fY;
            float f10 = f9 < 0.0f ? 0.0f : f9;
            float f11 = f8 + f7 + fY;
            float fIntBitsToFloat2 = Float.intBitsToFloat((int) (c2863b.c() >> 32));
            float f12 = f11 > fIntBitsToFloat2 ? fIntBitsToFloat2 : f11;
            float fIntBitsToFloat3 = Float.intBitsToFloat((int) (j4 & 4294967295L));
            float f13 = (-fIntBitsToFloat3) / f6;
            float f14 = fIntBitsToFloat3 / f6;
            o4.f fVar = c2863b.f23803b;
            long jF = fVar.f();
            fVar.c().f();
            try {
                ((o4.f) ((l2.c) fVar.f21850c).f20267b).c().o(f10, f13, f12, f14, 0);
                j6.b();
            } finally {
                AbstractC2761L.o(fVar, jF);
            }
        } else {
            ((I0.J) interfaceC2864c).b();
        }
        return C3137A.f25453a;
    }

    private final Object e(Object obj) {
        DisposableEffectScope DisposableEffect = (DisposableEffectScope) obj;
        kotlin.jvm.internal.o.h(DisposableEffect, "$this$DisposableEffect");
        AbstractActivityC1833l abstractActivityC1833l = (AbstractActivityC1833l) this.f3884b;
        if (abstractActivityC1833l == null) {
            return new a3.f0();
        }
        C0180i c0180i = new C0180i(1, (a3.a0) this.f3885c, (State) this.f3886d);
        abstractActivityC1833l.getLifecycle().addObserver(c0180i);
        return new f1(6, abstractActivityC1833l, c0180i);
    }

    private final Object f(Object obj) {
        return UtilsKt.onStateOf$lambda$5((J4.c) this.f3884b, (J4.c) this.f3885c, (J4.c) this.f3886d, (AsyncImagePainter.State) obj);
    }

    private final Object g(Object obj) {
        return UtilsKt.transformOf$lambda$4((AbstractC2959b) this.f3884b, (AbstractC2959b) this.f3885c, (AbstractC2959b) this.f3886d, (AsyncImagePainter.State) obj);
    }

    private final Object h(Object obj) {
        n0.q focusProperties = (n0.q) obj;
        kotlin.jvm.internal.o.h(focusProperties, "$this$focusProperties");
        n0.x xVar = (n0.x) this.f3884b;
        focusProperties.i(xVar);
        focusProperties.b(xVar);
        focusProperties.e(xVar);
        if (!((List) ((MutableState) this.f3885c).getValue()).isEmpty()) {
            List list = (List) this.f3886d;
            if (!list.isEmpty()) {
                xVar = (n0.x) list.get(0);
            }
        }
        focusProperties.g(xVar);
        return C3137A.f25453a;
    }

    private final Object i(Object obj) {
        DisposableEffectScope DisposableEffect = (DisposableEffectScope) obj;
        kotlin.jvm.internal.o.h(DisposableEffect, "$this$DisposableEffect");
        C0180i c0180i = new C0180i(3, (State) this.f3885c, (AtomicBoolean) this.f3886d);
        InterfaceC1113w interfaceC1113w = (InterfaceC1113w) this.f3884b;
        interfaceC1113w.getLifecycle().addObserver(c0180i);
        return new f1(7, interfaceC1113w, c0180i);
    }

    private final Object j(Object obj) {
        n0.q focusProperties = (n0.q) obj;
        kotlin.jvm.internal.o.h(focusProperties, "$this$focusProperties");
        n0.x xVar = (n0.x) this.f3884b;
        focusProperties.i(xVar);
        focusProperties.b(xVar);
        focusProperties.e((n0.x) ((List) this.f3885c).get(0));
        focusProperties.g((n0.x) ((List) this.f3886d).get(0));
        return C3137A.f25453a;
    }

    /* JADX WARN: Multi-variable type inference failed */
    private final Object k(Object obj) {
        InterfaceC2866e drawBehind = (InterfaceC2866e) obj;
        kotlin.jvm.internal.o.h(drawBehind, "$this$drawBehind");
        if (((o5) ((MutableState) this.f3885c).getValue()) == o5.f18370b) {
            InterfaceC2866e.E(drawBehind, (AbstractC2711q) this.f3884b, 0L, 0L, L4.a.u(((Number) ((MutableState) this.f3886d).getValue()).floatValue(), 0.0f, 1.0f), null, 118);
        }
        return C3137A.f25453a;
    }

    /* JADX WARN: Multi-variable type inference failed */
    private final Object l(Object obj) {
        String it = (String) obj;
        kotlin.jvm.internal.o.h(it, "it");
        String strM1 = S4.p.m1(4, it);
        MutableState mutableState = (MutableState) this.f3885c;
        mutableState.setValue(strM1);
        ((MutableState) this.f3886d).setValue(null);
        if (((String) mutableState.getValue()).length() == 4) {
            ((J4.a) this.f3884b).invoke();
        }
        return C3137A.f25453a;
    }

    private final Object m(Object obj) {
        String name = (String) obj;
        kotlin.jvm.internal.o.h(name, "name");
        ((J4.e) this.f3884b).invoke(((R2) this.f3886d).f7513a, name);
        w4.p pVar = Z1.f17674a;
        ((MutableState) this.f3885c).setValue(null);
        return C3137A.f25453a;
    }

    private final Object n(Object obj) {
        Context ctx = (Context) obj;
        kotlin.jvm.internal.o.h(ctx, "ctx");
        WebView webView = new WebView(ctx);
        webView.setLayoutParams(new ViewGroup.LayoutParams(-1, -1));
        float f6 = AbstractC2190s4.f18484a;
        CookieManager cookieManager = CookieManager.getInstance();
        cookieManager.setAcceptCookie(true);
        cookieManager.setAcceptThirdPartyCookies(webView, true);
        webView.getSettings().setJavaScriptEnabled(true);
        webView.getSettings().setDomStorageEnabled(true);
        webView.getSettings().setMediaPlaybackRequiresUserGesture(false);
        webView.getSettings().setUseWideViewPort(true);
        webView.getSettings().setLoadWithOverviewMode(true);
        webView.getSettings().setBuiltInZoomControls(false);
        webView.getSettings().setDisplayZoomControls(false);
        webView.getSettings().setAllowContentAccess(true);
        webView.getSettings().setAllowFileAccess(false);
        webView.getSettings().setMixedContentMode(1);
        webView.getSettings().setUserAgentString("Mozilla/5.0 (Linux; Android 13; Smart-TV) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36");
        webView.setFocusable(true);
        webView.setFocusableInTouchMode(true);
        webView.addJavascriptInterface((p5) this.f3884b, "TrailerBridge");
        webView.setWebViewClient(new WebViewClient());
        webView.setWebChromeClient(new WebChromeClient());
        webView.loadDataWithBaseURL((String) this.f3885c, (String) this.f3886d, "text/html", "utf-8", null);
        webView.onResume();
        webView.requestFocus();
        return webView;
    }

    private final Object o(Object obj) {
        DisposableEffectScope DisposableEffect = (DisposableEffectScope) obj;
        kotlin.jvm.internal.o.h(DisposableEffect, "$this$DisposableEffect");
        C0180i c0180i = new C0180i(4, (C2359k) this.f3885c, (J4.a) this.f3886d);
        InterfaceC1113w interfaceC1113w = (InterfaceC1113w) this.f3884b;
        interfaceC1113w.getLifecycle().addObserver(c0180i);
        return new f1(12, interfaceC1113w, c0180i);
    }

    /* JADX WARN: Can't fix incorrect switch cases order, some code will duplicate */
    /* JADX WARN: Multi-variable type inference failed */
    /* JADX WARN: Removed duplicated region for block: B:440:0x0a17  */
    /* JADX WARN: Type inference failed for: r9v18, types: [java.lang.Object, java.util.Collection, java.util.List] */
    @Override // J4.c
    /*
        Code decompiled incorrectly, please refer to instructions dump.
    */
    public final Object invoke(Object obj) throws Throwable {
        InterfaceC2712s interfaceC2712s;
        C0594e c0594e;
        Integer numE;
        Integer numD;
        Integer numD2;
        Integer numE2;
        T0.L l;
        T0.L l6;
        S0 s02;
        S0 s03;
        T0.L l7;
        T0.L l8;
        S0 s04;
        S0 s05;
        Integer numD3;
        Integer numE3;
        Integer numE4;
        Integer numD4;
        Z0.y yVar;
        T.p pVar;
        Z0.y yVar2;
        T0.M mA;
        T0.M mA2;
        T0.M mA3;
        C0464l0 c0464l0;
        int i6 = 13;
        int i7 = 3;
        int i8 = 7;
        int i9 = 6;
        int i10 = 4;
        int i11 = 2;
        Object obj2 = null;
        int i12 = 16;
        int i13 = 0;
        C3137A c3137a = C3137A.f25453a;
        Object obj3 = this.f3885c;
        Object obj4 = this.f3886d;
        Object obj5 = this.f3884b;
        int i14 = 1;
        switch (this.f3883a) {
            case 0:
                Z0.y yVar3 = (Z0.y) obj;
                ((MutableState) obj3).setValue(yVar3);
                MutableState mutableState = (MutableState) obj4;
                boolean zC = kotlin.jvm.internal.o.c((String) mutableState.getValue(), yVar3.f9136a.f6510b);
                C0596g c0596g = yVar3.f9136a;
                mutableState.setValue(c0596g.f6510b);
                if (!zC) {
                    ((J4.c) obj5).invoke(c0596g.f6510b);
                }
                return c3137a;
            case 1:
                InterfaceC2866e interfaceC2866e = (InterfaceC2866e) obj;
                C0464l0 c0464l02 = (C0464l0) obj5;
                S0 s0D = c0464l02.d();
                if (s0D != null) {
                    InterfaceC2712s interfaceC2712sC = interfaceC2866e.a0().c();
                    long j4 = ((T0.N) c0464l02.f3887A.getValue()).f6483a;
                    long j6 = ((T0.N) c0464l02.f3888B.getValue()).f6483a;
                    long j7 = c0464l02.f3913z;
                    boolean zC2 = T0.N.c(j4);
                    T0.L l9 = s0D.f3742a;
                    I2.O o6 = c0464l02.f3912y;
                    Z0.r rVar = (Z0.r) obj4;
                    T0.K k6 = l9.f6471a;
                    if (!zC2) {
                        o6.g(j7);
                        int iB = rVar.b(T0.N.f(j4));
                        int iB2 = rVar.b(T0.N.e(j4));
                        if (iB != iB2) {
                            interfaceC2712sC.k(l9.h(iB, iB2), o6);
                        }
                    } else if (T0.N.c(j6)) {
                        long j8 = ((Z0.y) obj3).f9137b;
                        if (!T0.N.c(j8)) {
                            o6.g(j7);
                            int iB3 = rVar.b(T0.N.f(j8));
                            int iB4 = rVar.b(T0.N.e(j8));
                            if (iB3 != iB4) {
                                interfaceC2712sC.k(l9.h(iB3, iB4), o6);
                            }
                        }
                    } else {
                        long jB = k6.f6462b.b();
                        C2714u c2714u = new C2714u(jB);
                        if (jB == 16) {
                            c2714u = null;
                        }
                        long j9 = c2714u != null ? c2714u.f22947a : C2714u.f22935b;
                        o6.g(C2714u.c(C2714u.e(j9) * 0.2f, j9));
                        int iB5 = rVar.b(T0.N.f(j6));
                        int iB6 = rVar.b(T0.N.e(j6));
                        if (iB5 != iB6) {
                            interfaceC2712sC.k(l9.h(iB5, iB6), o6);
                        }
                    }
                    long j10 = l9.f6473c;
                    float f6 = (int) (j10 >> 32);
                    C0604o c0604o = l9.f6472b;
                    boolean z6 = ((f6 > c0604o.f6535d ? 1 : (f6 == c0604o.f6535d ? 0 : -1)) < 0 || c0604o.f6534c || (((float) ((int) (j10 & 4294967295L))) > c0604o.f6536e ? 1 : (((float) ((int) (j10 & 4294967295L))) == c0604o.f6536e ? 0 : -1)) < 0) && k6.f6466f != 3;
                    if (z6) {
                        C2632c c2632cB = m1.g.b(0L, (((long) Float.floatToRawIntBits((int) (j10 & 4294967295L))) & 4294967295L) | (((long) Float.floatToRawIntBits((int) (j10 >> 32))) << 32));
                        interfaceC2712sC.f();
                        InterfaceC2712s.d(interfaceC2712sC, c2632cB);
                    }
                    T0.G g6 = k6.f6462b.f6485a;
                    C2024l c2024l = g6.f6450m;
                    InterfaceC2027o interfaceC2027o = g6.f6439a;
                    if (c2024l == null) {
                        c2024l = C2024l.f16386b;
                    }
                    C2024l c2024l2 = c2024l;
                    p0.W w6 = g6.f6451n;
                    if (w6 == null) {
                        w6 = p0.W.f22883d;
                    }
                    p0.W w7 = w6;
                    r0.f fVar = g6.f6453p;
                    if (fVar == null) {
                        fVar = r0.h.f23808a;
                    }
                    r0.f fVar2 = fVar;
                    try {
                        AbstractC2711q abstractC2711qB = interfaceC2027o.b();
                        C2026n c2026n = C2026n.f16391a;
                        try {
                            if (abstractC2711qB != null) {
                                interfaceC2712s = interfaceC2712sC;
                                C0604o.j(c0604o, interfaceC2712s, abstractC2711qB, interfaceC2027o != c2026n ? interfaceC2027o.getAlpha() : 1.0f, w7, c2024l2, fVar2);
                            } else {
                                interfaceC2712s = interfaceC2712sC;
                                C0604o.i(c0604o, interfaceC2712s, interfaceC2027o != c2026n ? interfaceC2027o.a() : C2714u.f22935b, w7, c2024l2, fVar2);
                            }
                            if (z6) {
                                interfaceC2712s.r();
                            }
                        } catch (Throwable th) {
                            th = th;
                            if (z6) {
                                interfaceC2712sC.r();
                            }
                            throw th;
                        }
                    } catch (Throwable th2) {
                        th = th2;
                    }
                }
                return c3137a;
            case 2:
                C0594e c0594e2 = (C0594e) obj;
                kotlin.jvm.internal.y yVar4 = (kotlin.jvm.internal.y) obj5;
                C0594e c0594e3 = (C0594e) obj3;
                if (yVar4.f20130a && (c0594e2.f6503a instanceof T0.G)) {
                    int i15 = c0594e3.f6504b;
                    int i16 = c0594e2.f6504b;
                    if (i16 == i15) {
                        int i17 = c0594e3.f6505c;
                        int i18 = c0594e2.f6505c;
                        if (i18 == i17) {
                            T0.G g7 = (T0.G) obj4;
                            if (g7 == null) {
                                g7 = new T0.G(0L, 0L, (X0.I) null, (X0.C) null, (X0.D) null, (AbstractC0808v) null, (String) null, 0L, (C2013a) null, (C2028p) null, (C1187b) null, 0L, (C2024l) null, (p0.W) null, 65535);
                            }
                            c0594e = new C0594e(i16, i18, g7);
                        }
                    }
                } else {
                    c0594e = c0594e2;
                }
                yVar4.f20130a = c0594e3.equals(c0594e2);
                return c0594e;
            case 3:
                Z0.E e6 = (Z0.E) ((kotlin.jvm.internal.C) obj4).f20115a;
                Z0.y yVarJ = ((T.p) obj5).j((List) obj);
                if (e6 != null) {
                    e6.a(null, yVarJ);
                }
                ((C0490z) obj3).invoke(yVarJ);
                return c3137a;
            case 4:
                V.W w8 = (V.W) obj;
                kotlin.jvm.internal.y yVar5 = (kotlin.jvm.internal.y) obj4;
                E0 e0 = (E0) obj3;
                switch (((EnumC0446c0) obj5).ordinal()) {
                    case 0:
                        w8.f7011e.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            if (T0.N.c(w8.f7012f)) {
                                w8.i();
                            } else if (w8.f()) {
                                int iF = T0.N.f(w8.f7012f);
                                w8.q(iF, iF);
                            } else {
                                int iE = T0.N.e(w8.f7012f);
                                w8.q(iE, iE);
                            }
                        }
                        return c3137a;
                    case 1:
                        w8.f7011e.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            if (T0.N.c(w8.f7012f)) {
                                w8.m();
                            } else if (w8.f()) {
                                int iE2 = T0.N.e(w8.f7012f);
                                w8.q(iE2, iE2);
                            } else {
                                int iF2 = T0.N.f(w8.f7012f);
                                w8.q(iF2, iF2);
                            }
                        }
                        return c3137a;
                    case 2:
                        V.r0 r0Var = w8.f7011e;
                        r0Var.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            if (w8.f()) {
                                r0Var.f7152a = null;
                                if (w8.f7013g.f6510b.length() > 0 && (numD = w8.d()) != null) {
                                    int iIntValue = numD.intValue();
                                    w8.q(iIntValue, iIntValue);
                                }
                            } else {
                                r0Var.f7152a = null;
                                if (w8.f7013g.f6510b.length() > 0 && (numE = w8.e()) != null) {
                                    int iIntValue2 = numE.intValue();
                                    w8.q(iIntValue2, iIntValue2);
                                }
                            }
                        }
                        return c3137a;
                    case 3:
                        V.r0 r0Var2 = w8.f7011e;
                        r0Var2.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            if (w8.f()) {
                                r0Var2.f7152a = null;
                                if (w8.f7013g.f6510b.length() > 0 && (numE2 = w8.e()) != null) {
                                    int iIntValue3 = numE2.intValue();
                                    w8.q(iIntValue3, iIntValue3);
                                }
                            } else {
                                r0Var2.f7152a = null;
                                if (w8.f7013g.f6510b.length() > 0 && (numD2 = w8.d()) != null) {
                                    int iIntValue4 = numD2.intValue();
                                    w8.q(iIntValue4, iIntValue4);
                                }
                            }
                        }
                        return c3137a;
                    case 4:
                        w8.j();
                        return c3137a;
                    case 5:
                        w8.l();
                        return c3137a;
                    case 6:
                        w8.o();
                        return c3137a;
                    case 7:
                        w8.n();
                        return c3137a;
                    case 8:
                        w8.f7011e.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            if (w8.f()) {
                                w8.o();
                            } else {
                                w8.n();
                            }
                        }
                        return c3137a;
                    case 9:
                        w8.f7011e.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            if (w8.f()) {
                                w8.n();
                            } else {
                                w8.o();
                            }
                        }
                        return c3137a;
                    case 10:
                        if (w8.f7013g.f6510b.length() > 0 && (l = w8.f7009c) != null) {
                            int iG = w8.g(l, -1);
                            w8.q(iG, iG);
                        }
                        return c3137a;
                    case 11:
                        if (w8.f7013g.f6510b.length() > 0 && (l6 = w8.f7009c) != null) {
                            int iG2 = w8.g(l6, 1);
                            w8.q(iG2, iG2);
                        }
                        return c3137a;
                    case 12:
                    case 48:
                        return c3137a;
                    case 13:
                        if (w8.f7013g.f6510b.length() > 0 && (s02 = w8.f7015i) != null) {
                            int iH = w8.h(s02, -1);
                            w8.q(iH, iH);
                        }
                        return c3137a;
                    case 14:
                        if (w8.f7013g.f6510b.length() > 0 && (s03 = w8.f7015i) != null) {
                            int iH2 = w8.h(s03, 1);
                            w8.q(iH2, iH2);
                        }
                        return c3137a;
                    case 15:
                        w8.f7011e.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            w8.q(0, 0);
                        }
                        return c3137a;
                    case 16:
                        w8.f7011e.f7152a = null;
                        C0596g c0596g2 = w8.f7013g;
                        if (c0596g2.f6510b.length() > 0) {
                            int length = c0596g2.f6510b.length();
                            w8.q(length, length);
                        }
                        return c3137a;
                    case 17:
                        e0.f3598b.f(false);
                        return c3137a;
                    case 18:
                        e0.f3598b.r();
                        return c3137a;
                    case 19:
                        e0.f3598b.h();
                        return c3137a;
                    case 20:
                        List listA = w8.a(new h1(13));
                        if (listA != null) {
                            e0.a(listA);
                        }
                        return c3137a;
                    case 21:
                        List listA2 = w8.a(new h1(14));
                        if (listA2 != null) {
                            e0.a(listA2);
                        }
                        return c3137a;
                    case 22:
                        List listA3 = w8.a(new h1(15));
                        if (listA3 != null) {
                            e0.a(listA3);
                        }
                        return c3137a;
                    case 23:
                        List listA4 = w8.a(new h1(i12));
                        if (listA4 != null) {
                            e0.a(listA4);
                        }
                        return c3137a;
                    case 24:
                        List listA5 = w8.a(new h1(17));
                        if (listA5 != null) {
                            e0.a(listA5);
                        }
                        return c3137a;
                    case 25:
                        List listA6 = w8.a(new h1(18));
                        if (listA6 != null) {
                            e0.a(listA6);
                        }
                        return c3137a;
                    case 26:
                        w8.f7011e.f7152a = null;
                        C0596g c0596g3 = w8.f7013g;
                        if (c0596g3.f6510b.length() > 0) {
                            w8.q(0, c0596g3.f6510b.length());
                        }
                        return c3137a;
                    case 27:
                        w8.i();
                        w8.p();
                        return c3137a;
                    case 28:
                        w8.m();
                        w8.p();
                        return c3137a;
                    case 29:
                        if (w8.f7013g.f6510b.length() > 0 && (l7 = w8.f7009c) != null) {
                            int iG3 = w8.g(l7, -1);
                            w8.q(iG3, iG3);
                        }
                        w8.p();
                        return c3137a;
                    case 30:
                        if (w8.f7013g.f6510b.length() > 0 && (l8 = w8.f7009c) != null) {
                            int iG4 = w8.g(l8, 1);
                            w8.q(iG4, iG4);
                        }
                        w8.p();
                        return c3137a;
                    case 31:
                        if (w8.f7013g.f6510b.length() > 0 && (s04 = w8.f7015i) != null) {
                            int iH3 = w8.h(s04, -1);
                            w8.q(iH3, iH3);
                        }
                        w8.p();
                        return c3137a;
                    case 32:
                        if (w8.f7013g.f6510b.length() > 0 && (s05 = w8.f7015i) != null) {
                            int iH4 = w8.h(s05, 1);
                            w8.q(iH4, iH4);
                        }
                        w8.p();
                        return c3137a;
                    case 33:
                        w8.f7011e.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            w8.q(0, 0);
                        }
                        w8.p();
                        return c3137a;
                    case 34:
                        w8.f7011e.f7152a = null;
                        C0596g c0596g4 = w8.f7013g;
                        if (c0596g4.f6510b.length() > 0) {
                            int length2 = c0596g4.f6510b.length();
                            w8.q(length2, length2);
                        }
                        w8.p();
                        return c3137a;
                    case 35:
                        V.r0 r0Var3 = w8.f7011e;
                        r0Var3.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            if (w8.f()) {
                                r0Var3.f7152a = null;
                                if (w8.f7013g.f6510b.length() > 0 && (numE3 = w8.e()) != null) {
                                    int iIntValue5 = numE3.intValue();
                                    w8.q(iIntValue5, iIntValue5);
                                }
                            } else {
                                r0Var3.f7152a = null;
                                if (w8.f7013g.f6510b.length() > 0 && (numD3 = w8.d()) != null) {
                                    int iIntValue6 = numD3.intValue();
                                    w8.q(iIntValue6, iIntValue6);
                                }
                            }
                        }
                        w8.p();
                        return c3137a;
                    case TsExtractor.TS_STREAM_TYPE_H265 /* 36 */:
                        V.r0 r0Var4 = w8.f7011e;
                        r0Var4.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            if (w8.f()) {
                                r0Var4.f7152a = null;
                                if (w8.f7013g.f6510b.length() > 0 && (numD4 = w8.d()) != null) {
                                    int iIntValue7 = numD4.intValue();
                                    w8.q(iIntValue7, iIntValue7);
                                }
                            } else {
                                r0Var4.f7152a = null;
                                if (w8.f7013g.f6510b.length() > 0 && (numE4 = w8.e()) != null) {
                                    int iIntValue8 = numE4.intValue();
                                    w8.q(iIntValue8, iIntValue8);
                                }
                            }
                        }
                        w8.p();
                        return c3137a;
                    case FirestoreIndexValueWriter.INDEX_TYPE_REFERENCE /* 37 */:
                        w8.j();
                        w8.p();
                        return c3137a;
                    case FlacConstants.STREAM_INFO_BLOCK_SIZE /* 38 */:
                        w8.l();
                        w8.p();
                        return c3137a;
                    case 39:
                        w8.o();
                        w8.p();
                        return c3137a;
                    case 40:
                        w8.n();
                        w8.p();
                        return c3137a;
                    case 41:
                        w8.f7011e.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            if (w8.f()) {
                                w8.o();
                            } else {
                                w8.n();
                            }
                        }
                        w8.p();
                        return c3137a;
                    case AacUtil.AUDIO_OBJECT_TYPE_AAC_XHE /* 42 */:
                        w8.f7011e.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            if (w8.f()) {
                                w8.n();
                            } else {
                                w8.o();
                            }
                        }
                        w8.p();
                        return c3137a;
                    case 43:
                        w8.f7011e.f7152a = null;
                        if (w8.f7013g.f6510b.length() > 0) {
                            long j11 = w8.f7012f;
                            int i19 = T0.N.f6482c;
                            int i20 = (int) (j11 & 4294967295L);
                            w8.q(i20, i20);
                        }
                        return c3137a;
                    case 44:
                        if (e0.f3601e) {
                            C0490z c0490z = e0.f3597a.f3911x;
                            c0490z.getClass();
                            yVar5.f20130a = c0490z.f4034b.f3905r.b(e0.l);
                        } else {
                            e0.a(AbstractC2612c.q(new C0860a("\n", 1)));
                        }
                        return c3137a;
                    case 45:
                        if (e0.f3601e) {
                            yVar5.f20130a = false;
                        } else {
                            e0.a(AbstractC2612c.q(new C0860a("\t", 1)));
                        }
                        return c3137a;
                    case 46:
                        Y0 y02 = e0.f3604h;
                        if (y02 != null) {
                            y02.a(Z0.y.a(w8.f7014h, w8.f7013g, w8.f7012f, 4));
                        }
                        Y0 y03 = e0.f3604h;
                        if (y03 != null) {
                            T.p pVar2 = y03.f3769a;
                            if (pVar2 == null || (pVar = (T.p) pVar2.f6345b) == null) {
                                yVar = null;
                            } else {
                                y03.f3769a = pVar;
                                y03.f3771c -= ((Z0.y) pVar2.f6346c).f9136a.f6510b.length();
                                y03.f3770b = new T.p(i12, y03.f3770b, (Z0.y) pVar2.f6346c);
                                yVar = (Z0.y) pVar.f6346c;
                            }
                            if (yVar != null) {
                                e0.f3607k.invoke(yVar);
                            }
                        }
                        return c3137a;
                    case 47:
                        Y0 y04 = e0.f3604h;
                        if (y04 != null) {
                            T.p pVar3 = y04.f3770b;
                            if (pVar3 != null) {
                                y04.f3770b = (T.p) pVar3.f6345b;
                                Z0.y yVar6 = (Z0.y) pVar3.f6346c;
                                y04.f3769a = new T.p(i12, y04.f3769a, yVar6);
                                y04.f3771c = yVar6.f9136a.f6510b.length() + y04.f3771c;
                                yVar2 = (Z0.y) pVar3.f6346c;
                            } else {
                                yVar2 = null;
                            }
                            if (yVar2 != null) {
                                e0.f3607k.invoke(yVar2);
                            }
                        }
                        return c3137a;
                    default:
                        throw new E3.v();
                }
            case 5:
                C0483v0 c0483v0 = (C0483v0) obj;
                C0594e c0594e4 = (C0594e) obj3;
                Object obj6 = c0594e4.f6503a;
                T0.M mA4 = ((AbstractC0602m) obj6).a();
                T0.G g8 = mA4 != null ? mA4.f6477a : null;
                MutableIntState mutableIntState = ((C0468n0) obj4).f3936b;
                T0.G gC = (!((mutableIntState.getIntValue() & 1) != 0) || (mA3 = ((AbstractC0602m) obj6).a()) == null) ? null : mA3.f6478b;
                ((V0) obj5).getClass();
                if (g8 != null) {
                    gC = g8.c(gC);
                }
                T0.G gC2 = ((mutableIntState.getIntValue() & 2) == 0 || (mA2 = ((AbstractC0602m) obj6).a()) == null) ? null : mA2.f6479c;
                if (gC != null) {
                    gC2 = gC.c(gC2);
                }
                T0.G gC3 = ((mutableIntState.getIntValue() & 4) == 0 || (mA = ((AbstractC0602m) obj6).a()) == null) ? null : mA.f6480d;
                if (gC2 != null) {
                    gC3 = gC2.c(gC3);
                }
                c0483v0.getClass();
                c0483v0.f4004b = c0483v0.f4003a.b(new C0463l(new kotlin.jvm.internal.y(), c0594e4, gC3, i11));
                return c3137a;
            case 6:
                C2099d2 entry = (C2099d2) obj;
                kotlin.jvm.internal.o.h(entry, "entry");
                ((MutableState) obj3).setValue(Boolean.FALSE);
                ((J4.e) obj5).invoke((EnumC2203v) obj4, new HomeSection(entry.f17848a, entry.f17849b, x4.y.f26065a));
                return c3137a;
            case 7:
                D.A LazyColumn = (D.A) obj;
                kotlin.jvm.internal.o.h(LazyColumn, "$this$LazyColumn");
                List list = (List) obj3;
                ((D.l) LazyColumn).t(list.size(), new U(i9, new C0556x0(i11), list), new M2.W(list, i10), ComposableLambdaKt.composableLambdaInstance(802480018, true, new M2.U0(list, (String) obj4, (J4.c) obj5, 0)));
                return c3137a;
            case 8:
                E.v LazyVerticalGrid = (E.v) obj;
                kotlin.jvm.internal.o.h(LazyVerticalGrid, "$this$LazyVerticalGrid");
                State state = (State) obj3;
                List list2 = ((C2209w) state.getValue()).f18632b;
                ((E.j) LazyVerticalGrid).s(list2.size(), new U(7, new A4.b(11), list2), new M2.W(list2, 5), ComposableLambdaKt.composableLambdaInstance(-1942245546, true, new M2.U0(list2, (M2.C) obj4, (J4.c) obj5, i14)));
                if (((C2209w) state.getValue()).f18634d) {
                    E.v.c(LazyVerticalGrid, new C0556x0(9), AbstractC0504e.f4686a, 5);
                }
                return c3137a;
            case 9:
                C3132d c3132d = (C3132d) obj;
                ?? r9 = ((N.c) obj5).f5114a;
                int size = r9.size();
                int i21 = 0;
                while (i21 < size) {
                    N.b bVar = (N.b) r9.get(i21);
                    if (bVar instanceof N.d) {
                        N.d dVar = (N.d) bVar;
                        C3132d.b(c3132d, new C0053c(dVar, i8), ((N.d) bVar).f5116c == 0 ? null : ComposableLambdaKt.composableLambdaInstance(-1930700965, true, new K2.m(dVar, i7)), new B2.j(i6, dVar, (N.g) obj4), 6);
                    } else if (bVar instanceof N.h) {
                        if (Build.VERSION.SDK_INT >= 28) {
                            N.h hVar = (N.h) bVar;
                            Context context = (Context) obj3;
                            if (context != null) {
                                int i22 = hVar.f5125c;
                                TextClassification textClassification = hVar.f5124b;
                                if (i22 < 0) {
                                    C0053c c0053c = new C0053c(textClassification, 8);
                                    Drawable icon = textClassification.getIcon();
                                    C3132d.b(c3132d, c0053c, icon != null ? ComposableLambdaKt.composableLambdaInstance(-1123224187, true, new K2.m(icon, i10)) : null, new B2.j(14, context, textClassification), 6);
                                } else {
                                    RemoteAction remoteActionD = G1.c.d(textClassification.getActions().get(i22));
                                    C3132d.b(c3132d, new C0053c(remoteActionD, 9), ((i22 == 0) || remoteActionD.shouldShowIcon()) ? ComposableLambdaKt.composableLambdaInstance(-1261173016, true, new K2.m(remoteActionD, 5)) : null, new C0135f(remoteActionD, 10), 6);
                                }
                            }
                        }
                    } else if (bVar instanceof N.f) {
                        c3132d.getClass();
                        c3132d.f25418b.add(AbstractC3130b.f25411b);
                    }
                    i21++;
                    i6 = 13;
                    i7 = 3;
                    i8 = 7;
                }
                return c3137a;
            case 10:
                C0124z c0124z = (C0124z) obj;
                long j12 = c0124z.f646c;
                G0.K k7 = (G0.K) obj3;
                C0109j c0109j = (C0109j) obj5;
                V.i0 i0Var = (V.i0) c0109j.f608d;
                if (i0Var.m() && i0Var.p().f9136a.f6510b.length() != 0 && (c0464l0 = i0Var.f7084d) != null && c0464l0.d() != null) {
                    c0109j.j(i0Var.p(), j12, false, k7);
                    i13 = 1;
                }
                if (i13 != 0) {
                    c0124z.a();
                    ((kotlin.jvm.internal.y) obj4).f20130a = true;
                }
                return c3137a;
            case 11:
                M.a aVar = (M.a) obj;
                N.f fVar3 = N.f.f5123b;
                aVar.f4195a.g(fVar3);
                EnumC0485w0 enumC0485w0 = EnumC0485w0.f4011d;
                V.i0 i0Var2 = (V.i0) obj5;
                boolean z7 = (T0.N.c(i0Var2.p().f9137b) || !i0Var2.l() || (i0Var2.f7086f instanceof Z0.s) || i0Var2.f7088h == null) ? false : true;
                V4.C c6 = (V4.C) obj3;
                B2.j jVar = new B2.j(c6, new V.n0(i0Var2, null));
                Context context2 = (Context) obj4;
                Resources resources = context2.getResources();
                B.B0 b02 = new B.B0(i12, jVar, obj2);
                n.J j13 = aVar.f4195a;
                if (z7) {
                    j13.g(new N.d(N.e.f5118a, resources.getString(R.string.cut), R.attr.actionModeCutDrawable, b02));
                }
                EnumC0485w0 enumC0485w02 = EnumC0485w0.f4011d;
                boolean z8 = (T0.N.c(i0Var2.p().f9137b) || (i0Var2.f7086f instanceof Z0.s) || i0Var2.f7088h == null) ? false : true;
                B2.j jVar2 = new B2.j(c6, new V.o0(i0Var2, null));
                Resources resources2 = context2.getResources();
                B.B0 b03 = new B.B0(i12, jVar2, obj2);
                if (z8) {
                    j13.g(new N.d(N.e.f5119b, resources2.getString(R.string.copy), R.attr.actionModeCopyDrawable, b03));
                }
                EnumC0485w0 enumC0485w03 = EnumC0485w0.f4011d;
                boolean z9 = i0Var2.l() && ((Boolean) i0Var2.f7103x.getValue()).booleanValue() && i0Var2.f7088h != null;
                B2.j jVar3 = new B2.j(c6, new V.p0(i0Var2, null));
                Resources resources3 = context2.getResources();
                B.B0 b04 = new B.B0(i12, jVar3, obj2);
                if (z9) {
                    j13.g(new N.d(N.e.f5120c, resources3.getString(R.string.paste), R.attr.actionModePasteDrawable, b04));
                }
                EnumC0485w0 enumC0485w04 = EnumC0485w0.f4011d;
                boolean z10 = T0.N.d(i0Var2.p().f9137b) != i0Var2.p().f9136a.f6510b.length();
                V.m0 m0Var = new V.m0(i0Var2, i13);
                V.m0 m0Var2 = new V.m0(i0Var2, i14);
                Resources resources4 = context2.getResources();
                B.B0 b05 = new B.B0(i12, m0Var2, m0Var);
                if (z10) {
                    j13.g(new N.d(N.e.f5121d, resources4.getString(R.string.selectAll), R.attr.actionModeSelectAllDrawable, b05));
                }
                if (Build.VERSION.SDK_INT >= 26) {
                    EnumC0485w0 enumC0485w05 = EnumC0485w0.f4011d;
                    if (i0Var2.l() && T0.N.c(i0Var2.p().f9137b)) {
                        i13 = 1;
                    }
                    V.m0 m0Var3 = new V.m0(i0Var2, i11);
                    Resources resources5 = context2.getResources();
                    B.B0 b06 = new B.B0(i12, m0Var3, obj2);
                    if (i13 != 0) {
                        j13.g(new N.d(enumC0485w05.f4013a, resources5.getString(enumC0485w05.f4014b), enumC0485w05.f4015c, b06));
                    }
                }
                j13.g(fVar3);
                return c3137a;
            case 12:
                return a(obj);
            case 13:
                return b(obj);
            case 14:
                return c(obj);
            case 15:
                return d(obj);
            case 16:
                return e(obj);
            case 17:
                return f(obj);
            case 18:
                return g(obj);
            case 19:
                return h(obj);
            case 20:
                return i(obj);
            case 21:
                return j(obj);
            case 22:
                return k(obj);
            case 23:
                return l(obj);
            case 24:
                return m(obj);
            case 25:
                return n(obj);
            case 26:
                return o(obj);
            default:
                float fFloatValue = ((Float) obj).floatValue();
                C3171j c3171j = (C3171j) obj5;
                float f7 = c3171j.f25836c ? 1.0f : -1.0f;
                C3167h1 c3167h1 = c3171j.f25835b;
                long jE = c3167h1.e(c3167h1.h(f7 * fFloatValue));
                C3167h1 c3167h12 = ((C3158e1) obj4).f25776a;
                float fG = c3167h1.g(c3167h1.e(c3167h12.c(c3167h12.f25819k, jE, 1))) * f7;
                if (Math.abs(fG) < Math.abs(fFloatValue)) {
                    ((InterfaceC0765i0) obj3).cancel(V4.E.a("Scroll animation cancelled because scroll was not consumed (" + fG + " < " + fFloatValue + ')', null));
                }
                return c3137a;
        }
    }

    public /* synthetic */ C0463l(Object obj, Object obj2, MutableState mutableState, int i6) {
        this.f3883a = i6;
        this.f3884b = obj;
        this.f3886d = obj2;
        this.f3885c = mutableState;
    }

    public /* synthetic */ C0463l(Object obj, Object obj2, Object obj3, int i6) {
        this.f3883a = i6;
        this.f3884b = obj;
        this.f3885c = obj2;
        this.f3886d = obj3;
    }

    public /* synthetic */ C0463l(C3171j c3171j, L1 l12, InterfaceC0765i0 interfaceC0765i0, C3158e1 c3158e1) {
        this.f3883a = 27;
        this.f3884b = c3171j;
        this.f3885c = interfaceC0765i0;
        this.f3886d = c3158e1;
    }
}
