134 lines
5.0 KiB
Java
134 lines
5.0 KiB
Java
|
package com.scb.phone.view.adapter.moneyaction;
|
||
|
|
||
|
import android.view.LayoutInflater;
|
||
|
import android.view.View;
|
||
|
import android.view.ViewGroup;
|
||
|
import android.widget.ImageView;
|
||
|
import android.widget.TextView;
|
||
|
import androidx.recyclerview.widget.RecyclerView;
|
||
|
import butterknife.BindView;
|
||
|
import butterknife.ButterKnife;
|
||
|
import butterknife.Unbinder;
|
||
|
import com.scb.phone.R;
|
||
|
import com.scb.phone.view.adapter.moneyaction.MoneyActionAdapter;
|
||
|
import java.util.List;
|
||
|
import o.InterfaceC12825fIZ;
|
||
|
import o.pyT;
|
||
|
|
||
|
/* loaded from: classes5.dex */
|
||
|
public final class MoneyActionAdapter extends RecyclerView.Sts<CustomViewHolder> {
|
||
|
private List<Integer> c;
|
||
|
private InterfaceC12825fIZ e;
|
||
|
|
||
|
/* loaded from: classes5.dex */
|
||
|
public class CustomViewHolder_ViewBinding implements Unbinder {
|
||
|
private CustomViewHolder c;
|
||
|
|
||
|
public CustomViewHolder_ViewBinding(CustomViewHolder customViewHolder, View view) {
|
||
|
this.c = customViewHolder;
|
||
|
customViewHolder.icon = (ImageView) pyT.e(view, R.id.money_action_icon, "field 'icon'", ImageView.class);
|
||
|
customViewHolder.description = (TextView) pyT.e(view, R.id.money_action_description, "field 'description'", TextView.class);
|
||
|
}
|
||
|
|
||
|
@Override // butterknife.Unbinder
|
||
|
public final void a() {
|
||
|
CustomViewHolder customViewHolder = this.c;
|
||
|
if (customViewHolder == null) {
|
||
|
throw new IllegalStateException("Bindings already cleared.");
|
||
|
}
|
||
|
this.c = null;
|
||
|
customViewHolder.icon = null;
|
||
|
customViewHolder.description = null;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
@Override // androidx.recyclerview.widget.RecyclerView.Sts
|
||
|
public final /* synthetic */ void onBindViewHolder(CustomViewHolder customViewHolder, int i) {
|
||
|
CustomViewHolder customViewHolder2 = customViewHolder;
|
||
|
Integer num = this.c.get(i);
|
||
|
customViewHolder2.b = num.intValue();
|
||
|
int intValue = num.intValue();
|
||
|
if (intValue == 0) {
|
||
|
customViewHolder2.icon.setImageResource(R.drawable.ic_request_money);
|
||
|
customViewHolder2.description.setText(R.string.money_action_request_money_new);
|
||
|
return;
|
||
|
}
|
||
|
if (intValue == 1) {
|
||
|
customViewHolder2.icon.setImageResource(R.drawable.ic_cardless_atm);
|
||
|
customViewHolder2.description.setText(R.string.money_action_cardless_atm);
|
||
|
return;
|
||
|
}
|
||
|
if (intValue == 2) {
|
||
|
customViewHolder2.icon.setImageResource(R.drawable.ic_scan);
|
||
|
customViewHolder2.description.setText(R.string.money_action_scan);
|
||
|
return;
|
||
|
}
|
||
|
if (intValue == 3) {
|
||
|
customViewHolder2.icon.setImageResource(R.drawable.ic_top_up);
|
||
|
customViewHolder2.description.setText(R.string.money_action_top_up);
|
||
|
} else if (intValue == 4) {
|
||
|
customViewHolder2.icon.setImageResource(R.drawable.ic_transfer);
|
||
|
customViewHolder2.description.setText(R.string.money_action_transfer);
|
||
|
} else if (intValue == 5) {
|
||
|
customViewHolder2.icon.setImageResource(R.drawable.ic_bill_payment);
|
||
|
customViewHolder2.description.setText(R.string.money_action_bill_payment);
|
||
|
}
|
||
|
}
|
||
|
|
||
|
public MoneyActionAdapter(InterfaceC12825fIZ interfaceC12825fIZ, List<Integer> list) {
|
||
|
this.e = interfaceC12825fIZ;
|
||
|
this.c = list;
|
||
|
}
|
||
|
|
||
|
@Override // androidx.recyclerview.widget.RecyclerView.Sts
|
||
|
public final int getItemCount() {
|
||
|
List<Integer> list = this.c;
|
||
|
if (list == null) {
|
||
|
return 0;
|
||
|
}
|
||
|
return list.size();
|
||
|
}
|
||
|
|
||
|
/* loaded from: classes5.dex */
|
||
|
public class CustomViewHolder extends RecyclerView.zJl {
|
||
|
int b;
|
||
|
|
||
|
@BindView
|
||
|
TextView description;
|
||
|
private MoneyActionAdapter e;
|
||
|
|
||
|
@BindView
|
||
|
ImageView icon;
|
||
|
|
||
|
/* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
|
||
|
CustomViewHolder(MoneyActionAdapter moneyActionAdapter, View view) {
|
||
|
super(view);
|
||
|
this.e = moneyActionAdapter;
|
||
|
ButterKnife.c(this, view);
|
||
|
view.setOnClickListener(new View.OnClickListener(this) { // from class: o.exb
|
||
|
private MoneyActionAdapter.CustomViewHolder d;
|
||
|
|
||
|
@Override // android.view.View.OnClickListener
|
||
|
public final void onClick(View view2) {
|
||
|
MoneyActionAdapter.CustomViewHolder.d(this.d);
|
||
|
}
|
||
|
|
||
|
{
|
||
|
this.d = this;
|
||
|
}
|
||
|
});
|
||
|
}
|
||
|
|
||
|
public static /* synthetic */ void d(CustomViewHolder customViewHolder) {
|
||
|
if (customViewHolder.e.e != null) {
|
||
|
customViewHolder.e.e.a(customViewHolder.b);
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
|
||
|
@Override // androidx.recyclerview.widget.RecyclerView.Sts
|
||
|
public final /* synthetic */ CustomViewHolder onCreateViewHolder(ViewGroup viewGroup, int i) {
|
||
|
return new CustomViewHolder(this, LayoutInflater.from(viewGroup.getContext()).inflate(R.layout.2131559182, (ViewGroup) null));
|
||
|
}
|
||
|
}
|