package B;

import F1.AbstractC0195y;
import F1.C0180i;
import android.content.Context;
import android.view.View;
import androidx.compose.runtime.DisposableEffectResult;
import androidx.compose.runtime.MutableState;
import androidx.compose.runtime.State;
import androidx.lifecycle.C1104m;
import androidx.lifecycle.InterfaceC1113w;
import androidx.media3.exoplayer.ExoPlayer;
import androidx.navigation.C1137l;
import d.AbstractActivityC1833l;
import d3.C1917q0;
import d3.C1944z1;
import j2.C2330h;
import j2.C2335m;
import java.lang.reflect.Field;
import java.util.Iterator;
import java.util.List;
import m3.C2481p;
import q.C2757H;
import q.C2760K;
import q.C2803u0;

/* JADX INFO: loaded from: classes.dex */
public final class f1 implements DisposableEffectResult {

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

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

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

    public /* synthetic */ f1(int i6, Object obj, Object obj2) {
        this.f276a = i6;
        this.f277b = obj;
        this.f278c = obj2;
    }

    /* JADX WARN: Multi-variable type inference failed */
    @Override // androidx.compose.runtime.DisposableEffectResult
    public final void dispose() {
        Object obj = this.f278c;
        Object obj2 = this.f277b;
        switch (this.f276a) {
            case 0:
                g1 g1Var = (g1) obj2;
                int i6 = g1Var.f302u - 1;
                g1Var.f302u = i6;
                if (i6 == 0) {
                    Field field = F1.F.f1367a;
                    View view = (View) obj;
                    AbstractC0195y.c(view, null);
                    F1.F.e(view, null);
                    view.removeOnAttachStateChangeListener(g1Var.f303v);
                }
                break;
            case 1:
                ((F.d0) obj2).f1273c.j(obj);
                break;
            case 2:
                ((Context) obj2).getApplicationContext().unregisterComponentCallbacks((J0.T) obj);
                break;
            case 3:
                ((Context) obj2).getApplicationContext().unregisterComponentCallbacks((J0.U) obj);
                break;
            case 4:
                MutableState mutableState = (MutableState) obj2;
                z.o oVar = (z.o) mutableState.getValue();
                if (oVar != null) {
                    z.n nVar = new z.n(oVar);
                    z.l lVar = (z.l) obj;
                    if (lVar != null) {
                        ((z.m) lVar).b(nVar);
                    }
                    mutableState.setValue(null);
                }
                break;
            case 5:
                ((K.V0) obj2).f3755c.remove((J4.c) obj);
                break;
            case 6:
                ((AbstractActivityC1833l) obj2).getLifecycle().removeObserver((C0180i) obj);
                break;
            case 7:
                ((InterfaceC1113w) obj2).getLifecycle().removeObserver((C0180i) obj);
                break;
            case 8:
                ((AbstractActivityC1833l) obj2).getLifecycle().removeObserver((C1917q0) obj);
                break;
            case 9:
                ((ExoPlayer) obj2).removeListener((C1944z1) obj);
                break;
            case 10:
                ((C1137l) obj2).f12763k.removeObserver((C2335m) obj);
                break;
            case 11:
                Iterator it = ((List) ((State) obj2).getValue()).iterator();
                while (it.hasNext()) {
                    ((C2330h) obj).b().b((C1137l) it.next());
                }
                break;
            case 12:
                ((InterfaceC1113w) obj2).getLifecycle().removeObserver((C0180i) obj);
                break;
            case 13:
                ((AbstractActivityC1833l) obj2).getLifecycle().removeObserver((C1104m) obj);
                break;
            case 14:
                ((AbstractActivityC1833l) obj2).getLifecycle().removeObserver((C1104m) obj);
                break;
            case 15:
                ExoPlayer exoPlayer = (ExoPlayer) obj2;
                exoPlayer.removeListener((C2481p) obj);
                exoPlayer.stop();
                exoPlayer.release();
                break;
            case 16:
                ((C2760K) obj2).f23191a.remove((C2757H) obj);
                break;
            case 17:
                ((q.A0) obj2).f23143j.remove((q.A0) obj);
                break;
            case 18:
                q.A0 a02 = (q.A0) obj2;
                a02.getClass();
                C2803u0 c2803u0 = (C2803u0) ((q.v0) obj).f23470b.getValue();
                if (c2803u0 != null) {
                    a02.f23142i.remove(c2803u0.f23457a);
                }
                break;
            default:
                ((q.A0) obj2).f23142i.remove((q.y0) obj);
                break;
        }
    }
}
