package androidx.activity.result;

import androidx.activity.result.AbstractC0072d;
import androidx.lifecycle.AbstractC0424i;
import androidx.lifecycle.InterfaceC0432k;
import androidx.lifecycle.InterfaceC0434m;
import p004b.AbstractC0463a;

/* loaded from: classes.dex */
class ActivityResultRegistry$1 implements InterfaceC0432k {

    /* renamed from: a */
    public final /* synthetic */ String f73a;

    /* renamed from: b */
    public final /* synthetic */ InterfaceC0070b f74b;

    /* renamed from: c */
    public final /* synthetic */ AbstractC0463a f75c;

    /* renamed from: d */
    public final /* synthetic */ AbstractC0072d f76d;

    @Override // androidx.lifecycle.InterfaceC0432k
    /* renamed from: d */
    public void mo472d(InterfaceC0434m interfaceC0434m, AbstractC0424i.EnumC0426b enumC0426b) {
        if (!AbstractC0424i.EnumC0426b.ON_START.equals(enumC0426b)) {
            if (AbstractC0424i.EnumC0426b.ON_STOP.equals(enumC0426b)) {
                this.f76d.f84f.remove(this.f73a);
                return;
            } else if (AbstractC0424i.EnumC0426b.ON_DESTROY.equals(enumC0426b)) {
                this.f76d.m4983i(this.f73a);
                return;
            } else {
                return;
            }
        }
        this.f76d.f84f.put(this.f73a, new AbstractC0072d.C0074b<>(this.f74b, this.f75c));
        if (this.f76d.f85g.containsKey(this.f73a)) {
            Object obj = this.f76d.f85g.get(this.f73a);
            this.f76d.f85g.remove(this.f73a);
            this.f74b.mo3936a(obj);
        }
        C0068a c0068a = (C0068a) this.f76d.f86h.getParcelable(this.f73a);
        if (c0068a != null) {
            this.f76d.f86h.remove(this.f73a);
            this.f74b.mo3936a(this.f75c.mo3634a(c0068a.m4995b(), c0068a.m4996a()));
        }
    }
}