325 lines
14 KiB
Java
325 lines
14 KiB
Java
|
package com.scb.phone.view.adapter.creditcard;
|
||
|
|
||
|
import android.content.Context;
|
||
|
import android.graphics.PorterDuff;
|
||
|
import android.view.LayoutInflater;
|
||
|
import android.view.View;
|
||
|
import android.view.ViewGroup;
|
||
|
import android.widget.ImageView;
|
||
|
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.IA;
|
||
|
import o.IC;
|
||
|
import o.nMh;
|
||
|
import o.pyT;
|
||
|
|
||
|
/* loaded from: classes5.dex */
|
||
|
public final class CreditCardDetailUnbilledAdapter extends BaseExpandableRecycleViewAdapter {
|
||
|
public IA d;
|
||
|
|
||
|
@Override // o.pvT, o.Qpt
|
||
|
public final int c(int i) {
|
||
|
return i == 0 ? 0 : 1;
|
||
|
}
|
||
|
|
||
|
/* 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.foreignCurrency = (TextView) pyT.e(view, R.id.unbilled_foreign_currency_value, "field 'foreignCurrency'", TextView.class);
|
||
|
childViewHolder.originalCurrencyTextView = (TextView) pyT.e(view, R.id.original_currency_text_view, "field 'originalCurrencyTextView'", TextView.class);
|
||
|
childViewHolder.postDateTextView = (TextView) pyT.e(view, R.id.post_date_text_view, "field 'postDateTextView'", TextView.class);
|
||
|
childViewHolder.categoriesTextView = (TextView) pyT.e(view, R.id.categories_text_view, "field 'categoriesTextView'", TextView.class);
|
||
|
childViewHolder.descriptionTextView = (TextView) pyT.e(view, R.id.description_text_view, "field 'descriptionTextView'", 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.foreignCurrency = null;
|
||
|
childViewHolder.originalCurrencyTextView = null;
|
||
|
childViewHolder.postDateTextView = null;
|
||
|
childViewHolder.categoriesTextView = null;
|
||
|
childViewHolder.descriptionTextView = null;
|
||
|
childViewHolder.category = null;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
/* loaded from: classes5.dex */
|
||
|
public class HeaderViewHolder_ViewBinding implements Unbinder {
|
||
|
private HeaderViewHolder e;
|
||
|
|
||
|
public HeaderViewHolder_ViewBinding(HeaderViewHolder headerViewHolder, View view) {
|
||
|
this.e = headerViewHolder;
|
||
|
headerViewHolder.headerTitle = (TextView) pyT.e(view, R.id.unbilled_header_title_text_view, "field 'headerTitle'", TextView.class);
|
||
|
headerViewHolder.headerValue = (TextView) pyT.e(view, R.id.unbilled_header_value_text_view, "field 'headerValue'", TextView.class);
|
||
|
}
|
||
|
|
||
|
@Override // butterknife.Unbinder
|
||
|
public final void a() {
|
||
|
HeaderViewHolder headerViewHolder = this.e;
|
||
|
if (headerViewHolder == null) {
|
||
|
throw new IllegalStateException("Bindings already cleared.");
|
||
|
}
|
||
|
this.e = null;
|
||
|
headerViewHolder.headerTitle = null;
|
||
|
headerViewHolder.headerValue = null;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
/* loaded from: classes5.dex */
|
||
|
public class ParentViewHolder_ViewBinding extends BaseExpandableRecycleViewAdapter.BaseParentViewHolder_ViewBinding {
|
||
|
private ParentViewHolder e;
|
||
|
|
||
|
public ParentViewHolder_ViewBinding(ParentViewHolder parentViewHolder, View view) {
|
||
|
super(parentViewHolder, view);
|
||
|
this.e = parentViewHolder;
|
||
|
parentViewHolder.container = (RelativeLayout) pyT.e(view, R.id.unbilled_container, "field 'container'", RelativeLayout.class);
|
||
|
parentViewHolder.title = (TextView) pyT.e(view, R.id.unbilled_title, "field 'title'", TextView.class);
|
||
|
parentViewHolder.pending = (TextView) pyT.e(view, R.id.unbilled_pending, "field 'pending'", TextView.class);
|
||
|
parentViewHolder.type = (TextView) pyT.e(view, R.id.unbilled_type, "field 'type'", TextView.class);
|
||
|
parentViewHolder.value = (TextView) pyT.e(view, R.id.unbilled_value, "field 'value'", TextView.class);
|
||
|
parentViewHolder.date = (TextView) pyT.e(view, R.id.unbilled_date, "field 'date'", TextView.class);
|
||
|
parentViewHolder.line = pyT.a(view, R.id.unbilled_line, "field 'line'");
|
||
|
parentViewHolder.verticalLine = pyT.a(view, R.id.unbilled_vertical_line_view, "field 'verticalLine'");
|
||
|
parentViewHolder.expandIconImageView = (ImageView) pyT.e(view, R.id.expand_icon_image_view, "field 'expandIconImageView'", ImageView.class);
|
||
|
}
|
||
|
|
||
|
@Override // com.scb.phone.view.adapter.BaseExpandableRecycleViewAdapter.BaseParentViewHolder_ViewBinding, butterknife.Unbinder
|
||
|
public final void a() {
|
||
|
ParentViewHolder parentViewHolder = this.e;
|
||
|
if (parentViewHolder == null) {
|
||
|
throw new IllegalStateException("Bindings already cleared.");
|
||
|
}
|
||
|
this.e = null;
|
||
|
parentViewHolder.container = null;
|
||
|
parentViewHolder.title = null;
|
||
|
parentViewHolder.pending = null;
|
||
|
parentViewHolder.type = null;
|
||
|
parentViewHolder.value = null;
|
||
|
parentViewHolder.date = null;
|
||
|
parentViewHolder.line = null;
|
||
|
parentViewHolder.verticalLine = null;
|
||
|
parentViewHolder.expandIconImageView = null;
|
||
|
super.a();
|
||
|
}
|
||
|
}
|
||
|
|
||
|
public CreditCardDetailUnbilledAdapter(Context context, IA ia) {
|
||
|
super(context);
|
||
|
this.d = ia;
|
||
|
}
|
||
|
|
||
|
@Override // o.Qpt
|
||
|
public final RecyclerView.zJl anX_(ViewGroup viewGroup, int i) {
|
||
|
LayoutInflater from = LayoutInflater.from(viewGroup.getContext());
|
||
|
if (i == 0) {
|
||
|
return new HeaderViewHolder(from.inflate(R.layout.2131559092, viewGroup, false));
|
||
|
}
|
||
|
return new ParentViewHolder(from.inflate(R.layout.2131559093, 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) {
|
||
|
if (zjl instanceof HeaderViewHolder) {
|
||
|
HeaderViewHolder headerViewHolder = (HeaderViewHolder) zjl;
|
||
|
headerViewHolder.headerTitle.setText(this.b.getString(R.string.credit_card_bills_unbilled));
|
||
|
headerViewHolder.headerValue.setText(this.d.c);
|
||
|
return;
|
||
|
}
|
||
|
if (zjl instanceof ParentViewHolder) {
|
||
|
ParentViewHolder parentViewHolder = (ParentViewHolder) zjl;
|
||
|
IC ic = this.d.a.get(i - 1);
|
||
|
parentViewHolder.title.setText(ic.a);
|
||
|
parentViewHolder.value.setText(ic.m);
|
||
|
parentViewHolder.date.setText(ic.n);
|
||
|
parentViewHolder.pending.setVisibility(8);
|
||
|
if (i > 1 && i < this.d.a.size() + 1) {
|
||
|
parentViewHolder.line.setVisibility(0);
|
||
|
} else {
|
||
|
parentViewHolder.line.setVisibility(4);
|
||
|
}
|
||
|
if (i == this.d.a.size()) {
|
||
|
parentViewHolder.verticalLine.setVisibility(8);
|
||
|
} else {
|
||
|
parentViewHolder.verticalLine.setVisibility(0);
|
||
|
}
|
||
|
if (ic.f) {
|
||
|
parentViewHolder.expandIconImageView.setColorFilter(nMh.getColor(this.b, R.color.f3412131099849), PorterDuff.Mode.SRC_ATOP);
|
||
|
parentViewHolder.pending.setVisibility(0);
|
||
|
parentViewHolder.value.setText(ic.d);
|
||
|
parentViewHolder.title.setTextColor(nMh.getColor(this.b, R.color.f3412131099849));
|
||
|
parentViewHolder.value.setTextColor(nMh.getColor(this.b, R.color.f3412131099849));
|
||
|
parentViewHolder.date.setTextColor(nMh.getColor(this.b, R.color.f3412131099849));
|
||
|
} else {
|
||
|
parentViewHolder.expandIconImageView.setColorFilter(nMh.getColor(this.b, R.color.f2982131099805), PorterDuff.Mode.SRC_ATOP);
|
||
|
parentViewHolder.title.setTextColor(nMh.getColor(this.b, R.color.f2982131099805));
|
||
|
parentViewHolder.date.setTextColor(nMh.getColor(this.b, R.color.f3412131099849));
|
||
|
parentViewHolder.value.setTextColor(ic.b ? this.b.getColor(R.color.f2722131099779) : this.b.getColor(R.color.f2982131099805));
|
||
|
}
|
||
|
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;
|
||
|
IC ic = this.d.a.get(i - 1);
|
||
|
childViewHolder.description.setText(ic.a);
|
||
|
childViewHolder.postDate.setText(ic.h);
|
||
|
childViewHolder.foreignCurrency.setText(ic.d);
|
||
|
childViewHolder.category.setText(ic.c);
|
||
|
if (ic.f) {
|
||
|
childViewHolder.originalCurrencyTextView.setVisibility(8);
|
||
|
childViewHolder.foreignCurrency.setVisibility(8);
|
||
|
childViewHolder.postDateTextView.setTextColor(nMh.getColor(this.b, R.color.f3412131099849));
|
||
|
childViewHolder.description.setTextColor(nMh.getColor(this.b, R.color.f3412131099849));
|
||
|
childViewHolder.descriptionTextView.setTextColor(nMh.getColor(this.b, R.color.f3412131099849));
|
||
|
childViewHolder.postDate.setTextColor(nMh.getColor(this.b, R.color.f3412131099849));
|
||
|
childViewHolder.category.setTextColor(nMh.getColor(this.b, R.color.f3412131099849));
|
||
|
childViewHolder.categoriesTextView.setTextColor(nMh.getColor(this.b, R.color.f3412131099849));
|
||
|
} else {
|
||
|
childViewHolder.originalCurrencyTextView.setVisibility(0);
|
||
|
childViewHolder.foreignCurrency.setVisibility(0);
|
||
|
childViewHolder.postDateTextView.setTextColor(nMh.getColor(this.b, R.color.f2272131099733));
|
||
|
childViewHolder.description.setTextColor(nMh.getColor(this.b, R.color.f2982131099805));
|
||
|
childViewHolder.descriptionTextView.setTextColor(nMh.getColor(this.b, R.color.f2272131099733));
|
||
|
childViewHolder.postDate.setTextColor(nMh.getColor(this.b, R.color.f2982131099805));
|
||
|
childViewHolder.category.setTextColor(nMh.getColor(this.b, R.color.f2982131099805));
|
||
|
childViewHolder.categoriesTextView.setTextColor(nMh.getColor(this.b, R.color.f2272131099733));
|
||
|
}
|
||
|
if (ic.j) {
|
||
|
childViewHolder.originalCurrencyTextView.setVisibility(8);
|
||
|
childViewHolder.foreignCurrency.setVisibility(8);
|
||
|
} else {
|
||
|
if (ic.f) {
|
||
|
return;
|
||
|
}
|
||
|
childViewHolder.originalCurrencyTextView.setVisibility(0);
|
||
|
childViewHolder.foreignCurrency.setVisibility(0);
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
|
||
|
@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 HeaderViewHolder extends AbstractC5347brN {
|
||
|
|
||
|
@BindView
|
||
|
TextView headerTitle;
|
||
|
|
||
|
@BindView
|
||
|
TextView headerValue;
|
||
|
|
||
|
HeaderViewHolder(View view) {
|
||
|
super(view);
|
||
|
ButterKnife.c(this, view);
|
||
|
RecyclerView.saX sax = (RecyclerView.saX) view.getLayoutParams();
|
||
|
((ViewGroup.LayoutParams) sax).height = 0;
|
||
|
view.setLayoutParams(sax);
|
||
|
}
|
||
|
}
|
||
|
|
||
|
/* loaded from: classes5.dex */
|
||
|
static class ParentViewHolder extends BaseExpandableRecycleViewAdapter.BaseParentViewHolder {
|
||
|
|
||
|
@BindView
|
||
|
RelativeLayout container;
|
||
|
|
||
|
@BindView
|
||
|
TextView date;
|
||
|
|
||
|
@BindView
|
||
|
ImageView expandIconImageView;
|
||
|
|
||
|
@BindView
|
||
|
View line;
|
||
|
|
||
|
@BindView
|
||
|
TextView pending;
|
||
|
|
||
|
@BindView
|
||
|
TextView title;
|
||
|
|
||
|
@BindView
|
||
|
TextView type;
|
||
|
|
||
|
@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 categoriesTextView;
|
||
|
|
||
|
@BindView
|
||
|
TextView category;
|
||
|
|
||
|
@BindView
|
||
|
TextView description;
|
||
|
|
||
|
@BindView
|
||
|
TextView descriptionTextView;
|
||
|
|
||
|
@BindView
|
||
|
TextView foreignCurrency;
|
||
|
|
||
|
@BindView
|
||
|
TextView originalCurrencyTextView;
|
||
|
|
||
|
@BindView
|
||
|
TextView postDate;
|
||
|
|
||
|
@BindView
|
||
|
TextView postDateTextView;
|
||
|
|
||
|
ChildViewHolder(View view) {
|
||
|
super(view);
|
||
|
ButterKnife.c(this, view);
|
||
|
}
|
||
|
}
|
||
|
|
||
|
@Override // o.Qpt
|
||
|
public final int d() {
|
||
|
return this.d.a.size() + 1;
|
||
|
}
|
||
|
}
|