what-the-bank/sources/o/C10649eKd.java

136 lines
4.5 KiB
Java
Raw Normal View History

2024-07-27 18:17:47 +07:00
package o;
import android.graphics.Canvas;
import android.graphics.Path;
import com.github.mikephil.charting.charts.RadarChart;
import com.google.android.gms.maps.model.BitmapDescriptorFactory;
import java.util.List;
/* renamed from: o.eKd, reason: case insensitive filesystem */
/* loaded from: classes.dex */
public final class C10649eKd extends C13675fem {
private RadarChart f;
private Path j;
public C10649eKd(DRH drh, OFJ ofj, RadarChart radarChart) {
super(drh, ofj);
this.j = new Path();
this.f = radarChart;
}
/* JADX INFO: Access modifiers changed from: protected */
@Override // o.YQn
public final void a(float f, float f2) {
int i;
int i2 = this.c.p;
double abs = Math.abs(f2 - f);
if (i2 == 0 || abs <= 0.0d || Double.isInfinite(abs)) {
this.c.m = new float[0];
this.c.e = new float[0];
this.c.l = 0;
return;
}
double a = AbstractC0810PWv.a(abs / i2);
boolean z = this.c.f9214o;
double a2 = AbstractC0810PWv.a(Math.pow(10.0d, (int) Math.log10(a)));
if (((int) (a / a2)) > 5) {
a = Math.floor(a2 * 10.0d);
}
AbstractC16220mRf abstractC16220mRf = this.c;
boolean z2 = this.c.n;
double ceil = a == 0.0d ? 0.0d : Math.ceil(f / a) * a;
double b = a == 0.0d ? 0.0d : AbstractC0810PWv.b(Math.floor(f2 / a) * a);
if (a != 0.0d) {
i = 0;
for (double d = ceil; d <= b; d += a) {
i++;
}
} else {
i = 0;
}
int i3 = i + 1;
this.c.l = i3;
if (this.c.m.length < i3) {
this.c.m = new float[i3];
}
for (int i4 = 0; i4 < i3; i4++) {
if (ceil == 0.0d) {
ceil = 0.0d;
}
this.c.m[i4] = (float) ceil;
ceil += a;
}
if (a < 1.0d) {
this.c.i = (int) Math.ceil(-Math.log10(a));
} else {
this.c.i = 0;
}
this.c.c = this.c.m[0];
this.c.a = this.c.m[i];
this.c.d = Math.abs(this.c.a - this.c.c);
}
@Override // o.C13675fem
public final void Ha_(Canvas canvas) {
String str;
if (((C13675fem) this).e.q && ((C13675fem) this).e.h) {
this.b.setTypeface(((C13675fem) this).e.v);
this.b.setTextSize(((C13675fem) this).e.b());
this.b.setColor(((C13675fem) this).e.r);
QFQ c = this.f.c();
QFQ e = QFQ.e(BitmapDescriptorFactory.HUE_RED, BitmapDescriptorFactory.HUE_RED);
float x = this.f.x();
int i = ((C13675fem) this).e.u ? ((C13675fem) this).e.l : ((C13675fem) this).e.l - 1;
for (int i2 = !((C13675fem) this).e.y ? 1 : 0; i2 < i; i2++) {
AbstractC0810PWv.b(c, (((C13675fem) this).e.m[i2] - ((C13675fem) this).e.c) * x, this.f.H, e);
OFJ ofj = ((C13675fem) this).e;
if (i2 < 0 || i2 >= ofj.m.length) {
str = "";
} else {
str = ofj.c().c(ofj.m[i2]);
}
canvas.drawText(str, e.a + 10.0f, e.e, this.b);
}
QFQ.b(c);
QFQ.b(e);
}
}
/* JADX WARN: Multi-variable type inference failed */
@Override // o.C13675fem
public final void Hb_(Canvas canvas) {
List<TpZ> list = ((C13675fem) this).e.s;
if (list == null) {
return;
}
float v = this.f.v();
float x = this.f.x();
QFQ c = this.f.c();
QFQ e = QFQ.e(BitmapDescriptorFactory.HUE_RED, BitmapDescriptorFactory.HUE_RED);
for (int i = 0; i < list.size(); i++) {
TpZ tpZ = list.get(i);
if (tpZ.q) {
this.a.setColor(tpZ.c);
this.a.setPathEffect(tpZ.e);
this.a.setStrokeWidth(tpZ.d);
float f = tpZ.b;
float f2 = this.f.v.c;
Path path = this.j;
path.reset();
for (int i2 = 0; i2 < ((Bsv) this.f.g()).b().r(); i2++) {
AbstractC0810PWv.b(c, (BitmapDescriptorFactory.HUE_RED - f2) * x, (i2 * v) + this.f.H, e);
if (i2 == 0) {
path.moveTo(e.a, e.e);
} else {
path.lineTo(e.a, e.e);
}
}
path.close();
canvas.drawPath(path, this.a);
}
}
QFQ.b(c);
QFQ.b(e);
}
}