what-the-bank/sources/o/C10896eSC.java

94 lines
3.9 KiB
Java

package o;
import android.content.DialogInterface;
import androidx.fragment.app.FragmentActivity;
import com.scb.phone.view.custom.common.CustomDialog;
import com.scb.phone.view.fragment.donations.SharingMomentsPreviewFragment;
import java.lang.ref.WeakReference;
/* renamed from: o.eSC, reason: case insensitive filesystem */
/* loaded from: classes5.dex */
public final class C10896eSC {
private static final String[] b = {"android.permission.WRITE_EXTERNAL_STORAGE"};
private static final String[] e = {"android.permission.READ_MEDIA_IMAGES"};
public static void c(SharingMomentsPreviewFragment sharingMomentsPreviewFragment) {
FragmentActivity requireActivity = sharingMomentsPreviewFragment.requireActivity();
String[] strArr = b;
if (C15581guh.b(requireActivity, strArr)) {
sharingMomentsPreviewFragment.h();
} else {
sharingMomentsPreviewFragment.requestPermissions(strArr, 126);
}
}
public static void d(SharingMomentsPreviewFragment sharingMomentsPreviewFragment) {
FragmentActivity requireActivity = sharingMomentsPreviewFragment.requireActivity();
String[] strArr = e;
if (!C15581guh.b(requireActivity, strArr)) {
if (C15581guh.e(sharingMomentsPreviewFragment, strArr)) {
final LWm lWm = new LWm(sharingMomentsPreviewFragment, (byte) 0);
((CustomDialog) CustomDialog.e(new Object[]{CustomDialog.b(sharingMomentsPreviewFragment.getContext()).c(com.scb.phone.R.string.permission_storage_title).d(com.scb.phone.R.string.permission_storage).aoT_(com.scb.phone.R.string.permission_allow, new DialogInterface.OnClickListener(lWm) { // from class: o.eSz
private InterfaceC15577gud b;
@Override // android.content.DialogInterface.OnClickListener
public final void onClick(DialogInterface dialogInterface, int i) {
this.b.c();
}
{
this.b = lWm;
}
}), Integer.valueOf(com.scb.phone.R.string.permission_deny), new DialogInterface.OnClickListener(lWm) { // from class: o.eSB
private InterfaceC15577gud e;
@Override // android.content.DialogInterface.OnClickListener
public final void onClick(DialogInterface dialogInterface, int i) {
this.e.e();
}
{
this.e = lWm;
}
}})).show();
return;
}
sharingMomentsPreviewFragment.requestPermissions(strArr, 127);
return;
}
sharingMomentsPreviewFragment.h();
}
/* JADX INFO: Access modifiers changed from: package-private */
/* renamed from: o.eSC$LWm */
/* loaded from: classes5.dex */
public static final class LWm implements InterfaceC15577gud {
private final WeakReference<SharingMomentsPreviewFragment> b;
private LWm(SharingMomentsPreviewFragment sharingMomentsPreviewFragment) {
this.b = new WeakReference<>(sharingMomentsPreviewFragment);
}
@Override // o.InterfaceC15577gud
public final void c() {
SharingMomentsPreviewFragment sharingMomentsPreviewFragment = this.b.get();
if (sharingMomentsPreviewFragment == null) {
return;
}
sharingMomentsPreviewFragment.requestPermissions(C10896eSC.e, 127);
}
@Override // o.InterfaceC15577gud
public final void e() {
if (this.b.get() == null) {
return;
}
SharingMomentsPreviewFragment.d();
}
/* synthetic */ LWm(SharingMomentsPreviewFragment sharingMomentsPreviewFragment, byte b) {
this(sharingMomentsPreviewFragment);
}
}
}