50 lines
1.5 KiB
Java
50 lines
1.5 KiB
Java
package androidx.transition;
|
|
|
|
import android.graphics.Path;
|
|
import android.graphics.PathMeasure;
|
|
import android.graphics.PointF;
|
|
import android.util.Property;
|
|
|
|
/* loaded from: classes.dex */
|
|
class PathProperty<T> extends Property<T, Float> {
|
|
private final Property<T, PointF> a;
|
|
private final PathMeasure b;
|
|
private final float c;
|
|
private final float[] d;
|
|
private final PointF e;
|
|
private float f;
|
|
|
|
PathProperty(Property<T, PointF> property, Path path) {
|
|
super(Float.class, property.getName());
|
|
this.d = new float[2];
|
|
this.e = new PointF();
|
|
this.a = property;
|
|
this.b = new PathMeasure(path, false);
|
|
this.c = this.b.getLength();
|
|
}
|
|
|
|
@Override // android.util.Property
|
|
/* renamed from: a, reason: merged with bridge method [inline-methods] */
|
|
public void set(T t, Float f) {
|
|
this.f = f.floatValue();
|
|
this.b.getPosTan(this.c * f.floatValue(), this.d, null);
|
|
PointF pointF = this.e;
|
|
float[] fArr = this.d;
|
|
pointF.x = fArr[0];
|
|
pointF.y = fArr[1];
|
|
this.a.set(t, pointF);
|
|
}
|
|
|
|
/* JADX WARN: Multi-variable type inference failed */
|
|
@Override // android.util.Property
|
|
public /* bridge */ /* synthetic */ Float get(Object obj) {
|
|
return get((PathProperty<T>) obj);
|
|
}
|
|
|
|
/* JADX WARN: Can't rename method to resolve collision */
|
|
@Override // android.util.Property
|
|
public Float get(T t) {
|
|
return Float.valueOf(this.f);
|
|
}
|
|
}
|