Initial import of ADIF API reverse-engineering toolkit
This commit is contained in:
37
apk_decompiled/sources/S1/a.java
Normal file
37
apk_decompiled/sources/S1/a.java
Normal file
@@ -0,0 +1,37 @@
|
||||
package S1;
|
||||
|
||||
import android.view.ScaleGestureDetector;
|
||||
import com.google.android.gms.maps.model.BitmapDescriptorFactory;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public final class a implements ScaleGestureDetector.OnScaleGestureListener {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final /* synthetic */ b f1537a;
|
||||
|
||||
public a(b bVar) {
|
||||
this.f1537a = bVar;
|
||||
}
|
||||
|
||||
@Override // android.view.ScaleGestureDetector.OnScaleGestureListener
|
||||
public final boolean onScale(ScaleGestureDetector scaleGestureDetector) {
|
||||
float scaleFactor = scaleGestureDetector.getScaleFactor();
|
||||
if (Float.isNaN(scaleFactor) || Float.isInfinite(scaleFactor)) {
|
||||
return false;
|
||||
}
|
||||
if (scaleFactor < BitmapDescriptorFactory.HUE_RED) {
|
||||
return true;
|
||||
}
|
||||
this.f1537a.f1545j.t(scaleFactor, scaleGestureDetector.getFocusX(), scaleGestureDetector.getFocusY());
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override // android.view.ScaleGestureDetector.OnScaleGestureListener
|
||||
public final boolean onScaleBegin(ScaleGestureDetector scaleGestureDetector) {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override // android.view.ScaleGestureDetector.OnScaleGestureListener
|
||||
public final void onScaleEnd(ScaleGestureDetector scaleGestureDetector) {
|
||||
}
|
||||
}
|
||||
216
apk_decompiled/sources/S1/b.java
Normal file
216
apk_decompiled/sources/S1/b.java
Normal file
@@ -0,0 +1,216 @@
|
||||
package S1;
|
||||
|
||||
import android.content.Context;
|
||||
import android.graphics.Matrix;
|
||||
import android.graphics.RectF;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.ScaleGestureDetector;
|
||||
import android.view.VelocityTracker;
|
||||
import android.view.ViewConfiguration;
|
||||
import android.view.ViewParent;
|
||||
import com.github.chrisbanes.photoview.PhotoView;
|
||||
import com.google.android.gms.maps.model.BitmapDescriptorFactory;
|
||||
import kotlin.KotlinVersion;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public final class b {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public int f1538a = -1;
|
||||
|
||||
/* renamed from: b, reason: collision with root package name */
|
||||
public int f1539b = 0;
|
||||
|
||||
/* renamed from: c, reason: collision with root package name */
|
||||
public final ScaleGestureDetector f1540c;
|
||||
|
||||
/* renamed from: d, reason: collision with root package name */
|
||||
public VelocityTracker f1541d;
|
||||
|
||||
/* renamed from: e, reason: collision with root package name */
|
||||
public boolean f1542e;
|
||||
|
||||
/* renamed from: f, reason: collision with root package name */
|
||||
public float f1543f;
|
||||
|
||||
/* renamed from: g, reason: collision with root package name */
|
||||
public float f1544g;
|
||||
public final float h;
|
||||
public final float i;
|
||||
|
||||
/* renamed from: j, reason: collision with root package name */
|
||||
public final A.a f1545j;
|
||||
|
||||
public b(Context context, A.a aVar) {
|
||||
ViewConfiguration viewConfiguration = ViewConfiguration.get(context);
|
||||
this.i = viewConfiguration.getScaledMinimumFlingVelocity();
|
||||
this.h = viewConfiguration.getScaledTouchSlop();
|
||||
this.f1545j = aVar;
|
||||
this.f1540c = new ScaleGestureDetector(context, new a(this));
|
||||
}
|
||||
|
||||
public final void a(MotionEvent motionEvent) {
|
||||
float x3;
|
||||
float y3;
|
||||
float x4;
|
||||
float y4;
|
||||
RectF rectF;
|
||||
int i;
|
||||
int i4;
|
||||
int i5;
|
||||
int i6;
|
||||
float x5;
|
||||
float y5;
|
||||
int i7;
|
||||
int action = motionEvent.getAction() & KotlinVersion.MAX_COMPONENT_VALUE;
|
||||
if (action != 0) {
|
||||
A.a aVar = this.f1545j;
|
||||
if (action == 1) {
|
||||
this.f1538a = -1;
|
||||
if (this.f1542e && this.f1541d != null) {
|
||||
try {
|
||||
x4 = motionEvent.getX(this.f1539b);
|
||||
} catch (Exception unused) {
|
||||
x4 = motionEvent.getX();
|
||||
}
|
||||
this.f1543f = x4;
|
||||
try {
|
||||
y4 = motionEvent.getY(this.f1539b);
|
||||
} catch (Exception unused2) {
|
||||
y4 = motionEvent.getY();
|
||||
}
|
||||
this.f1544g = y4;
|
||||
this.f1541d.addMovement(motionEvent);
|
||||
this.f1541d.computeCurrentVelocity(1000);
|
||||
float xVelocity = this.f1541d.getXVelocity();
|
||||
float yVelocity = this.f1541d.getYVelocity();
|
||||
if (Math.max(Math.abs(xVelocity), Math.abs(yVelocity)) >= this.i) {
|
||||
o oVar = (o) aVar.f7b;
|
||||
n nVar = new n(oVar, oVar.h.getContext());
|
||||
oVar.f1573r = nVar;
|
||||
PhotoView photoView = oVar.h;
|
||||
int width = (photoView.getWidth() - photoView.getPaddingLeft()) - photoView.getPaddingRight();
|
||||
int height = (photoView.getHeight() - photoView.getPaddingTop()) - photoView.getPaddingBottom();
|
||||
int i8 = (int) (-xVelocity);
|
||||
int i9 = (int) (-yVelocity);
|
||||
oVar.b();
|
||||
Matrix c4 = oVar.c();
|
||||
if (oVar.h.getDrawable() != null) {
|
||||
rectF = oVar.f1570n;
|
||||
rectF.set(BitmapDescriptorFactory.HUE_RED, BitmapDescriptorFactory.HUE_RED, r12.getIntrinsicWidth(), r12.getIntrinsicHeight());
|
||||
c4.mapRect(rectF);
|
||||
} else {
|
||||
rectF = null;
|
||||
}
|
||||
if (rectF != null) {
|
||||
int round = Math.round(-rectF.left);
|
||||
float f2 = width;
|
||||
if (f2 < rectF.width()) {
|
||||
i = Math.round(rectF.width() - f2);
|
||||
i4 = 0;
|
||||
} else {
|
||||
i = round;
|
||||
i4 = i;
|
||||
}
|
||||
int round2 = Math.round(-rectF.top);
|
||||
float f4 = height;
|
||||
if (f4 < rectF.height()) {
|
||||
i5 = Math.round(rectF.height() - f4);
|
||||
i6 = 0;
|
||||
} else {
|
||||
i5 = round2;
|
||||
i6 = i5;
|
||||
}
|
||||
nVar.f1556b = round;
|
||||
nVar.f1557c = round2;
|
||||
if (round != i || round2 != i5) {
|
||||
nVar.f1555a.fling(round, round2, i8, i9, i4, i, i6, i5, 0, 0);
|
||||
}
|
||||
}
|
||||
photoView.post(oVar.f1573r);
|
||||
}
|
||||
}
|
||||
VelocityTracker velocityTracker = this.f1541d;
|
||||
if (velocityTracker != null) {
|
||||
velocityTracker.recycle();
|
||||
this.f1541d = null;
|
||||
}
|
||||
} else if (action == 2) {
|
||||
try {
|
||||
x5 = motionEvent.getX(this.f1539b);
|
||||
} catch (Exception unused3) {
|
||||
x5 = motionEvent.getX();
|
||||
}
|
||||
try {
|
||||
y5 = motionEvent.getY(this.f1539b);
|
||||
} catch (Exception unused4) {
|
||||
y5 = motionEvent.getY();
|
||||
}
|
||||
float f5 = x5 - this.f1543f;
|
||||
float f6 = y5 - this.f1544g;
|
||||
if (!this.f1542e) {
|
||||
this.f1542e = Math.sqrt((double) ((f6 * f6) + (f5 * f5))) >= ((double) this.h);
|
||||
}
|
||||
if (this.f1542e) {
|
||||
o oVar2 = (o) aVar.f7b;
|
||||
if (!oVar2.f1566j.f1540c.isInProgress()) {
|
||||
oVar2.f1569m.postTranslate(f5, f6);
|
||||
oVar2.a();
|
||||
ViewParent parent = oVar2.h.getParent();
|
||||
if (oVar2.f1564f && !oVar2.f1566j.f1540c.isInProgress() && !oVar2.f1565g) {
|
||||
int i10 = oVar2.f1574s;
|
||||
if ((i10 == 2 || ((i10 == 0 && f5 >= 1.0f) || ((i10 == 1 && f5 <= -1.0f) || (((i7 = oVar2.f1575t) == 0 && f6 >= 1.0f) || (i7 == 1 && f6 <= -1.0f))))) && parent != null) {
|
||||
parent.requestDisallowInterceptTouchEvent(false);
|
||||
}
|
||||
} else if (parent != null) {
|
||||
parent.requestDisallowInterceptTouchEvent(true);
|
||||
}
|
||||
}
|
||||
this.f1543f = x5;
|
||||
this.f1544g = y5;
|
||||
VelocityTracker velocityTracker2 = this.f1541d;
|
||||
if (velocityTracker2 != null) {
|
||||
velocityTracker2.addMovement(motionEvent);
|
||||
}
|
||||
}
|
||||
} else if (action == 3) {
|
||||
this.f1538a = -1;
|
||||
VelocityTracker velocityTracker3 = this.f1541d;
|
||||
if (velocityTracker3 != null) {
|
||||
velocityTracker3.recycle();
|
||||
this.f1541d = null;
|
||||
}
|
||||
} else if (action == 6) {
|
||||
int action2 = (motionEvent.getAction() & 65280) >> 8;
|
||||
if (motionEvent.getPointerId(action2) == this.f1538a) {
|
||||
int i11 = action2 != 0 ? 0 : 1;
|
||||
this.f1538a = motionEvent.getPointerId(i11);
|
||||
this.f1543f = motionEvent.getX(i11);
|
||||
this.f1544g = motionEvent.getY(i11);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
this.f1538a = motionEvent.getPointerId(0);
|
||||
VelocityTracker obtain = VelocityTracker.obtain();
|
||||
this.f1541d = obtain;
|
||||
if (obtain != null) {
|
||||
obtain.addMovement(motionEvent);
|
||||
}
|
||||
try {
|
||||
x3 = motionEvent.getX(this.f1539b);
|
||||
} catch (Exception unused5) {
|
||||
x3 = motionEvent.getX();
|
||||
}
|
||||
this.f1543f = x3;
|
||||
try {
|
||||
y3 = motionEvent.getY(this.f1539b);
|
||||
} catch (Exception unused6) {
|
||||
y3 = motionEvent.getY();
|
||||
}
|
||||
this.f1544g = y3;
|
||||
this.f1542e = false;
|
||||
}
|
||||
int i12 = this.f1538a;
|
||||
this.f1539b = motionEvent.findPointerIndex(i12 != -1 ? i12 : 0);
|
||||
}
|
||||
}
|
||||
5
apk_decompiled/sources/S1/c.java
Normal file
5
apk_decompiled/sources/S1/c.java
Normal file
@@ -0,0 +1,5 @@
|
||||
package S1;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public interface c {
|
||||
}
|
||||
5
apk_decompiled/sources/S1/d.java
Normal file
5
apk_decompiled/sources/S1/d.java
Normal file
@@ -0,0 +1,5 @@
|
||||
package S1;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public interface d {
|
||||
}
|
||||
5
apk_decompiled/sources/S1/e.java
Normal file
5
apk_decompiled/sources/S1/e.java
Normal file
@@ -0,0 +1,5 @@
|
||||
package S1;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public interface e {
|
||||
}
|
||||
5
apk_decompiled/sources/S1/f.java
Normal file
5
apk_decompiled/sources/S1/f.java
Normal file
@@ -0,0 +1,5 @@
|
||||
package S1;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public interface f {
|
||||
}
|
||||
5
apk_decompiled/sources/S1/g.java
Normal file
5
apk_decompiled/sources/S1/g.java
Normal file
@@ -0,0 +1,5 @@
|
||||
package S1;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public interface g {
|
||||
}
|
||||
5
apk_decompiled/sources/S1/h.java
Normal file
5
apk_decompiled/sources/S1/h.java
Normal file
@@ -0,0 +1,5 @@
|
||||
package S1;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public interface h {
|
||||
}
|
||||
5
apk_decompiled/sources/S1/i.java
Normal file
5
apk_decompiled/sources/S1/i.java
Normal file
@@ -0,0 +1,5 @@
|
||||
package S1;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public interface i {
|
||||
}
|
||||
31
apk_decompiled/sources/S1/j.java
Normal file
31
apk_decompiled/sources/S1/j.java
Normal file
@@ -0,0 +1,31 @@
|
||||
package S1;
|
||||
|
||||
import android.view.GestureDetector;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.View;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public final class j extends GestureDetector.SimpleOnGestureListener {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final /* synthetic */ o f1546a;
|
||||
|
||||
public j(o oVar) {
|
||||
this.f1546a = oVar;
|
||||
}
|
||||
|
||||
@Override // android.view.GestureDetector.SimpleOnGestureListener, android.view.GestureDetector.OnGestureListener
|
||||
public final boolean onFling(MotionEvent motionEvent, MotionEvent motionEvent2, float f2, float f4) {
|
||||
this.f1546a.getClass();
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override // android.view.GestureDetector.SimpleOnGestureListener, android.view.GestureDetector.OnGestureListener
|
||||
public final void onLongPress(MotionEvent motionEvent) {
|
||||
o oVar = this.f1546a;
|
||||
View.OnLongClickListener onLongClickListener = oVar.f1572q;
|
||||
if (onLongClickListener != null) {
|
||||
onLongClickListener.onLongClick(oVar.h);
|
||||
}
|
||||
}
|
||||
}
|
||||
75
apk_decompiled/sources/S1/k.java
Normal file
75
apk_decompiled/sources/S1/k.java
Normal file
@@ -0,0 +1,75 @@
|
||||
package S1;
|
||||
|
||||
import android.graphics.Matrix;
|
||||
import android.graphics.RectF;
|
||||
import android.view.GestureDetector;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.View;
|
||||
import com.google.android.gms.maps.model.BitmapDescriptorFactory;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public final class k implements GestureDetector.OnDoubleTapListener {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final /* synthetic */ o f1547a;
|
||||
|
||||
public k(o oVar) {
|
||||
this.f1547a = oVar;
|
||||
}
|
||||
|
||||
@Override // android.view.GestureDetector.OnDoubleTapListener
|
||||
public final boolean onDoubleTap(MotionEvent motionEvent) {
|
||||
o oVar = this.f1547a;
|
||||
try {
|
||||
float d4 = oVar.d();
|
||||
float x3 = motionEvent.getX();
|
||||
float y3 = motionEvent.getY();
|
||||
float f2 = oVar.f1562d;
|
||||
if (d4 < f2) {
|
||||
oVar.e(f2, x3, y3, true);
|
||||
} else {
|
||||
if (d4 >= f2) {
|
||||
float f4 = oVar.f1563e;
|
||||
if (d4 < f4) {
|
||||
oVar.e(f4, x3, y3, true);
|
||||
}
|
||||
}
|
||||
oVar.e(oVar.f1561c, x3, y3, true);
|
||||
}
|
||||
} catch (ArrayIndexOutOfBoundsException unused) {
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override // android.view.GestureDetector.OnDoubleTapListener
|
||||
public final boolean onDoubleTapEvent(MotionEvent motionEvent) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override // android.view.GestureDetector.OnDoubleTapListener
|
||||
public final boolean onSingleTapConfirmed(MotionEvent motionEvent) {
|
||||
RectF rectF;
|
||||
o oVar = this.f1547a;
|
||||
View.OnClickListener onClickListener = oVar.p;
|
||||
if (onClickListener != null) {
|
||||
onClickListener.onClick(oVar.h);
|
||||
}
|
||||
oVar.b();
|
||||
Matrix c4 = oVar.c();
|
||||
if (oVar.h.getDrawable() != null) {
|
||||
rectF = oVar.f1570n;
|
||||
rectF.set(BitmapDescriptorFactory.HUE_RED, BitmapDescriptorFactory.HUE_RED, r1.getIntrinsicWidth(), r1.getIntrinsicHeight());
|
||||
c4.mapRect(rectF);
|
||||
} else {
|
||||
rectF = null;
|
||||
}
|
||||
float x3 = motionEvent.getX();
|
||||
float y3 = motionEvent.getY();
|
||||
if (rectF == null || !rectF.contains(x3, y3)) {
|
||||
return false;
|
||||
}
|
||||
rectF.width();
|
||||
rectF.height();
|
||||
return true;
|
||||
}
|
||||
}
|
||||
31
apk_decompiled/sources/S1/l.java
Normal file
31
apk_decompiled/sources/S1/l.java
Normal file
@@ -0,0 +1,31 @@
|
||||
package S1;
|
||||
|
||||
import android.widget.ImageView;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public abstract /* synthetic */ class l {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public static final /* synthetic */ int[] f1548a;
|
||||
|
||||
static {
|
||||
int[] iArr = new int[ImageView.ScaleType.values().length];
|
||||
f1548a = iArr;
|
||||
try {
|
||||
iArr[ImageView.ScaleType.FIT_CENTER.ordinal()] = 1;
|
||||
} catch (NoSuchFieldError unused) {
|
||||
}
|
||||
try {
|
||||
f1548a[ImageView.ScaleType.FIT_START.ordinal()] = 2;
|
||||
} catch (NoSuchFieldError unused2) {
|
||||
}
|
||||
try {
|
||||
f1548a[ImageView.ScaleType.FIT_END.ordinal()] = 3;
|
||||
} catch (NoSuchFieldError unused3) {
|
||||
}
|
||||
try {
|
||||
f1548a[ImageView.ScaleType.FIT_XY.ordinal()] = 4;
|
||||
} catch (NoSuchFieldError unused4) {
|
||||
}
|
||||
}
|
||||
}
|
||||
44
apk_decompiled/sources/S1/m.java
Normal file
44
apk_decompiled/sources/S1/m.java
Normal file
@@ -0,0 +1,44 @@
|
||||
package S1;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public final class m implements Runnable {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final float f1549a;
|
||||
|
||||
/* renamed from: b, reason: collision with root package name */
|
||||
public final float f1550b;
|
||||
|
||||
/* renamed from: c, reason: collision with root package name */
|
||||
public final long f1551c = System.currentTimeMillis();
|
||||
|
||||
/* renamed from: d, reason: collision with root package name */
|
||||
public final float f1552d;
|
||||
|
||||
/* renamed from: e, reason: collision with root package name */
|
||||
public final float f1553e;
|
||||
|
||||
/* renamed from: f, reason: collision with root package name */
|
||||
public final /* synthetic */ o f1554f;
|
||||
|
||||
public m(o oVar, float f2, float f4, float f5, float f6) {
|
||||
this.f1554f = oVar;
|
||||
this.f1549a = f5;
|
||||
this.f1550b = f6;
|
||||
this.f1552d = f2;
|
||||
this.f1553e = f4;
|
||||
}
|
||||
|
||||
@Override // java.lang.Runnable
|
||||
public final void run() {
|
||||
float currentTimeMillis = ((float) (System.currentTimeMillis() - this.f1551c)) * 1.0f;
|
||||
o oVar = this.f1554f;
|
||||
float interpolation = oVar.f1559a.getInterpolation(Math.min(1.0f, currentTimeMillis / oVar.f1560b));
|
||||
float f2 = this.f1553e;
|
||||
float f4 = this.f1552d;
|
||||
oVar.f1578w.t(com.google.android.gms.measurement.internal.a.a(f2, f4, interpolation, f4) / oVar.d(), this.f1549a, this.f1550b);
|
||||
if (interpolation < 1.0f) {
|
||||
oVar.h.postOnAnimation(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
40
apk_decompiled/sources/S1/n.java
Normal file
40
apk_decompiled/sources/S1/n.java
Normal file
@@ -0,0 +1,40 @@
|
||||
package S1;
|
||||
|
||||
import android.content.Context;
|
||||
import android.widget.OverScroller;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public final class n implements Runnable {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final OverScroller f1555a;
|
||||
|
||||
/* renamed from: b, reason: collision with root package name */
|
||||
public int f1556b;
|
||||
|
||||
/* renamed from: c, reason: collision with root package name */
|
||||
public int f1557c;
|
||||
|
||||
/* renamed from: d, reason: collision with root package name */
|
||||
public final /* synthetic */ o f1558d;
|
||||
|
||||
public n(o oVar, Context context) {
|
||||
this.f1558d = oVar;
|
||||
this.f1555a = new OverScroller(context);
|
||||
}
|
||||
|
||||
@Override // java.lang.Runnable
|
||||
public final void run() {
|
||||
OverScroller overScroller = this.f1555a;
|
||||
if (!overScroller.isFinished() && overScroller.computeScrollOffset()) {
|
||||
int currX = overScroller.getCurrX();
|
||||
int currY = overScroller.getCurrY();
|
||||
o oVar = this.f1558d;
|
||||
oVar.f1569m.postTranslate(this.f1556b - currX, this.f1557c - currY);
|
||||
oVar.a();
|
||||
this.f1556b = currX;
|
||||
this.f1557c = currY;
|
||||
oVar.h.postOnAnimation(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
303
apk_decompiled/sources/S1/o.java
Normal file
303
apk_decompiled/sources/S1/o.java
Normal file
@@ -0,0 +1,303 @@
|
||||
package S1;
|
||||
|
||||
import android.graphics.Matrix;
|
||||
import android.graphics.RectF;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.view.GestureDetector;
|
||||
import android.view.View;
|
||||
import android.view.animation.AccelerateDecelerateInterpolator;
|
||||
import android.widget.ImageView;
|
||||
import com.github.chrisbanes.photoview.PhotoView;
|
||||
import com.google.android.gms.maps.model.BitmapDescriptorFactory;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public final class o implements View.OnTouchListener, View.OnLayoutChangeListener {
|
||||
public final PhotoView h;
|
||||
public final GestureDetector i;
|
||||
|
||||
/* renamed from: j, reason: collision with root package name */
|
||||
public final b f1566j;
|
||||
public View.OnClickListener p;
|
||||
|
||||
/* renamed from: q, reason: collision with root package name */
|
||||
public View.OnLongClickListener f1572q;
|
||||
|
||||
/* renamed from: r, reason: collision with root package name */
|
||||
public n f1573r;
|
||||
|
||||
/* renamed from: w, reason: collision with root package name */
|
||||
public final A.a f1578w;
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public final AccelerateDecelerateInterpolator f1559a = new AccelerateDecelerateInterpolator();
|
||||
|
||||
/* renamed from: b, reason: collision with root package name */
|
||||
public int f1560b = 200;
|
||||
|
||||
/* renamed from: c, reason: collision with root package name */
|
||||
public float f1561c = 1.0f;
|
||||
|
||||
/* renamed from: d, reason: collision with root package name */
|
||||
public float f1562d = 1.75f;
|
||||
|
||||
/* renamed from: e, reason: collision with root package name */
|
||||
public float f1563e = 3.0f;
|
||||
|
||||
/* renamed from: f, reason: collision with root package name */
|
||||
public boolean f1564f = true;
|
||||
|
||||
/* renamed from: g, reason: collision with root package name */
|
||||
public boolean f1565g = false;
|
||||
|
||||
/* renamed from: k, reason: collision with root package name */
|
||||
public final Matrix f1567k = new Matrix();
|
||||
|
||||
/* renamed from: l, reason: collision with root package name */
|
||||
public final Matrix f1568l = new Matrix();
|
||||
|
||||
/* renamed from: m, reason: collision with root package name */
|
||||
public final Matrix f1569m = new Matrix();
|
||||
|
||||
/* renamed from: n, reason: collision with root package name */
|
||||
public final RectF f1570n = new RectF();
|
||||
|
||||
/* renamed from: o, reason: collision with root package name */
|
||||
public final float[] f1571o = new float[9];
|
||||
|
||||
/* renamed from: s, reason: collision with root package name */
|
||||
public int f1574s = 2;
|
||||
|
||||
/* renamed from: t, reason: collision with root package name */
|
||||
public int f1575t = 2;
|
||||
|
||||
/* renamed from: u, reason: collision with root package name */
|
||||
public boolean f1576u = true;
|
||||
|
||||
/* renamed from: v, reason: collision with root package name */
|
||||
public ImageView.ScaleType f1577v = ImageView.ScaleType.FIT_CENTER;
|
||||
|
||||
public o(PhotoView photoView) {
|
||||
A.a aVar = new A.a(this, 15);
|
||||
this.f1578w = aVar;
|
||||
this.h = photoView;
|
||||
photoView.setOnTouchListener(this);
|
||||
photoView.addOnLayoutChangeListener(this);
|
||||
if (photoView.isInEditMode()) {
|
||||
return;
|
||||
}
|
||||
this.f1566j = new b(photoView.getContext(), aVar);
|
||||
GestureDetector gestureDetector = new GestureDetector(photoView.getContext(), new j(this));
|
||||
this.i = gestureDetector;
|
||||
gestureDetector.setOnDoubleTapListener(new k(this));
|
||||
}
|
||||
|
||||
public final void a() {
|
||||
if (b()) {
|
||||
this.h.setImageMatrix(c());
|
||||
}
|
||||
}
|
||||
|
||||
public final boolean b() {
|
||||
RectF rectF;
|
||||
float f2;
|
||||
float f4;
|
||||
float f5;
|
||||
float f6;
|
||||
float f7;
|
||||
Matrix c4 = c();
|
||||
Drawable drawable = this.h.getDrawable();
|
||||
float f8 = BitmapDescriptorFactory.HUE_RED;
|
||||
if (drawable != null) {
|
||||
rectF = this.f1570n;
|
||||
rectF.set(BitmapDescriptorFactory.HUE_RED, BitmapDescriptorFactory.HUE_RED, drawable.getIntrinsicWidth(), drawable.getIntrinsicHeight());
|
||||
c4.mapRect(rectF);
|
||||
} else {
|
||||
rectF = null;
|
||||
}
|
||||
if (rectF == null) {
|
||||
return false;
|
||||
}
|
||||
float height = rectF.height();
|
||||
float width = rectF.width();
|
||||
PhotoView photoView = this.h;
|
||||
float height2 = (photoView.getHeight() - photoView.getPaddingTop()) - photoView.getPaddingBottom();
|
||||
if (height <= height2) {
|
||||
int i = l.f1548a[this.f1577v.ordinal()];
|
||||
if (i != 2) {
|
||||
if (i != 3) {
|
||||
f6 = (height2 - height) / 2.0f;
|
||||
f7 = rectF.top;
|
||||
} else {
|
||||
f6 = height2 - height;
|
||||
f7 = rectF.top;
|
||||
}
|
||||
f2 = f6 - f7;
|
||||
} else {
|
||||
f2 = -rectF.top;
|
||||
}
|
||||
this.f1575t = 2;
|
||||
} else {
|
||||
float f9 = rectF.top;
|
||||
if (f9 > BitmapDescriptorFactory.HUE_RED) {
|
||||
this.f1575t = 0;
|
||||
f2 = -f9;
|
||||
} else {
|
||||
float f10 = rectF.bottom;
|
||||
if (f10 < height2) {
|
||||
this.f1575t = 1;
|
||||
f2 = height2 - f10;
|
||||
} else {
|
||||
this.f1575t = -1;
|
||||
f2 = 0.0f;
|
||||
}
|
||||
}
|
||||
}
|
||||
float width2 = (photoView.getWidth() - photoView.getPaddingLeft()) - photoView.getPaddingRight();
|
||||
if (width <= width2) {
|
||||
int i4 = l.f1548a[this.f1577v.ordinal()];
|
||||
if (i4 != 2) {
|
||||
if (i4 != 3) {
|
||||
f4 = (width2 - width) / 2.0f;
|
||||
f5 = rectF.left;
|
||||
} else {
|
||||
f4 = width2 - width;
|
||||
f5 = rectF.left;
|
||||
}
|
||||
f8 = f4 - f5;
|
||||
} else {
|
||||
f8 = -rectF.left;
|
||||
}
|
||||
this.f1574s = 2;
|
||||
} else {
|
||||
float f11 = rectF.left;
|
||||
if (f11 > BitmapDescriptorFactory.HUE_RED) {
|
||||
this.f1574s = 0;
|
||||
f8 = -f11;
|
||||
} else {
|
||||
float f12 = rectF.right;
|
||||
if (f12 < width2) {
|
||||
f8 = width2 - f12;
|
||||
this.f1574s = 1;
|
||||
} else {
|
||||
this.f1574s = -1;
|
||||
}
|
||||
}
|
||||
}
|
||||
this.f1569m.postTranslate(f8, f2);
|
||||
return true;
|
||||
}
|
||||
|
||||
public final Matrix c() {
|
||||
Matrix matrix = this.f1568l;
|
||||
matrix.set(this.f1567k);
|
||||
matrix.postConcat(this.f1569m);
|
||||
return matrix;
|
||||
}
|
||||
|
||||
public final float d() {
|
||||
Matrix matrix = this.f1569m;
|
||||
float[] fArr = this.f1571o;
|
||||
matrix.getValues(fArr);
|
||||
float pow = (float) Math.pow(fArr[0], 2.0d);
|
||||
matrix.getValues(fArr);
|
||||
return (float) Math.sqrt(pow + ((float) Math.pow(fArr[3], 2.0d)));
|
||||
}
|
||||
|
||||
public final void e(float f2, float f4, float f5, boolean z3) {
|
||||
if (f2 < this.f1561c || f2 > this.f1563e) {
|
||||
throw new IllegalArgumentException("Scale must be within the range of minScale and maxScale");
|
||||
}
|
||||
if (z3) {
|
||||
this.h.post(new m(this, d(), f2, f4, f5));
|
||||
} else {
|
||||
this.f1569m.setScale(f2, f2, f4, f5);
|
||||
a();
|
||||
}
|
||||
}
|
||||
|
||||
public final void f() {
|
||||
if (this.f1576u) {
|
||||
g(this.h.getDrawable());
|
||||
return;
|
||||
}
|
||||
Matrix matrix = this.f1569m;
|
||||
matrix.reset();
|
||||
matrix.postRotate(BitmapDescriptorFactory.HUE_RED);
|
||||
a();
|
||||
this.h.setImageMatrix(c());
|
||||
b();
|
||||
}
|
||||
|
||||
public final void g(Drawable drawable) {
|
||||
if (drawable == null) {
|
||||
return;
|
||||
}
|
||||
PhotoView photoView = this.h;
|
||||
float width = (photoView.getWidth() - photoView.getPaddingLeft()) - photoView.getPaddingRight();
|
||||
float height = (photoView.getHeight() - photoView.getPaddingTop()) - photoView.getPaddingBottom();
|
||||
int intrinsicWidth = drawable.getIntrinsicWidth();
|
||||
int intrinsicHeight = drawable.getIntrinsicHeight();
|
||||
Matrix matrix = this.f1567k;
|
||||
matrix.reset();
|
||||
float f2 = intrinsicWidth;
|
||||
float f4 = width / f2;
|
||||
float f5 = intrinsicHeight;
|
||||
float f6 = height / f5;
|
||||
ImageView.ScaleType scaleType = this.f1577v;
|
||||
if (scaleType == ImageView.ScaleType.CENTER) {
|
||||
matrix.postTranslate((width - f2) / 2.0f, (height - f5) / 2.0f);
|
||||
} else if (scaleType == ImageView.ScaleType.CENTER_CROP) {
|
||||
float max = Math.max(f4, f6);
|
||||
matrix.postScale(max, max);
|
||||
matrix.postTranslate((width - (f2 * max)) / 2.0f, (height - (f5 * max)) / 2.0f);
|
||||
} else if (scaleType == ImageView.ScaleType.CENTER_INSIDE) {
|
||||
float min = Math.min(1.0f, Math.min(f4, f6));
|
||||
matrix.postScale(min, min);
|
||||
matrix.postTranslate((width - (f2 * min)) / 2.0f, (height - (f5 * min)) / 2.0f);
|
||||
} else {
|
||||
RectF rectF = new RectF(BitmapDescriptorFactory.HUE_RED, BitmapDescriptorFactory.HUE_RED, f2, f5);
|
||||
RectF rectF2 = new RectF(BitmapDescriptorFactory.HUE_RED, BitmapDescriptorFactory.HUE_RED, width, height);
|
||||
if (((int) BitmapDescriptorFactory.HUE_RED) % 180 != 0) {
|
||||
rectF = new RectF(BitmapDescriptorFactory.HUE_RED, BitmapDescriptorFactory.HUE_RED, f5, f2);
|
||||
}
|
||||
int i = l.f1548a[this.f1577v.ordinal()];
|
||||
if (i == 1) {
|
||||
matrix.setRectToRect(rectF, rectF2, Matrix.ScaleToFit.CENTER);
|
||||
} else if (i == 2) {
|
||||
matrix.setRectToRect(rectF, rectF2, Matrix.ScaleToFit.START);
|
||||
} else if (i == 3) {
|
||||
matrix.setRectToRect(rectF, rectF2, Matrix.ScaleToFit.END);
|
||||
} else if (i == 4) {
|
||||
matrix.setRectToRect(rectF, rectF2, Matrix.ScaleToFit.FILL);
|
||||
}
|
||||
}
|
||||
Matrix matrix2 = this.f1569m;
|
||||
matrix2.reset();
|
||||
matrix2.postRotate(BitmapDescriptorFactory.HUE_RED);
|
||||
a();
|
||||
this.h.setImageMatrix(c());
|
||||
b();
|
||||
}
|
||||
|
||||
@Override // android.view.View.OnLayoutChangeListener
|
||||
public final void onLayoutChange(View view, int i, int i4, int i5, int i6, int i7, int i8, int i9, int i10) {
|
||||
if (i == i7 && i4 == i8 && i5 == i9 && i6 == i10) {
|
||||
return;
|
||||
}
|
||||
g(this.h.getDrawable());
|
||||
}
|
||||
|
||||
/* JADX WARN: Removed duplicated region for block: B:13:0x00c6 */
|
||||
@Override // android.view.View.OnTouchListener
|
||||
/*
|
||||
Code decompiled incorrectly, please refer to instructions dump.
|
||||
To view partially-correct add '--show-bad-code' argument
|
||||
*/
|
||||
public final boolean onTouch(android.view.View r9, android.view.MotionEvent r10) {
|
||||
/*
|
||||
Method dump skipped, instructions count: 254
|
||||
To view this dump add '--comments-level debug' option
|
||||
*/
|
||||
throw new UnsupportedOperationException("Method not decompiled: S1.o.onTouch(android.view.View, android.view.MotionEvent):boolean");
|
||||
}
|
||||
}
|
||||
19
apk_decompiled/sources/S1/p.java
Normal file
19
apk_decompiled/sources/S1/p.java
Normal file
@@ -0,0 +1,19 @@
|
||||
package S1;
|
||||
|
||||
import android.widget.ImageView;
|
||||
|
||||
/* loaded from: classes3.dex */
|
||||
public abstract /* synthetic */ class p {
|
||||
|
||||
/* renamed from: a, reason: collision with root package name */
|
||||
public static final /* synthetic */ int[] f1579a;
|
||||
|
||||
static {
|
||||
int[] iArr = new int[ImageView.ScaleType.values().length];
|
||||
f1579a = iArr;
|
||||
try {
|
||||
iArr[ImageView.ScaleType.MATRIX.ordinal()] = 1;
|
||||
} catch (NoSuchFieldError unused) {
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user