what-the-bank/sources/com/scb/phone/view/fragment/cardmanagement/deejungtransfer/DeejungTransferInstallments...

228 lines
9.3 KiB
Java
Raw Normal View History

2024-07-27 18:17:47 +07:00
package com.scb.phone.view.fragment.cardmanagement.deejungtransfer;
import android.content.Context;
import android.content.Intent;
import android.os.Build;
import android.os.Bundle;
import android.os.Parcelable;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import androidx.constraintlayout.widget.ConstraintLayout;
import androidx.fragment.app.FragmentActivity;
import com.scb.phone.R;
import com.scb.phone.view.activity.cardmanagement.deejungtransfer.DeejungTermsAndConditionsActivity;
import com.scb.phone.view.activity.cardmanagement.deejungtransfer.DeejungTransferInstallmentOtpActivity;
import com.scb.phone.view.fragment.BaseFragment;
import com.scb.phone.view.fragment.cardmanagement.deejungtransfer.DeejungTransferInstallmentsReviewBottomFragment;
import o.AbstractC14961gcz;
import o.C11146eZo;
import o.C11560ehe;
import o.C14957gcv;
import o.C17408wYc;
import o.GR;
import o.Heg;
import o.InterfaceC0834Plv;
import o.InterfaceC10303eAL;
import o.InterfaceC13393fZL;
import o.InterfaceC14890gbN;
import o.eAO;
import o.fZZ;
import o.huo;
import o.qeC;
/* loaded from: classes5.dex */
public final class DeejungTransferInstallmentsReviewBottomFragment extends Hilt_DeejungTransferInstallmentsReviewBottomFragment implements InterfaceC10303eAL {
private final InterfaceC13393fZL c;
private huo<Intent> d;
private GR j;
public DeejungTransferInstallmentsReviewBottomFragment() {
HBt hBt = new HBt(this);
C14957gcv.e(hBt, "");
this.c = new fZZ(hBt);
}
/* loaded from: classes5.dex */
static final class HBt extends AbstractC14961gcz implements InterfaceC14890gbN<C17408wYc> {
private DeejungTransferInstallmentsReviewBottomFragment b;
@Override // o.InterfaceC14890gbN
public final /* synthetic */ C17408wYc invoke() {
View inflate = this.b.getLayoutInflater().inflate(R.layout.2131559963, (ViewGroup) null, false);
View e = qeC.e(inflate, R.id.layout_review_page_bottom);
if (e != null) {
return new C17408wYc((ConstraintLayout) inflate, C11146eZo.a(e));
}
throw new NullPointerException("Missing required view with ID: ".concat(inflate.getResources().getResourceName(R.id.layout_review_page_bottom)));
}
/* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
HBt(DeejungTransferInstallmentsReviewBottomFragment deejungTransferInstallmentsReviewBottomFragment) {
super(0);
this.b = deejungTransferInstallmentsReviewBottomFragment;
}
}
@Override // androidx.fragment.app.Fragment
public final View onCreateView(LayoutInflater layoutInflater, ViewGroup viewGroup, Bundle bundle) {
C14957gcv.e(layoutInflater, "");
ConstraintLayout constraintLayout = ((C17408wYc) this.c.e()).b;
C14957gcv.c(constraintLayout, "");
return constraintLayout;
}
@Override // androidx.fragment.app.Fragment
public final void onViewCreated(View view, Bundle bundle) {
C14957gcv.e(view, "");
super.onViewCreated(view, bundle);
FragmentActivity activity = getActivity();
if (activity != null) {
Intent intent = activity.getIntent();
C14957gcv.c(intent, "");
if (Build.VERSION.SDK_INT >= 33) {
Bundle extras = intent.getExtras();
if (extras != null) {
r3 = (Parcelable) extras.getParcelable("com.scb.phone.view.activity.card_management.DeejungTransferInstallmentsSummaryFragment.KEY_TRANSFER_INSTALLMENTS_SUMMARY_DISPLAY_MODEL", GR.class);
}
} else {
Bundle extras2 = intent.getExtras();
Parcelable parcelable = extras2 != null ? extras2.getParcelable("com.scb.phone.view.activity.card_management.DeejungTransferInstallmentsSummaryFragment.KEY_TRANSFER_INSTALLMENTS_SUMMARY_DISPLAY_MODEL") : null;
r3 = (GR) (parcelable instanceof GR ? parcelable : null);
}
GR gr = (GR) r3;
if (gr != null) {
this.j = gr;
}
final C11146eZo c11146eZo = ((C17408wYc) this.c.e()).c;
c11146eZo.a.setTermsCheckboxListener(new eAO(c11146eZo) { // from class: o.eJZ
private C11146eZo d;
@Override // o.eAO
public final void c(boolean z) {
DeejungTransferInstallmentsReviewBottomFragment.a(this.d);
}
{
this.d = c11146eZo;
}
});
c11146eZo.a.setTermsAndConditionsListener(this);
((C17408wYc) this.c.e()).c.e.setOnClickListener(new View.OnClickListener(this) { // from class: o.eKa
private DeejungTransferInstallmentsReviewBottomFragment c;
@Override // android.view.View.OnClickListener
public final void onClick(View view2) {
DeejungTransferInstallmentsReviewBottomFragment.e(this.c);
}
{
this.c = this;
}
});
huo<Intent> registerForActivityResult = registerForActivityResult(new C11560ehe.Sts(), new InterfaceC0834Plv(this) { // from class: o.eKc
private DeejungTransferInstallmentsReviewBottomFragment e;
@Override // o.InterfaceC0834Plv
public final void d(Object obj) {
DeejungTransferInstallmentsReviewBottomFragment.a(this.e, (Heg) obj);
}
{
this.e = this;
}
});
C14957gcv.c(registerForActivityResult, "");
this.d = registerForActivityResult;
}
}
@Override // o.InterfaceC10303eAL
public final void j() {
FragmentActivity activity;
BaseFragment.HBt hBt = new BaseFragment.HBt(this) { // from class: o.eKb
private DeejungTransferInstallmentsReviewBottomFragment b;
@Override // com.scb.phone.view.fragment.BaseFragment.HBt
public final void c(Context context) {
DeejungTransferInstallmentsReviewBottomFragment.a(this.b, context);
}
{
this.b = this;
}
};
if (!isAdded() || (activity = getActivity()) == null) {
return;
}
hBt.c(activity);
}
@Override // com.scb.phone.view.fragment.BaseFragment, androidx.fragment.app.Fragment
public final void onDestroy() {
huo<Intent> huoVar = this.d;
if (huoVar == null) {
C14957gcv.a("");
huoVar = null;
}
huoVar.e();
super.onDestroy();
}
public static /* synthetic */ void a(DeejungTransferInstallmentsReviewBottomFragment deejungTransferInstallmentsReviewBottomFragment, Heg heg) {
FragmentActivity activity;
C14957gcv.e(deejungTransferInstallmentsReviewBottomFragment, "");
if (heg.e != -1 || (activity = deejungTransferInstallmentsReviewBottomFragment.getActivity()) == null) {
return;
}
activity.finish();
}
public static /* synthetic */ void a(DeejungTransferInstallmentsReviewBottomFragment deejungTransferInstallmentsReviewBottomFragment, Context context) {
C14957gcv.e(deejungTransferInstallmentsReviewBottomFragment, "");
if (context != null) {
DeejungTermsAndConditionsActivity.RVV rvv = DeejungTermsAndConditionsActivity.b;
GR gr = deejungTransferInstallmentsReviewBottomFragment.j;
if (gr == null) {
C14957gcv.a("");
gr = null;
}
String str = gr.t;
C14957gcv.e(context, "");
Intent intent = new Intent(context, (Class<?>) DeejungTermsAndConditionsActivity.class);
intent.putExtra("EXTRA_DEEJUNG_TERMS_AND_CONDITIONS_URL", str);
deejungTransferInstallmentsReviewBottomFragment.startActivity(intent);
}
}
public static /* synthetic */ void a(C11146eZo c11146eZo) {
C14957gcv.e(c11146eZo, "");
c11146eZo.e.setEnabled(c11146eZo.a.termsCheckBox.isChecked());
}
public static /* synthetic */ void e(DeejungTransferInstallmentsReviewBottomFragment deejungTransferInstallmentsReviewBottomFragment) {
Intent intent;
C14957gcv.e(deejungTransferInstallmentsReviewBottomFragment, "");
Context context = deejungTransferInstallmentsReviewBottomFragment.getContext();
if (context != null) {
DeejungTransferInstallmentOtpActivity.LWm lWm = DeejungTransferInstallmentOtpActivity.b;
GR gr = deejungTransferInstallmentsReviewBottomFragment.j;
if (gr == null) {
C14957gcv.a("");
gr = null;
}
C14957gcv.e(context, "");
intent = new Intent(context, (Class<?>) DeejungTransferInstallmentOtpActivity.class).putExtra("com.scb.phone.view.activity.card_management.DeejungTransferInstallmentsSummaryFragment.KEY_TRANSFER_INSTALLMENTS_SUMMARY_DISPLAY_MODEL", gr);
C14957gcv.c(intent, "");
} else {
intent = null;
}
huo<Intent> huoVar = deejungTransferInstallmentsReviewBottomFragment.d;
if (huoVar == null) {
C14957gcv.a("");
huoVar = null;
}
huoVar.d(intent, null);
}
}