package v6;

import android.content.Context;
import android.content.ContextWrapper;
import android.view.LayoutInflater;
import h0.ComponentCallbacksC1023x;

/* JADX INFO: loaded from: classes.dex */
public final class h extends ContextWrapper {

    /* JADX INFO: renamed from: a, reason: collision with root package name */
    public LayoutInflater f18125a;

    /* JADX INFO: renamed from: b, reason: collision with root package name */
    public LayoutInflater f18126b;

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public h(Context context, ComponentCallbacksC1023x componentCallbacksC1023x) {
        super(context);
        context.getClass();
        U1.b bVar = new U1.b(4, this);
        this.f18125a = null;
        componentCallbacksC1023x.getClass();
        componentCallbacksC1023x.f13285f0.f(bVar);
    }

    @Override // android.content.ContextWrapper, android.content.Context
    public final Object getSystemService(String str) {
        if (!"layout_inflater".equals(str)) {
            return getBaseContext().getSystemService(str);
        }
        if (this.f18126b == null) {
            if (this.f18125a == null) {
                this.f18125a = (LayoutInflater) getBaseContext().getSystemService("layout_inflater");
            }
            this.f18126b = this.f18125a.cloneInContext(this);
        }
        return this.f18126b;
    }

    /* JADX WARN: Illegal instructions before constructor call */
    public h(LayoutInflater layoutInflater, ComponentCallbacksC1023x componentCallbacksC1023x) {
        layoutInflater.getClass();
        Context context = layoutInflater.getContext();
        context.getClass();
        super(context);
        U1.b bVar = new U1.b(4, this);
        this.f18125a = layoutInflater;
        componentCallbacksC1023x.getClass();
        componentCallbacksC1023x.f13285f0.f(bVar);
    }
}
