754 lines
26 KiB
Smali
754 lines
26 KiB
Smali
.class public final Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;
|
|
.super Lcom/discord/app/AppDialog;
|
|
.source "WidgetDisableDeleteAccountDialog.kt"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/MemberClasses;
|
|
value = {
|
|
Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Mode;,
|
|
Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Companion;
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field public static final synthetic $$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
.field public static final Companion:Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Companion;
|
|
|
|
.field public static final EXTRA_MODE:Ljava/lang/String; = "extra_mode"
|
|
|
|
|
|
# instance fields
|
|
.field public final bodyTv$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final cancelBtn$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final codeWrap$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final confirmBtn$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final headerTv$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final passwordWrap$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
|
|
# direct methods
|
|
.method public static constructor <clinit>()V
|
|
.locals 5
|
|
|
|
const/4 v0, 0x6
|
|
|
|
new-array v0, v0, [Lkotlin/reflect/KProperty;
|
|
|
|
new-instance v1, Lj0/n/c/q;
|
|
|
|
const-class v2, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;
|
|
|
|
invoke-static {v2}, Lj0/n/c/s;->getOrCreateKotlinClass(Ljava/lang/Class;)Lj0/r/b;
|
|
|
|
move-result-object v2
|
|
|
|
const-string v3, "headerTv"
|
|
|
|
const-string v4, "getHeaderTv()Landroid/widget/TextView;"
|
|
|
|
invoke-direct {v1, v2, v3, v4}, Lj0/n/c/q;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-static {v1}, Lj0/n/c/s;->property1(Lj0/n/c/p;)Lj0/r/d;
|
|
|
|
const/4 v2, 0x0
|
|
|
|
aput-object v1, v0, v2
|
|
|
|
new-instance v1, Lj0/n/c/q;
|
|
|
|
const-class v2, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;
|
|
|
|
invoke-static {v2}, Lj0/n/c/s;->getOrCreateKotlinClass(Ljava/lang/Class;)Lj0/r/b;
|
|
|
|
move-result-object v2
|
|
|
|
const-string v3, "bodyTv"
|
|
|
|
const-string v4, "getBodyTv()Landroid/widget/TextView;"
|
|
|
|
invoke-direct {v1, v2, v3, v4}, Lj0/n/c/q;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-static {v1}, Lj0/n/c/s;->property1(Lj0/n/c/p;)Lj0/r/d;
|
|
|
|
const/4 v2, 0x1
|
|
|
|
aput-object v1, v0, v2
|
|
|
|
new-instance v1, Lj0/n/c/q;
|
|
|
|
const-class v2, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;
|
|
|
|
invoke-static {v2}, Lj0/n/c/s;->getOrCreateKotlinClass(Ljava/lang/Class;)Lj0/r/b;
|
|
|
|
move-result-object v2
|
|
|
|
const-string v3, "cancelBtn"
|
|
|
|
const-string v4, "getCancelBtn()Landroid/widget/Button;"
|
|
|
|
invoke-direct {v1, v2, v3, v4}, Lj0/n/c/q;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-static {v1}, Lj0/n/c/s;->property1(Lj0/n/c/p;)Lj0/r/d;
|
|
|
|
const/4 v2, 0x2
|
|
|
|
aput-object v1, v0, v2
|
|
|
|
new-instance v1, Lj0/n/c/q;
|
|
|
|
const-class v2, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;
|
|
|
|
invoke-static {v2}, Lj0/n/c/s;->getOrCreateKotlinClass(Ljava/lang/Class;)Lj0/r/b;
|
|
|
|
move-result-object v2
|
|
|
|
const-string v3, "confirmBtn"
|
|
|
|
const-string v4, "getConfirmBtn()Lcom/discord/views/LoadingButton;"
|
|
|
|
invoke-direct {v1, v2, v3, v4}, Lj0/n/c/q;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-static {v1}, Lj0/n/c/s;->property1(Lj0/n/c/p;)Lj0/r/d;
|
|
|
|
const/4 v2, 0x3
|
|
|
|
aput-object v1, v0, v2
|
|
|
|
new-instance v1, Lj0/n/c/q;
|
|
|
|
const-class v2, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;
|
|
|
|
invoke-static {v2}, Lj0/n/c/s;->getOrCreateKotlinClass(Ljava/lang/Class;)Lj0/r/b;
|
|
|
|
move-result-object v2
|
|
|
|
const-string v3, "passwordWrap"
|
|
|
|
const-string v4, "getPasswordWrap()Lcom/google/android/material/textfield/TextInputLayout;"
|
|
|
|
invoke-direct {v1, v2, v3, v4}, Lj0/n/c/q;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-static {v1}, Lj0/n/c/s;->property1(Lj0/n/c/p;)Lj0/r/d;
|
|
|
|
const/4 v2, 0x4
|
|
|
|
aput-object v1, v0, v2
|
|
|
|
new-instance v1, Lj0/n/c/q;
|
|
|
|
const-class v2, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;
|
|
|
|
invoke-static {v2}, Lj0/n/c/s;->getOrCreateKotlinClass(Ljava/lang/Class;)Lj0/r/b;
|
|
|
|
move-result-object v2
|
|
|
|
const-string v3, "codeWrap"
|
|
|
|
const-string v4, "getCodeWrap()Lcom/google/android/material/textfield/TextInputLayout;"
|
|
|
|
invoke-direct {v1, v2, v3, v4}, Lj0/n/c/q;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-static {v1}, Lj0/n/c/s;->property1(Lj0/n/c/p;)Lj0/r/d;
|
|
|
|
const/4 v2, 0x5
|
|
|
|
aput-object v1, v0, v2
|
|
|
|
sput-object v0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
new-instance v0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Companion;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
invoke-direct {v0, v1}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Companion;-><init>(Lkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
|
|
sput-object v0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->Companion:Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Companion;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>()V
|
|
.locals 1
|
|
|
|
invoke-direct {p0}, Lcom/discord/app/AppDialog;-><init>()V
|
|
|
|
const v0, 0x7f0a02eb
|
|
|
|
invoke-static {p0, v0}, Lf/n/a/k/a;->i(Landroidx/fragment/app/DialogFragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->headerTv$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a02e7
|
|
|
|
invoke-static {p0, v0}, Lf/n/a/k/a;->i(Landroidx/fragment/app/DialogFragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->bodyTv$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a02e8
|
|
|
|
invoke-static {p0, v0}, Lf/n/a/k/a;->i(Landroidx/fragment/app/DialogFragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->cancelBtn$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a02ea
|
|
|
|
invoke-static {p0, v0}, Lf/n/a/k/a;->i(Landroidx/fragment/app/DialogFragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->confirmBtn$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a02ec
|
|
|
|
invoke-static {p0, v0}, Lf/n/a/k/a;->i(Landroidx/fragment/app/DialogFragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->passwordWrap$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a02e9
|
|
|
|
invoke-static {p0, v0}, Lf/n/a/k/a;->i(Landroidx/fragment/app/DialogFragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->codeWrap$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final synthetic access$configureUI(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;Lcom/discord/models/domain/ModelUser;)V
|
|
.locals 0
|
|
|
|
invoke-direct {p0, p1}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->configureUI(Lcom/discord/models/domain/ModelUser;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final synthetic access$getCodeWrap$p(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;)Lcom/google/android/material/textfield/TextInputLayout;
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getCodeWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public static final synthetic access$getConfirmBtn$p(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;)Lcom/discord/views/LoadingButton;
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getConfirmBtn()Lcom/discord/views/LoadingButton;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public static final synthetic access$getPasswordWrap$p(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;)Lcom/google/android/material/textfield/TextInputLayout;
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getPasswordWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public static final synthetic access$onDisableClicked(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Mode;)V
|
|
.locals 0
|
|
|
|
invoke-direct {p0, p1}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->onDisableClicked(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Mode;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private final configureUI(Lcom/discord/models/domain/ModelUser;)V
|
|
.locals 1
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getCodeWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {p1}, Lcom/discord/models/domain/ModelUser;->isMfaEnabled()Z
|
|
|
|
move-result p1
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
const/4 p1, 0x0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/16 p1, 0x8
|
|
|
|
:goto_0
|
|
invoke-virtual {v0, p1}, Landroid/view/View;->setVisibility(I)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private final getBodyTv()Landroid/widget/TextView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->bodyTv$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/4 v2, 0x1
|
|
|
|
aget-object v1, v1, v2
|
|
|
|
invoke-interface {v0, p0, v1}, Lkotlin/properties/ReadOnlyProperty;->getValue(Ljava/lang/Object;Lkotlin/reflect/KProperty;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Landroid/widget/TextView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getCancelBtn()Landroid/widget/Button;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->cancelBtn$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/4 v2, 0x2
|
|
|
|
aget-object v1, v1, v2
|
|
|
|
invoke-interface {v0, p0, v1}, Lkotlin/properties/ReadOnlyProperty;->getValue(Ljava/lang/Object;Lkotlin/reflect/KProperty;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Landroid/widget/Button;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getCodeWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->codeWrap$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/4 v2, 0x5
|
|
|
|
aget-object v1, v1, v2
|
|
|
|
invoke-interface {v0, p0, v1}, Lkotlin/properties/ReadOnlyProperty;->getValue(Ljava/lang/Object;Lkotlin/reflect/KProperty;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Lcom/google/android/material/textfield/TextInputLayout;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getConfirmBtn()Lcom/discord/views/LoadingButton;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->confirmBtn$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/4 v2, 0x3
|
|
|
|
aget-object v1, v1, v2
|
|
|
|
invoke-interface {v0, p0, v1}, Lkotlin/properties/ReadOnlyProperty;->getValue(Ljava/lang/Object;Lkotlin/reflect/KProperty;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Lcom/discord/views/LoadingButton;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getHeaderTv()Landroid/widget/TextView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->headerTv$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/4 v2, 0x0
|
|
|
|
aget-object v1, v1, v2
|
|
|
|
invoke-interface {v0, p0, v1}, Lkotlin/properties/ReadOnlyProperty;->getValue(Ljava/lang/Object;Lkotlin/reflect/KProperty;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Landroid/widget/TextView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getPasswordWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->passwordWrap$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/4 v2, 0x4
|
|
|
|
aget-object v1, v1, v2
|
|
|
|
invoke-interface {v0, p0, v1}, Lkotlin/properties/ReadOnlyProperty;->getValue(Ljava/lang/Object;Lkotlin/reflect/KProperty;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Lcom/google/android/material/textfield/TextInputLayout;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final onDisableClicked(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Mode;)V
|
|
.locals 12
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getConfirmBtn()Lcom/discord/views/LoadingButton;
|
|
|
|
move-result-object v0
|
|
|
|
const/4 v1, 0x1
|
|
|
|
invoke-virtual {v0, v1}, Lcom/discord/views/LoadingButton;->setIsLoading(Z)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getCodeWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0}, Landroid/widget/LinearLayout;->getVisibility()I
|
|
|
|
move-result v0
|
|
|
|
const/4 v2, 0x0
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getCodeWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-static {v0}, Lcom/discord/utilities/view/extensions/ViewExtensions;->getTextOrEmpty(Lcom/google/android/material/textfield/TextInputLayout;)Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
move-object v0, v2
|
|
|
|
:goto_0
|
|
new-instance v3, Lcom/discord/restapi/RestAPIParams$DisableAccount;
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getPasswordWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-static {v4}, Lcom/discord/utilities/view/extensions/ViewExtensions;->getTextOrEmpty(Lcom/google/android/material/textfield/TextInputLayout;)Ljava/lang/String;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-direct {v3, v4, v0}, Lcom/discord/restapi/RestAPIParams$DisableAccount;-><init>(Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-virtual {p1}, Ljava/lang/Enum;->ordinal()I
|
|
|
|
move-result p1
|
|
|
|
if-eqz p1, :cond_2
|
|
|
|
if-ne p1, v1, :cond_1
|
|
|
|
sget-object p1, Lcom/discord/utilities/rest/RestAPI;->Companion:Lcom/discord/utilities/rest/RestAPI$Companion;
|
|
|
|
invoke-virtual {p1}, Lcom/discord/utilities/rest/RestAPI$Companion;->getApi()Lcom/discord/utilities/rest/RestAPI;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {p1, v3}, Lcom/discord/utilities/rest/RestAPI;->deleteAccount(Lcom/discord/restapi/RestAPIParams$DisableAccount;)Lrx/Observable;
|
|
|
|
move-result-object p1
|
|
|
|
goto :goto_1
|
|
|
|
:cond_1
|
|
new-instance p1, Lkotlin/NoWhenBranchMatchedException;
|
|
|
|
invoke-direct {p1}, Lkotlin/NoWhenBranchMatchedException;-><init>()V
|
|
|
|
throw p1
|
|
|
|
:cond_2
|
|
sget-object p1, Lcom/discord/utilities/rest/RestAPI;->Companion:Lcom/discord/utilities/rest/RestAPI$Companion;
|
|
|
|
invoke-virtual {p1}, Lcom/discord/utilities/rest/RestAPI$Companion;->getApi()Lcom/discord/utilities/rest/RestAPI;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {p1, v3}, Lcom/discord/utilities/rest/RestAPI;->disableAccount(Lcom/discord/restapi/RestAPIParams$DisableAccount;)Lrx/Observable;
|
|
|
|
move-result-object p1
|
|
|
|
:goto_1
|
|
const/4 v0, 0x0
|
|
|
|
invoke-static {p1, v0, v1, v2}, Lcom/discord/utilities/rx/ObservableExtensionsKt;->restSubscribeOn$default(Lrx/Observable;ZILjava/lang/Object;)Lrx/Observable;
|
|
|
|
move-result-object p1
|
|
|
|
const/4 v0, 0x2
|
|
|
|
invoke-static {p1, p0, v2, v0, v2}, Lcom/discord/utilities/rx/ObservableExtensionsKt;->ui$default(Lrx/Observable;Lcom/discord/app/AppComponent;Lcom/discord/utilities/mg_recycler/MGRecyclerAdapterSimple;ILjava/lang/Object;)Lrx/Observable;
|
|
|
|
move-result-object v3
|
|
|
|
const-class v4, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;
|
|
|
|
const/4 v5, 0x0
|
|
|
|
const/4 v6, 0x0
|
|
|
|
new-instance v7, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onDisableClicked$1;
|
|
|
|
invoke-direct {v7, p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onDisableClicked$1;-><init>(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;)V
|
|
|
|
const/4 v8, 0x0
|
|
|
|
sget-object v9, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onDisableClicked$2;->INSTANCE:Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onDisableClicked$2;
|
|
|
|
const/16 v10, 0x16
|
|
|
|
const/4 v11, 0x0
|
|
|
|
invoke-static/range {v3 .. v11}, Lcom/discord/utilities/rx/ObservableExtensionsKt;->appSubscribe$default(Lrx/Observable;Ljava/lang/Class;Landroid/content/Context;Lkotlin/jvm/functions/Function1;Lkotlin/jvm/functions/Function1;Lkotlin/jvm/functions/Function0;Lkotlin/jvm/functions/Function1;ILjava/lang/Object;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public getContentViewResId()I
|
|
.locals 1
|
|
|
|
const v0, 0x7f0d01b2
|
|
|
|
return v0
|
|
.end method
|
|
|
|
.method public onResume()V
|
|
.locals 12
|
|
|
|
invoke-super {p0}, Lcom/discord/app/AppDialog;->onResume()V
|
|
|
|
sget-object v0, Lcom/discord/stores/StoreStream;->Companion:Lcom/discord/stores/StoreStream$Companion;
|
|
|
|
invoke-virtual {v0}, Lcom/discord/stores/StoreStream$Companion;->getUsers()Lcom/discord/stores/StoreUser;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0}, Lcom/discord/stores/StoreUser;->observeMe()Lrx/Observable;
|
|
|
|
move-result-object v0
|
|
|
|
const/4 v1, 0x0
|
|
|
|
const/4 v2, 0x2
|
|
|
|
invoke-static {v0, p0, v1, v2, v1}, Lcom/discord/utilities/rx/ObservableExtensionsKt;->ui$default(Lrx/Observable;Lcom/discord/app/AppComponent;Lcom/discord/utilities/mg_recycler/MGRecyclerAdapterSimple;ILjava/lang/Object;)Lrx/Observable;
|
|
|
|
move-result-object v3
|
|
|
|
const-class v4, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;
|
|
|
|
new-instance v9, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onResume$1;
|
|
|
|
invoke-direct {v9, p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onResume$1;-><init>(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;)V
|
|
|
|
const/4 v5, 0x0
|
|
|
|
const/4 v6, 0x0
|
|
|
|
const/4 v7, 0x0
|
|
|
|
const/4 v8, 0x0
|
|
|
|
const/16 v10, 0x1e
|
|
|
|
const/4 v11, 0x0
|
|
|
|
invoke-static/range {v3 .. v11}, Lcom/discord/utilities/rx/ObservableExtensionsKt;->appSubscribe$default(Lrx/Observable;Ljava/lang/Class;Landroid/content/Context;Lkotlin/jvm/functions/Function1;Lkotlin/jvm/functions/Function1;Lkotlin/jvm/functions/Function0;Lkotlin/jvm/functions/Function1;ILjava/lang/Object;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public onViewBound(Landroid/view/View;)V
|
|
.locals 7
|
|
|
|
const/4 v0, 0x0
|
|
|
|
if-eqz p1, :cond_2
|
|
|
|
invoke-super {p0, p1}, Lcom/discord/app/AppDialog;->onViewBound(Landroid/view/View;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
invoke-virtual {p0, p1}, Landroidx/fragment/app/DialogFragment;->setCancelable(Z)V
|
|
|
|
invoke-virtual {p0}, Landroidx/fragment/app/Fragment;->getArguments()Landroid/os/Bundle;
|
|
|
|
move-result-object v1
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
const-string v0, "extra_mode"
|
|
|
|
invoke-virtual {v1, v0}, Landroid/os/Bundle;->getInt(Ljava/lang/String;)I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Mode;->values()[Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Mode;
|
|
|
|
move-result-object v1
|
|
|
|
aget-object v0, v1, v0
|
|
|
|
:cond_0
|
|
if-nez v0, :cond_1
|
|
|
|
sget-object v1, Lcom/discord/app/AppLog;->c:Lcom/discord/app/AppLog;
|
|
|
|
const/4 v3, 0x0
|
|
|
|
const/4 v4, 0x0
|
|
|
|
const/4 v5, 0x6
|
|
|
|
const/4 v6, 0x0
|
|
|
|
const-string v2, "Disable/Delete Dialog shown with null mode"
|
|
|
|
invoke-static/range {v1 .. v6}, Lcom/discord/utilities/logging/Logger;->e$default(Lcom/discord/utilities/logging/Logger;Ljava/lang/String;Ljava/lang/Throwable;Ljava/util/Map;ILjava/lang/Object;)V
|
|
|
|
invoke-virtual {p0}, Lcom/discord/app/AppDialog;->dismiss()V
|
|
|
|
return-void
|
|
|
|
:cond_1
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getConfirmBtn()Lcom/discord/views/LoadingButton;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v1, p1}, Lcom/discord/views/LoadingButton;->setIsLoading(Z)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getHeaderTv()Landroid/widget/TextView;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {v0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Mode;->getHeaderStringId()I
|
|
|
|
move-result v1
|
|
|
|
invoke-virtual {p0, v1}, Landroidx/fragment/app/Fragment;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {p1, v1}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getBodyTv()Landroid/widget/TextView;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {v0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Mode;->getBodyStringId()I
|
|
|
|
move-result v1
|
|
|
|
invoke-virtual {p0, v1}, Landroidx/fragment/app/Fragment;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {p1, v1}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getConfirmBtn()Lcom/discord/views/LoadingButton;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {v0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Mode;->getConfirmStringId()I
|
|
|
|
move-result v1
|
|
|
|
invoke-virtual {p0, v1}, Landroidx/fragment/app/Fragment;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {p1, v1}, Lcom/discord/views/LoadingButton;->setText(Ljava/lang/String;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getCancelBtn()Landroid/widget/Button;
|
|
|
|
move-result-object p1
|
|
|
|
new-instance v1, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onViewBound$1;
|
|
|
|
invoke-direct {v1, p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onViewBound$1;-><init>(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;)V
|
|
|
|
invoke-virtual {p1, v1}, Landroid/widget/Button;->setOnClickListener(Landroid/view/View$OnClickListener;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getCodeWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
|
|
move-result-object p1
|
|
|
|
new-instance v1, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onViewBound$2;
|
|
|
|
invoke-direct {v1, p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onViewBound$2;-><init>(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;)V
|
|
|
|
invoke-static {p1, p0, v1}, Lcom/discord/utilities/view/extensions/ViewExtensions;->addBindedTextWatcher(Lcom/google/android/material/textfield/TextInputLayout;Landroidx/fragment/app/Fragment;Lkotlin/jvm/functions/Function1;)Lkotlin/Unit;
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getPasswordWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
|
|
move-result-object p1
|
|
|
|
new-instance v1, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onViewBound$3;
|
|
|
|
invoke-direct {v1, p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onViewBound$3;-><init>(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;)V
|
|
|
|
invoke-static {p1, p0, v1}, Lcom/discord/utilities/view/extensions/ViewExtensions;->addBindedTextWatcher(Lcom/google/android/material/textfield/TextInputLayout;Landroidx/fragment/app/Fragment;Lkotlin/jvm/functions/Function1;)Lkotlin/Unit;
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;->getConfirmBtn()Lcom/discord/views/LoadingButton;
|
|
|
|
move-result-object p1
|
|
|
|
new-instance v1, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onViewBound$4;
|
|
|
|
invoke-direct {v1, p0, v0}, Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$onViewBound$4;-><init>(Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog;Lcom/discord/widgets/settings/account/WidgetDisableDeleteAccountDialog$Mode;)V
|
|
|
|
invoke-virtual {p1, v1}, Landroid/widget/FrameLayout;->setOnClickListener(Landroid/view/View$OnClickListener;)V
|
|
|
|
return-void
|
|
|
|
:cond_2
|
|
const-string p1, "view"
|
|
|
|
invoke-static {p1}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
throw v0
|
|
.end method
|