package xc;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import androidx.annotation.Nullable;
import com.google.android.gms.measurement.internal.u1;
import ed.w;
import io.flutter.embedding.engine.plugins.lifecycle.HiddenLifecycleReference;
import java.util.HashSet;
import java.util.Iterator;

/* JADX INFO: loaded from: classes.dex */
public final class e implements bd.c {

    /* JADX INFO: renamed from: a, reason: collision with root package name */
    public final Activity f34783a;

    /* JADX INFO: renamed from: b, reason: collision with root package name */
    public final HiddenLifecycleReference f34784b;

    /* JADX INFO: renamed from: c, reason: collision with root package name */
    public final HashSet f34785c = new HashSet();

    /* JADX INFO: renamed from: d, reason: collision with root package name */
    public final HashSet f34786d = new HashSet();

    /* JADX INFO: renamed from: e, reason: collision with root package name */
    public final HashSet f34787e = new HashSet();

    /* JADX INFO: renamed from: f, reason: collision with root package name */
    public final HashSet f34788f = new HashSet();

    /* JADX INFO: renamed from: g, reason: collision with root package name */
    public final HashSet f34789g;

    public e(Activity activity, androidx.lifecycle.l lVar) {
        new HashSet();
        this.f34789g = new HashSet();
        this.f34783a = activity;
        this.f34784b = new HiddenLifecycleReference(lVar);
    }

    public final void a(w wVar) {
        this.f34786d.remove(wVar);
    }

    public boolean onActivityResult(int i10, int i11, @Nullable Intent intent) {
        Iterator it = new HashSet(this.f34786d).iterator();
        while (true) {
            boolean z10 = false;
            while (it.hasNext()) {
                if (((w) it.next()).onActivityResult(i10, i11, intent) || z10) {
                    z10 = true;
                }
            }
            return z10;
        }
    }

    public void onNewIntent(@Nullable Intent intent) {
        Iterator it = this.f34787e.iterator();
        if (it.hasNext()) {
            u1.x(it.next());
            throw null;
        }
    }

    public void onRestoreInstanceState(@Nullable Bundle bundle) {
        Iterator it = this.f34789g.iterator();
        if (it.hasNext()) {
            u1.x(it.next());
            throw null;
        }
    }
}
