package com.scb.phone.view.fragment.cardmanagement; import android.content.Context; import android.content.Intent; import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.TextView; import butterknife.BindView; import butterknife.ButterKnife; import butterknife.OnClick; import com.huawei.hms.support.api.entity.common.CommonConstant; import com.scb.phone.R; import com.scb.phone.view.activity.cardmanagement.StatementChannelCommonActivity; import com.scb.phone.view.activity.cardmanagement.TermAndConditionStatementChannelActivity; import com.scb.phone.view.activity.emailverification.ManageEmailLandingActivity; import java.util.ArrayList; import o.C0367Fb; import o.C14957gcv; import o.C2847amN; import o.InterfaceC13391fZD; import o.InterfaceC9068dcj; import o.ZI; import o.pug; /* loaded from: classes5.dex */ public final class ChangeChannelStatementReviewFragment extends Hilt_ChangeChannelStatementReviewFragment implements InterfaceC9068dcj.HBt { public static final IeS c = new IeS(0); @BindView public TextView changeAddressButton; private String d; private ArrayList f; private String g; private C0367Fb h; private String i; @InterfaceC13391fZD public C2847amN presenter; @BindView public TextView tvAddress; @BindView public TextView tvAddressTitle; @BindView public TextView tvMaskCardNo; @BindView public TextView tvRemark; /* loaded from: classes5.dex */ public static final class IeS { private IeS() { } public /* synthetic */ IeS(byte b) { this(); } } @Override // androidx.fragment.app.Fragment public final void onResume() { super.onResume(); final C2847amN c2847amN = this.presenter; String str = null; if (c2847amN == null) { C14957gcv.a(""); c2847amN = null; } String str2 = c2847amN.a; if (str2 == null) { C14957gcv.a(""); } else { str = str2; } if (C14957gcv.b((Object) str, (Object) CommonConstant.RETKEY.EMAIL)) { ZI.IeS ieS = new ZI.IeS(c2847amN) { // from class: o.amL private C2847amN c; @Override // o.ZI.IeS public final void e(Object obj) { C2847amN.a(this.c, (InterfaceC9068dcj.HBt) obj); } { this.c = c2847amN; } }; if (c2847amN.f != 0) { ieS.e(c2847amN.f); } } } @Override // androidx.fragment.app.Fragment public final View onCreateView(LayoutInflater layoutInflater, ViewGroup viewGroup, Bundle bundle) { C14957gcv.e(layoutInflater, ""); return layoutInflater.inflate(R.layout.2131559496, viewGroup, false); } @Override // androidx.fragment.app.Fragment public final void onCreate(Bundle bundle) { String string; String string2; super.onCreate(bundle); Bundle arguments = getArguments(); if (arguments != null) { C14957gcv.e("EXTRA_CHANNEL_KEY", ""); if (arguments == null) { string = ""; } else { string = arguments.getString("EXTRA_CHANNEL_KEY", ""); C14957gcv.c((Object) string, ""); } this.g = string; C14957gcv.e("EXTRA_ADDRESS_KEY", ""); if (arguments == null) { string2 = ""; } else { string2 = arguments.getString("EXTRA_ADDRESS_KEY", ""); C14957gcv.c((Object) string2, ""); } this.d = string2; C0367Fb c0367Fb = (C0367Fb) arguments.getParcelable("EXTRA_CREDIT_CARD_DISPLAY_KEY"); if (c0367Fb != null) { C14957gcv.c(c0367Fb, ""); this.h = c0367Fb; } ArrayList parcelableArrayList = arguments.getParcelableArrayList("EXTRA_CREDIT_CARD_DISPLAY_LIST_KEY"); if (parcelableArrayList != null) { C14957gcv.c(parcelableArrayList, ""); this.f = parcelableArrayList; } } } @Override // androidx.fragment.app.Fragment public final void onViewCreated(View view, Bundle bundle) { C14957gcv.e(view, ""); super.onViewCreated(view, bundle); ButterKnife.c(this, view); C2847amN c2847amN = this.presenter; String str = null; if (c2847amN == null) { C14957gcv.a(""); c2847amN = null; } c2847amN.e((C2847amN) this); final C2847amN c2847amN2 = this.presenter; if (c2847amN2 == null) { C14957gcv.a(""); c2847amN2 = null; } String str2 = this.g; if (str2 == null) { C14957gcv.a(""); str2 = null; } C0367Fb c0367Fb = this.h; if (c0367Fb == null) { C14957gcv.a(""); c0367Fb = null; } ArrayList arrayList = this.f; if (arrayList == null) { C14957gcv.a(""); arrayList = null; } String str3 = this.d; if (str3 == null) { C14957gcv.a(""); } else { str = str3; } C14957gcv.e(str2, ""); C14957gcv.e(c0367Fb, ""); C14957gcv.e(arrayList, ""); C14957gcv.e(str, ""); c2847amN2.c = c0367Fb; c2847amN2.e = arrayList; c2847amN2.a = str2; c2847amN2.b = str; ZI.IeS ieS = new ZI.IeS(c2847amN2) { // from class: o.amK private C2847amN a; @Override // o.ZI.IeS public final void e(Object obj) { C2847amN.e(this.a, (InterfaceC9068dcj.HBt) obj); } { this.a = c2847amN2; } }; if (c2847amN2.f != 0) { ieS.e(c2847amN2.f); } } @OnClick public final void onClickOk() { final C2847amN c2847amN = this.presenter; if (c2847amN == null) { C14957gcv.a(""); c2847amN = null; } ZI.IeS ieS = new ZI.IeS(c2847amN) { // from class: o.amQ private C2847amN d; @Override // o.ZI.IeS public final void e(Object obj) { C2847amN.b(this.d, (InterfaceC9068dcj.HBt) obj); } { this.d = c2847amN; } }; if (c2847amN.f != 0) { ieS.e(c2847amN.f); } } @OnClick public final void onClickChangeAddress() { final C2847amN c2847amN = this.presenter; if (c2847amN == null) { C14957gcv.a(""); c2847amN = null; } ZI.IeS ieS = new ZI.IeS(c2847amN) { // from class: o.amO private C2847amN c; @Override // o.ZI.IeS public final void e(Object obj) { C2847amN.c(this.c, (InterfaceC9068dcj.HBt) obj); } { this.c = c2847amN; } }; if (c2847amN.f != 0) { ieS.e(c2847amN.f); } } @Override // o.InterfaceC9068dcj.HBt public final void a(String str) { C14957gcv.e(str, ""); TextView textView = this.tvAddress; TextView textView2 = null; if (textView == null) { C14957gcv.a(""); textView = null; } textView.setText(str); TextView textView3 = this.tvAddressTitle; if (textView3 != null) { textView2 = textView3; } else { C14957gcv.a(""); } textView2.setText(getString(R.string.mailing_address)); } @Override // o.InterfaceC9068dcj.HBt public final void d(String str) { C14957gcv.e(str, ""); TextView textView = this.tvAddress; TextView textView2 = null; if (textView == null) { C14957gcv.a(""); textView = null; } textView.setText(str); TextView textView3 = this.tvAddressTitle; if (textView3 != null) { textView2 = textView3; } else { C14957gcv.a(""); } textView2.setText(getString(R.string.ccm_email_address)); } @Override // o.InterfaceC9068dcj.HBt public final void b(String str) { C14957gcv.e(str, ""); this.i = str; TextView textView = this.tvMaskCardNo; if (textView == null) { C14957gcv.a(""); textView = null; } textView.setText(str); } @Override // o.InterfaceC9068dcj.HBt public final void e(String str) { C14957gcv.e(str, ""); TextView textView = this.tvRemark; if (textView == null) { C14957gcv.a(""); textView = null; } textView.setText(str); } @Override // o.InterfaceC9068dcj.HBt public final void c(String str) { C14957gcv.e(str, ""); TextView textView = this.changeAddressButton; TextView textView2 = null; if (textView == null) { C14957gcv.a(""); textView = null; } textView.setText(str); TextView textView3 = this.changeAddressButton; if (textView3 != null) { textView2 = textView3; } else { C14957gcv.a(""); } textView2.setVisibility(4); } @Override // o.InterfaceC9068dcj.HBt public final void e() { Context context = getContext(); if (context != null) { StatementChannelCommonActivity.HBt hBt = StatementChannelCommonActivity.f6647o; C14957gcv.e(context, ""); Intent intent = new Intent(context, (Class) StatementChannelCommonActivity.class); intent.putExtra("EXTRA_PAGE_TYPE_KEY", StatementChannelCommonActivity.RVV.EDIT_ADDRESS_PAGE); context.startActivity(intent); } } @Override // o.InterfaceC9068dcj.HBt public final void d() { Context context = getContext(); if (context != null) { startActivityForResult(ManageEmailLandingActivity.aeX_(context), 119); } } @Override // o.InterfaceC9068dcj.HBt public final void e(C0367Fb c0367Fb, ArrayList arrayList, String str, String str2, ArrayList arrayList2) { String str3; C14957gcv.e(c0367Fb, ""); C14957gcv.e(arrayList, ""); C14957gcv.e(str, ""); C14957gcv.e(str2, ""); C14957gcv.e(arrayList2, ""); Context context = getContext(); if (context != null) { TermAndConditionStatementChannelActivity.HBt hBt = TermAndConditionStatementChannelActivity.m; String str4 = this.i; if (str4 == null) { C14957gcv.a(""); str3 = null; } else { str3 = str4; } context.startActivity(TermAndConditionStatementChannelActivity.HBt.Zv_(context, "creditcards_changechannel", c0367Fb, arrayList, str, str2, str3, arrayList2)); } } @Override // o.InterfaceC9068dcj.HBt public final void c(C0367Fb c0367Fb, ArrayList arrayList, String str, String str2) { C14957gcv.e(c0367Fb, ""); C14957gcv.e(arrayList, ""); C14957gcv.e(str, ""); C14957gcv.e(str2, ""); Context context = getContext(); if (context != null) { StatementChannelCommonActivity.HBt hBt = StatementChannelCommonActivity.f6647o; String str3 = this.i; if (str3 == null) { C14957gcv.a(""); str3 = null; } C14957gcv.e(context, ""); C14957gcv.e(c0367Fb, ""); C14957gcv.e(arrayList, ""); C14957gcv.e(str, ""); C14957gcv.e(str2, ""); C14957gcv.e(str3, ""); Intent intent = new Intent(context, (Class) StatementChannelCommonActivity.class); intent.putExtra("EXTRA_CHANNEL_KEY", str); intent.putExtra("EXTRA_MASK_CARD_KEY", str3); intent.putExtra("EXTRA_ADDRESS_KEY", str2); intent.putExtra("EXTRA_CREDIT_CARD_DISPLAY_KEY", c0367Fb); intent.putExtra("EXTRA_CREDIT_CARD_DISPLAY_LIST_KEY", arrayList); intent.putExtra("EXTRA_PAGE_TYPE_KEY", StatementChannelCommonActivity.RVV.APPLY_ALL); context.startActivity(intent); } } @Override // o.InterfaceC9068dcj.HBt public final void a() { c("change_stmt_channel_review", new pug[0]); } }