57 lines
1.7 KiB
Java
57 lines
1.7 KiB
Java
|
package com.scb.phone.view.custom.transferandpay;
|
||
|
|
||
|
import android.content.Context;
|
||
|
import android.text.TextUtils;
|
||
|
import android.util.AttributeSet;
|
||
|
import android.view.LayoutInflater;
|
||
|
import android.view.ViewGroup;
|
||
|
import android.widget.LinearLayout;
|
||
|
import android.widget.RelativeLayout;
|
||
|
import butterknife.BindView;
|
||
|
import butterknife.ButterKnife;
|
||
|
import com.scb.phone.R;
|
||
|
import o.C1168Xb;
|
||
|
import o.C1232Yo;
|
||
|
|
||
|
/* loaded from: classes5.dex */
|
||
|
public class CustomAmountInfo extends RelativeLayout {
|
||
|
|
||
|
@BindView
|
||
|
LinearLayout itemList;
|
||
|
|
||
|
public CustomAmountInfo(Context context, AttributeSet attributeSet) {
|
||
|
super(context, attributeSet);
|
||
|
((LayoutInflater) context.getSystemService("layout_inflater")).inflate(R.layout.2131558918, (ViewGroup) this, true);
|
||
|
ButterKnife.c(this);
|
||
|
}
|
||
|
|
||
|
public void setValues(C1168Xb c1168Xb) {
|
||
|
b(c1168Xb, false, false);
|
||
|
}
|
||
|
|
||
|
public void setValuesAligned(C1168Xb c1168Xb, boolean z) {
|
||
|
b(c1168Xb, true, z);
|
||
|
}
|
||
|
|
||
|
private void b(C1168Xb c1168Xb, boolean z, boolean z2) {
|
||
|
this.itemList.removeAllViews();
|
||
|
if (c1168Xb.a == null || c1168Xb.a.isEmpty()) {
|
||
|
return;
|
||
|
}
|
||
|
int size = c1168Xb.a.size();
|
||
|
int i = 0;
|
||
|
for (C1232Yo c1232Yo : c1168Xb.a) {
|
||
|
if (!TextUtils.isEmpty(c1232Yo.d) && !TextUtils.isEmpty(c1232Yo.e)) {
|
||
|
LinearLayout linearLayout = this.itemList;
|
||
|
Context context = getContext();
|
||
|
boolean z3 = true;
|
||
|
if (!z && size - 1 == i) {
|
||
|
z3 = false;
|
||
|
}
|
||
|
linearLayout.addView(new CustomAmountInfoItem(context, c1232Yo, z3, z2));
|
||
|
}
|
||
|
i++;
|
||
|
}
|
||
|
}
|
||
|
}
|