package z;

import android.view.View;
import android.widget.Magnifier;

/* loaded from: classes.dex */
public final class s0 implements q0 {

    /* renamed from: b, reason: collision with root package name */
    public static final s0 f53057b = new s0();

    /* renamed from: c, reason: collision with root package name */
    private static final boolean f53058c = true;

    /* loaded from: classes.dex */
    public static final class a extends r0 {
        public a(Magnifier magnifier) {
            super(magnifier);
        }

        @Override // z.p0
        public void a(long j10, long j11, float f10) {
            if (!Float.isNaN(f10)) {
                c().setZoom(f10);
            }
            if (r1.h.c(j11)) {
                c().show(r1.g.m(j10), r1.g.n(j10), r1.g.m(j11), r1.g.n(j11));
            } else {
                c().show(r1.g.m(j10), r1.g.n(j10));
            }
        }
    }

    private s0() {
    }

    @Override // z.q0
    public boolean a() {
        return f53058c;
    }

    @Override // z.q0
    /* renamed from: c, reason: merged with bridge method [inline-methods] */
    public a b(View view, boolean z10, long j10, float f10, float f11, boolean z11, c3.d dVar, float f12) {
        int c10;
        int c11;
        if (z10) {
            return new a(new Magnifier(view));
        }
        long l12 = dVar.l1(j10);
        float L0 = dVar.L0(f10);
        float L02 = dVar.L0(f11);
        Magnifier.Builder builder = new Magnifier.Builder(view);
        if (l12 != 9205357640488583168L) {
            c10 = fn.c.c(r1.m.i(l12));
            c11 = fn.c.c(r1.m.g(l12));
            builder.setSize(c10, c11);
        }
        if (!Float.isNaN(L0)) {
            builder.setCornerRadius(L0);
        }
        if (!Float.isNaN(L02)) {
            builder.setElevation(L02);
        }
        if (!Float.isNaN(f12)) {
            builder.setInitialZoom(f12);
        }
        builder.setClippingEnabled(z11);
        return new a(builder.build());
    }
}
