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

86 lines
2.5 KiB
Java
Raw Permalink Normal View History

2024-07-27 18:17:47 +07:00
package o;
import android.content.Context;
import android.view.View;
import android.view.ViewGroup;
import androidx.recyclerview.widget.RecyclerView;
import java.util.ArrayList;
import java.util.List;
/* renamed from: o.eqC, reason: case insensitive filesystem */
/* loaded from: classes5.dex */
public abstract class AbstractC12009eqC<T> extends RecyclerView.Sts<AbstractC12009eqC<T>.Sts> {
public View a;
public Context b;
public RVV<T> c;
public List<T> d = new ArrayList();
private View e;
private View f;
/* renamed from: o.eqC$RVV */
/* loaded from: classes5.dex */
public interface RVV<T> {
void b(T t);
}
protected abstract void a(AbstractC12009eqC<T>.Sts sts, int i);
protected abstract AbstractC12009eqC<T>.Sts any_(ViewGroup viewGroup);
@Override // androidx.recyclerview.widget.RecyclerView.Sts
public /* synthetic */ void onBindViewHolder(RecyclerView.zJl zjl, int i) {
AbstractC12009eqC<T>.Sts sts = (Sts) zjl;
if (getItemViewType(i) == 2) {
a(sts, i - (this.a == null ? 0 : 1));
}
}
public AbstractC12009eqC(Context context, View view, View view2) {
this.b = context;
this.f = view;
this.e = view2;
}
@Override // androidx.recyclerview.widget.RecyclerView.Sts
public int getItemViewType(int i) {
if (this.a != null && i == 0) {
return 0;
}
if (i == getItemCount() - 1) {
return 1;
}
return this.d.isEmpty() ? 3 : 2;
}
@Override // androidx.recyclerview.widget.RecyclerView.Sts
public int getItemCount() {
return (this.a == null ? 0 : 1) + (!this.d.isEmpty() ? this.d.size() + 1 : 2);
}
/* renamed from: o.eqC$Sts */
/* loaded from: classes5.dex */
public class Sts extends RecyclerView.zJl {
private AbstractC12009eqC d;
/* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
public Sts(AbstractC12009eqC abstractC12009eqC, View view) {
super(view);
this.d = abstractC12009eqC;
}
}
@Override // androidx.recyclerview.widget.RecyclerView.Sts
public /* synthetic */ RecyclerView.zJl onCreateViewHolder(ViewGroup viewGroup, int i) {
if (i == 2) {
return any_(viewGroup);
}
if (i == 0) {
return new Sts(this, this.a);
}
if (i == 1) {
return new Sts(this, this.f);
}
return new Sts(this, this.e);
}
}