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

54 lines
2.0 KiB
Java

package o;
import android.view.View;
import androidx.recyclerview.widget.RecyclerView;
/* loaded from: classes.dex */
public final class pNC {
public static int c(RecyclerView.AcL acL, MSs mSs, View view, View view2, RecyclerView.tOB tob, boolean z, boolean z2) {
int max;
if (tob.i_() != 0) {
if ((acL.c ? acL.i - acL.b : acL.h) != 0 && view != null && view2 != null) {
int min = Math.min(RecyclerView.tOB.f(view), RecyclerView.tOB.f(view2));
int max2 = Math.max(RecyclerView.tOB.f(view), RecyclerView.tOB.f(view2));
if (z2) {
max = Math.max(0, ((acL.c ? acL.i - acL.b : acL.h) - max2) - 1);
} else {
max = Math.max(0, min);
}
if (z) {
return Math.round((max * (Math.abs(mSs.a(view2) - mSs.c(view)) / (Math.abs(RecyclerView.tOB.f(view) - RecyclerView.tOB.f(view2)) + 1))) + (mSs.i() - mSs.c(view)));
}
return max;
}
}
return 0;
}
public static int b(RecyclerView.AcL acL, MSs mSs, View view, View view2, RecyclerView.tOB tob, boolean z) {
if (tob.i_() == 0) {
return 0;
}
if ((acL.c ? acL.i - acL.b : acL.h) == 0 || view == null || view2 == null) {
return 0;
}
if (!z) {
return Math.abs(RecyclerView.tOB.f(view) - RecyclerView.tOB.f(view2)) + 1;
}
return Math.min(mSs.h(), mSs.a(view2) - mSs.c(view));
}
public static int c(RecyclerView.AcL acL, MSs mSs, View view, View view2, RecyclerView.tOB tob, boolean z) {
if (tob.i_() == 0) {
return 0;
}
if ((acL.c ? acL.i - acL.b : acL.h) == 0 || view == null || view2 == null) {
return 0;
}
if (z) {
return (int) (((mSs.a(view2) - mSs.c(view)) / (Math.abs(RecyclerView.tOB.f(view) - RecyclerView.tOB.f(view2)) + 1)) * (acL.c ? acL.i - acL.b : acL.h));
}
return acL.c ? acL.i - acL.b : acL.h;
}
}