213 lines
7.9 KiB
Java
213 lines
7.9 KiB
Java
package com.scb.phone.view.adapter.creditcard;
|
|
|
|
import android.content.Context;
|
|
import android.view.LayoutInflater;
|
|
import android.view.View;
|
|
import android.view.ViewGroup;
|
|
import android.widget.RelativeLayout;
|
|
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.BaseExpandableRecycleViewAdapter;
|
|
import o.AbstractC5347brN;
|
|
import o.C0529Iu;
|
|
import o.C0530Iv;
|
|
import o.pyT;
|
|
|
|
/* loaded from: classes5.dex */
|
|
public final class CreditCardBilledDetailAdapter extends BaseExpandableRecycleViewAdapter {
|
|
private C0530Iv c;
|
|
|
|
/* loaded from: classes5.dex */
|
|
public class ChildViewHolder_ViewBinding implements Unbinder {
|
|
private ChildViewHolder b;
|
|
|
|
public ChildViewHolder_ViewBinding(ChildViewHolder childViewHolder, View view) {
|
|
this.b = childViewHolder;
|
|
childViewHolder.description = (TextView) pyT.e(view, R.id.unbilled_description_value, "field 'description'", TextView.class);
|
|
childViewHolder.postDate = (TextView) pyT.e(view, R.id.unbilled_post_date_value, "field 'postDate'", TextView.class);
|
|
childViewHolder.originalCurrency = (TextView) pyT.e(view, R.id.original_currency_text_view, "field 'originalCurrency'", TextView.class);
|
|
childViewHolder.foreignCurrency = (TextView) pyT.e(view, R.id.unbilled_foreign_currency_value, "field 'foreignCurrency'", TextView.class);
|
|
childViewHolder.category = (TextView) pyT.e(view, R.id.unbilled_category_value, "field 'category'", TextView.class);
|
|
}
|
|
|
|
@Override // butterknife.Unbinder
|
|
public final void a() {
|
|
ChildViewHolder childViewHolder = this.b;
|
|
if (childViewHolder == null) {
|
|
throw new IllegalStateException("Bindings already cleared.");
|
|
}
|
|
this.b = null;
|
|
childViewHolder.description = null;
|
|
childViewHolder.postDate = null;
|
|
childViewHolder.originalCurrency = null;
|
|
childViewHolder.foreignCurrency = null;
|
|
childViewHolder.category = null;
|
|
}
|
|
}
|
|
|
|
/* loaded from: classes5.dex */
|
|
public class ParentViewHolder_ViewBinding extends BaseExpandableRecycleViewAdapter.BaseParentViewHolder_ViewBinding {
|
|
private ParentViewHolder b;
|
|
|
|
public ParentViewHolder_ViewBinding(ParentViewHolder parentViewHolder, View view) {
|
|
super(parentViewHolder, view);
|
|
this.b = parentViewHolder;
|
|
parentViewHolder.container = (RelativeLayout) pyT.e(view, R.id.billed_detail_container, "field 'container'", RelativeLayout.class);
|
|
parentViewHolder.title = (TextView) pyT.e(view, R.id.billed_detail_title, "field 'title'", TextView.class);
|
|
parentViewHolder.value = (TextView) pyT.e(view, R.id.billed_detail_value, "field 'value'", TextView.class);
|
|
parentViewHolder.date = (TextView) pyT.e(view, R.id.billed_detail_date, "field 'date'", TextView.class);
|
|
parentViewHolder.line = pyT.a(view, R.id.billed_line, "field 'line'");
|
|
parentViewHolder.verticalLine = pyT.a(view, R.id.billed_vertical_line_view, "field 'verticalLine'");
|
|
}
|
|
|
|
@Override // com.scb.phone.view.adapter.BaseExpandableRecycleViewAdapter.BaseParentViewHolder_ViewBinding, butterknife.Unbinder
|
|
public final void a() {
|
|
ParentViewHolder parentViewHolder = this.b;
|
|
if (parentViewHolder == null) {
|
|
throw new IllegalStateException("Bindings already cleared.");
|
|
}
|
|
this.b = null;
|
|
parentViewHolder.container = null;
|
|
parentViewHolder.title = null;
|
|
parentViewHolder.value = null;
|
|
parentViewHolder.date = null;
|
|
parentViewHolder.line = null;
|
|
parentViewHolder.verticalLine = null;
|
|
super.a();
|
|
}
|
|
}
|
|
|
|
public CreditCardBilledDetailAdapter(Context context, C0530Iv c0530Iv) {
|
|
super(context);
|
|
this.c = c0530Iv;
|
|
}
|
|
|
|
@Override // o.Qpt
|
|
public final RecyclerView.zJl anX_(ViewGroup viewGroup, int i) {
|
|
return new ParentViewHolder(LayoutInflater.from(viewGroup.getContext()).inflate(R.layout.2131559086, viewGroup, false));
|
|
}
|
|
|
|
@Override // o.Qpt
|
|
public final RecyclerView.zJl anW_(ViewGroup viewGroup, int i) {
|
|
return new ChildViewHolder(LayoutInflater.from(viewGroup.getContext()).inflate(R.layout.2131559091, viewGroup, false));
|
|
}
|
|
|
|
@Override // o.Qpt
|
|
public final void d(RecyclerView.zJl zjl, int i) {
|
|
Context context;
|
|
int i2;
|
|
if (zjl instanceof ParentViewHolder) {
|
|
ParentViewHolder parentViewHolder = (ParentViewHolder) zjl;
|
|
C0529Iu c0529Iu = this.c.h.get(i);
|
|
parentViewHolder.title.setText(c0529Iu.d);
|
|
parentViewHolder.date.setText(c0529Iu.l);
|
|
parentViewHolder.value.setText(c0529Iu.g);
|
|
if (i > 0 && i < this.c.h.size()) {
|
|
parentViewHolder.line.setVisibility(0);
|
|
} else {
|
|
parentViewHolder.line.setVisibility(4);
|
|
}
|
|
if (i == this.c.h.size() - 1) {
|
|
parentViewHolder.verticalLine.setVisibility(8);
|
|
} else {
|
|
parentViewHolder.verticalLine.setVisibility(0);
|
|
}
|
|
TextView textView = parentViewHolder.value;
|
|
if (c0529Iu.a) {
|
|
context = this.b;
|
|
i2 = R.color.f2722131099779;
|
|
} else {
|
|
context = this.b;
|
|
i2 = R.color.f2982131099805;
|
|
}
|
|
textView.setTextColor(context.getColor(i2));
|
|
BaseExpandableRecycleViewAdapter.a(parentViewHolder);
|
|
}
|
|
}
|
|
|
|
@Override // o.Qpt
|
|
public final void c(RecyclerView.zJl zjl, int i, int i2) {
|
|
if (zjl instanceof ChildViewHolder) {
|
|
ChildViewHolder childViewHolder = (ChildViewHolder) zjl;
|
|
C0529Iu c0529Iu = this.c.h.get(i);
|
|
childViewHolder.category.setText(c0529Iu.b);
|
|
childViewHolder.description.setText(c0529Iu.d);
|
|
childViewHolder.postDate.setText(c0529Iu.j);
|
|
if (c0529Iu.h == null || c0529Iu.h.isEmpty() || c0529Iu.h.equals("THB")) {
|
|
childViewHolder.originalCurrency.setVisibility(8);
|
|
childViewHolder.foreignCurrency.setVisibility(8);
|
|
} else {
|
|
childViewHolder.originalCurrency.setVisibility(0);
|
|
childViewHolder.foreignCurrency.setVisibility(0);
|
|
childViewHolder.originalCurrency.setText(R.string.credit_card_billed_foreign_currency);
|
|
childViewHolder.foreignCurrency.setText(c0529Iu.f);
|
|
}
|
|
}
|
|
}
|
|
|
|
@Override // com.scb.phone.view.adapter.BaseExpandableRecycleViewAdapter, o.Qpt
|
|
public final boolean b(RecyclerView.zJl zjl) {
|
|
return zjl instanceof ParentViewHolder;
|
|
}
|
|
|
|
/* loaded from: classes5.dex */
|
|
static class ParentViewHolder extends BaseExpandableRecycleViewAdapter.BaseParentViewHolder {
|
|
|
|
@BindView
|
|
RelativeLayout container;
|
|
|
|
@BindView
|
|
TextView date;
|
|
|
|
@BindView
|
|
View line;
|
|
|
|
@BindView
|
|
TextView title;
|
|
|
|
@BindView
|
|
TextView value;
|
|
|
|
@BindView
|
|
View verticalLine;
|
|
|
|
ParentViewHolder(View view) {
|
|
super(view);
|
|
ButterKnife.c(this, view);
|
|
}
|
|
}
|
|
|
|
/* loaded from: classes5.dex */
|
|
static class ChildViewHolder extends AbstractC5347brN {
|
|
|
|
@BindView
|
|
TextView category;
|
|
|
|
@BindView
|
|
TextView description;
|
|
|
|
@BindView
|
|
TextView foreignCurrency;
|
|
|
|
@BindView
|
|
TextView originalCurrency;
|
|
|
|
@BindView
|
|
TextView postDate;
|
|
|
|
ChildViewHolder(View view) {
|
|
super(view);
|
|
ButterKnife.c(this, view);
|
|
}
|
|
}
|
|
|
|
@Override // o.Qpt
|
|
public final int d() {
|
|
return this.c.h.size();
|
|
}
|
|
}
|