842 lines
29 KiB
Smali
842 lines
29 KiB
Smali
.class public final Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;
|
|
.super Lcom/discord/app/AppFragment;
|
|
.source "WidgetSettingsAccountChangePassword.kt"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/MemberClasses;
|
|
value = {
|
|
Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$Companion;
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field public static final synthetic $$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
.field public static final Companion:Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$Companion;
|
|
|
|
|
|
# instance fields
|
|
.field public final currentPassword$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final dimmerView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final newPassword$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final saveButton$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final state:Lcom/discord/utilities/stateful/StatefulViews;
|
|
|
|
.field public final twoFA$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
|
|
# direct methods
|
|
.method public static constructor <clinit>()V
|
|
.locals 6
|
|
|
|
const/4 v0, 0x5
|
|
|
|
new-array v0, v0, [Lkotlin/reflect/KProperty;
|
|
|
|
new-instance v1, Ly/u/b/u;
|
|
|
|
const-class v2, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;
|
|
|
|
invoke-static {v2}, Ly/u/b/x;->getOrCreateKotlinClass(Ljava/lang/Class;)Ly/y/b;
|
|
|
|
move-result-object v2
|
|
|
|
const-string v3, "currentPassword"
|
|
|
|
const-string v4, "getCurrentPassword()Landroidx/appcompat/widget/AppCompatEditText;"
|
|
|
|
invoke-direct {v1, v2, v3, v4}, Ly/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v2, Ly/u/b/x;->a:Ly/u/b/y;
|
|
|
|
invoke-virtual {v2, v1}, Ly/u/b/y;->property1(Ly/u/b/t;)Ly/y/d;
|
|
|
|
const/4 v2, 0x0
|
|
|
|
aput-object v1, v0, v2
|
|
|
|
const/4 v1, 0x1
|
|
|
|
new-instance v2, Ly/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;
|
|
|
|
invoke-static {v3}, Ly/u/b/x;->getOrCreateKotlinClass(Ljava/lang/Class;)Ly/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "newPassword"
|
|
|
|
const-string v5, "getNewPassword()Landroidx/appcompat/widget/AppCompatEditText;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Ly/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Ly/u/b/x;->a:Ly/u/b/y;
|
|
|
|
invoke-virtual {v3, v2}, Ly/u/b/y;->property1(Ly/u/b/t;)Ly/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/4 v1, 0x2
|
|
|
|
new-instance v2, Ly/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;
|
|
|
|
invoke-static {v3}, Ly/u/b/x;->getOrCreateKotlinClass(Ljava/lang/Class;)Ly/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "twoFA"
|
|
|
|
const-string v5, "getTwoFA()Landroidx/appcompat/widget/AppCompatEditText;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Ly/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Ly/u/b/x;->a:Ly/u/b/y;
|
|
|
|
invoke-virtual {v3, v2}, Ly/u/b/y;->property1(Ly/u/b/t;)Ly/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/4 v1, 0x3
|
|
|
|
new-instance v2, Ly/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;
|
|
|
|
invoke-static {v3}, Ly/u/b/x;->getOrCreateKotlinClass(Ljava/lang/Class;)Ly/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "dimmerView"
|
|
|
|
const-string v5, "getDimmerView()Lcom/discord/utilities/dimmer/DimmerView;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Ly/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Ly/u/b/x;->a:Ly/u/b/y;
|
|
|
|
invoke-virtual {v3, v2}, Ly/u/b/y;->property1(Ly/u/b/t;)Ly/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/4 v1, 0x4
|
|
|
|
new-instance v2, Ly/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;
|
|
|
|
invoke-static {v3}, Ly/u/b/x;->getOrCreateKotlinClass(Ljava/lang/Class;)Ly/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "saveButton"
|
|
|
|
const-string v5, "getSaveButton()Lcom/google/android/material/floatingactionbutton/FloatingActionButton;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Ly/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Ly/u/b/x;->a:Ly/u/b/y;
|
|
|
|
invoke-virtual {v3, v2}, Ly/u/b/y;->property1(Ly/u/b/t;)Ly/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
sput-object v0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
new-instance v0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$Companion;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
invoke-direct {v0, v1}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$Companion;-><init>(Lkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
|
|
sput-object v0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->Companion:Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$Companion;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>()V
|
|
.locals 4
|
|
|
|
invoke-direct {p0}, Lcom/discord/app/AppFragment;-><init>()V
|
|
|
|
const v0, 0x7f0a0138
|
|
|
|
invoke-static {p0, v0}, Lf/n/a/j/a;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->currentPassword$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a0139
|
|
|
|
invoke-static {p0, v0}, Lf/n/a/j/a;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v1
|
|
|
|
iput-object v1, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->newPassword$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v1, 0x7f0a013b
|
|
|
|
invoke-static {p0, v1}, Lf/n/a/j/a;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v1
|
|
|
|
iput-object v1, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->twoFA$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v1, 0x7f0a02a9
|
|
|
|
invoke-static {p0, v1}, Lf/n/a/j/a;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v1
|
|
|
|
iput-object v1, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->dimmerView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v1, 0x7f0a013a
|
|
|
|
invoke-static {p0, v1}, Lf/n/a/j/a;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v1
|
|
|
|
iput-object v1, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->saveButton$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
new-instance v1, Lcom/discord/utilities/stateful/StatefulViews;
|
|
|
|
const/4 v2, 0x1
|
|
|
|
new-array v2, v2, [I
|
|
|
|
const/4 v3, 0x0
|
|
|
|
aput v0, v2, v3
|
|
|
|
invoke-direct {v1, v2}, Lcom/discord/utilities/stateful/StatefulViews;-><init>([I)V
|
|
|
|
iput-object v1, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->state:Lcom/discord/utilities/stateful/StatefulViews;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final synthetic access$configureUI(Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;Lcom/discord/models/domain/ModelUser;)V
|
|
.locals 0
|
|
|
|
invoke-direct {p0, p1}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->configureUI(Lcom/discord/models/domain/ModelUser;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final synthetic access$getCurrentPassword$p(Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;)Landroidx/appcompat/widget/AppCompatEditText;
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getCurrentPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public static final synthetic access$getNewPassword$p(Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;)Landroidx/appcompat/widget/AppCompatEditText;
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getNewPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public static final synthetic access$getTwoFA$p(Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;)Landroidx/appcompat/widget/AppCompatEditText;
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getTwoFA()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public static final synthetic access$saveNewPassword(Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;Lcom/discord/models/domain/ModelUser;)V
|
|
.locals 0
|
|
|
|
invoke-direct {p0, p1}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->saveNewPassword(Lcom/discord/models/domain/ModelUser;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private final configureUI(Lcom/discord/models/domain/ModelUser;)V
|
|
.locals 2
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getTwoFA()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {p1}, Lcom/discord/models/domain/ModelUser;->isMfaEnabled()Z
|
|
|
|
move-result v1
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
const/4 v1, 0x0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/16 v1, 0x8
|
|
|
|
:goto_0
|
|
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getSaveButton()Lcom/google/android/material/floatingactionbutton/FloatingActionButton;
|
|
|
|
move-result-object v0
|
|
|
|
new-instance v1, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$configureUI$1;
|
|
|
|
invoke-direct {v1, p0, p1}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$configureUI$1;-><init>(Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;Lcom/discord/models/domain/ModelUser;)V
|
|
|
|
invoke-virtual {v0, v1}, Landroid/widget/ImageButton;->setOnClickListener(Landroid/view/View$OnClickListener;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private final getCurrentPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->currentPassword$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->$$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, Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getDimmerView()Lcom/discord/utilities/dimmer/DimmerView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->dimmerView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->$$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/utilities/dimmer/DimmerView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getNewPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->newPassword$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->$$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, Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getSaveButton()Lcom/google/android/material/floatingactionbutton/FloatingActionButton;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->saveButton$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->$$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/floatingactionbutton/FloatingActionButton;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getTwoFA()Landroidx/appcompat/widget/AppCompatEditText;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->twoFA$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->$$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, Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final saveNewPassword(Lcom/discord/models/domain/ModelUser;)V
|
|
.locals 17
|
|
|
|
move-object/from16 v0, p0
|
|
|
|
invoke-virtual/range {p1 .. p1}, Lcom/discord/models/domain/ModelUser;->isMfaEnabled()Z
|
|
|
|
move-result v1
|
|
|
|
const/4 v2, 0x0
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getTwoFA()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v1}, Landroidx/appcompat/widget/AppCompatEditText;->getText()Landroid/text/Editable;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-static {v1}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object v1
|
|
|
|
move-object v10, v1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
move-object v10, v2
|
|
|
|
:goto_0
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getCurrentPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v1}, Landroidx/appcompat/widget/AppCompatEditText;->getText()Landroid/text/Editable;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-static {v1}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object v6
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getNewPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v1}, Landroidx/appcompat/widget/AppCompatEditText;->getText()Landroid/text/Editable;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-static {v1}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object v7
|
|
|
|
invoke-interface {v6}, Ljava/lang/CharSequence;->length()I
|
|
|
|
move-result v1
|
|
|
|
const/4 v14, 0x1
|
|
|
|
if-nez v1, :cond_1
|
|
|
|
const/4 v1, 0x1
|
|
|
|
goto :goto_1
|
|
|
|
:cond_1
|
|
const/4 v1, 0x0
|
|
|
|
:goto_1
|
|
if-eqz v1, :cond_2
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getCurrentPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v1}, Landroid/widget/EditText;->requestFocus()Z
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getCurrentPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getCurrentPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual {v2}, Landroid/widget/EditText;->getContext()Landroid/content/Context;
|
|
|
|
move-result-object v2
|
|
|
|
const v3, 0x7f120f42
|
|
|
|
invoke-virtual {v2, v3}, Landroid/content/Context;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual {v1, v2}, Landroid/widget/EditText;->setError(Ljava/lang/CharSequence;)V
|
|
|
|
return-void
|
|
|
|
:cond_2
|
|
sget-object v1, Lcom/discord/utilities/auth/AuthUtils;->INSTANCE:Lcom/discord/utilities/auth/AuthUtils;
|
|
|
|
invoke-virtual {v1, v7}, Lcom/discord/utilities/auth/AuthUtils;->isValidPasswordLength(Ljava/lang/String;)Z
|
|
|
|
move-result v1
|
|
|
|
if-nez v1, :cond_3
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getNewPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v1}, Landroid/widget/EditText;->requestFocus()Z
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getNewPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getNewPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual {v2}, Landroid/widget/EditText;->getContext()Landroid/content/Context;
|
|
|
|
move-result-object v2
|
|
|
|
const v3, 0x7f120f3c
|
|
|
|
invoke-virtual {v2, v3}, Landroid/content/Context;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual {v1, v2}, Landroid/widget/EditText;->setError(Ljava/lang/CharSequence;)V
|
|
|
|
return-void
|
|
|
|
:cond_3
|
|
invoke-virtual/range {p1 .. p1}, Lcom/discord/models/domain/ModelUser;->isMfaEnabled()Z
|
|
|
|
move-result v1
|
|
|
|
if-eqz v1, :cond_6
|
|
|
|
if-eqz v10, :cond_5
|
|
|
|
invoke-interface {v10}, Ljava/lang/CharSequence;->length()I
|
|
|
|
move-result v1
|
|
|
|
if-nez v1, :cond_4
|
|
|
|
goto :goto_2
|
|
|
|
:cond_4
|
|
const/4 v1, 0x0
|
|
|
|
goto :goto_3
|
|
|
|
:cond_5
|
|
:goto_2
|
|
const/4 v1, 0x1
|
|
|
|
:goto_3
|
|
if-eqz v1, :cond_6
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getTwoFA()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v1}, Landroid/widget/EditText;->requestFocus()Z
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getTwoFA()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getTwoFA()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual {v2}, Landroid/widget/EditText;->getContext()Landroid/content/Context;
|
|
|
|
move-result-object v2
|
|
|
|
const v3, 0x7f12147f
|
|
|
|
invoke-virtual {v2, v3}, Landroid/content/Context;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual {v1, v2}, Landroid/widget/EditText;->setError(Ljava/lang/CharSequence;)V
|
|
|
|
return-void
|
|
|
|
:cond_6
|
|
new-instance v1, Lcom/discord/restapi/RestAPIParams$UserInfo;
|
|
|
|
const/4 v4, 0x0
|
|
|
|
const/4 v5, 0x0
|
|
|
|
const/4 v8, 0x0
|
|
|
|
sget-object v3, Lcom/discord/stores/StoreStream;->Companion:Lcom/discord/stores/StoreStream$Companion;
|
|
|
|
invoke-virtual {v3}, Lcom/discord/stores/StoreStream$Companion;->getNotifications()Lcom/discord/stores/StoreNotifications;
|
|
|
|
move-result-object v3
|
|
|
|
invoke-virtual {v3}, Lcom/discord/stores/StoreNotifications;->getPushToken()Ljava/lang/String;
|
|
|
|
move-result-object v9
|
|
|
|
const/4 v11, 0x0
|
|
|
|
const/4 v12, 0x0
|
|
|
|
const/16 v13, 0x193
|
|
|
|
const/16 v16, 0x0
|
|
|
|
move-object v3, v1
|
|
|
|
const/4 v15, 0x1
|
|
|
|
move-object/from16 v14, v16
|
|
|
|
invoke-direct/range {v3 .. v14}, Lcom/discord/restapi/RestAPIParams$UserInfo;-><init>(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Integer;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
|
|
invoke-static {v0, v2, v15, v2}, Lcom/discord/app/AppFragment;->hideKeyboard$default(Lcom/discord/app/AppFragment;Landroid/view/View;ILjava/lang/Object;)V
|
|
|
|
sget-object v3, Lcom/discord/utilities/rest/RestAPI;->Companion:Lcom/discord/utilities/rest/RestAPI$Companion;
|
|
|
|
invoke-virtual {v3}, Lcom/discord/utilities/rest/RestAPI$Companion;->getApi()Lcom/discord/utilities/rest/RestAPI;
|
|
|
|
move-result-object v3
|
|
|
|
invoke-virtual {v3, v1}, Lcom/discord/utilities/rest/RestAPI;->patchUser(Lcom/discord/restapi/RestAPIParams$UserInfo;)Lrx/Observable;
|
|
|
|
move-result-object v1
|
|
|
|
const/4 v3, 0x0
|
|
|
|
invoke-static {v1, v3, v15, v2}, Lcom/discord/utilities/rx/ObservableExtensionsKt;->restSubscribeOn$default(Lrx/Observable;ZILjava/lang/Object;)Lrx/Observable;
|
|
|
|
move-result-object v1
|
|
|
|
const/4 v3, 0x2
|
|
|
|
invoke-static {v1, v0, v2, v3, 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 v1
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getDimmerView()Lcom/discord/utilities/dimmer/DimmerView;
|
|
|
|
move-result-object v2
|
|
|
|
const-wide/16 v4, 0x0
|
|
|
|
invoke-static {v2, v4, v5, v3}, Lf/a/b/k;->a(Lcom/discord/utilities/dimmer/DimmerView;JI)Lrx/Observable$c;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual {v1, v2}, Lrx/Observable;->a(Lrx/Observable$c;)Lrx/Observable;
|
|
|
|
move-result-object v1
|
|
|
|
new-instance v2, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$saveNewPassword$1;
|
|
|
|
invoke-direct {v2, v0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$saveNewPassword$1;-><init>(Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;)V
|
|
|
|
invoke-static {v2, v0}, Lf/a/b/k;->a(Lrx/functions/Action1;Lcom/discord/app/AppFragment;)Lrx/Observable$c;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual {v1, v2}, Lrx/Observable;->a(Lrx/Observable$c;)Lrx/Observable;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public getContentViewResId()I
|
|
.locals 1
|
|
|
|
const v0, 0x7f0d0231
|
|
|
|
return v0
|
|
.end method
|
|
|
|
.method public onViewBound(Landroid/view/View;)V
|
|
.locals 6
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
invoke-super {p0, p1}, Lcom/discord/app/AppFragment;->onViewBound(Landroid/view/View;)V
|
|
|
|
const p1, 0x7f121534
|
|
|
|
invoke-virtual {p0, p1}, Lcom/discord/app/AppFragment;->setActionBarSubtitle(I)Lkotlin/Unit;
|
|
|
|
const p1, 0x7f1203b2
|
|
|
|
invoke-virtual {p0, p1}, Lcom/discord/app/AppFragment;->setActionBarTitle(I)Lkotlin/Unit;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
const/4 v2, 0x0
|
|
|
|
const/4 v3, 0x0
|
|
|
|
const/4 v4, 0x7
|
|
|
|
const/4 v5, 0x0
|
|
|
|
move-object v0, p0
|
|
|
|
invoke-static/range {v0 .. v5}, Lcom/discord/app/AppFragment;->setActionBarDisplayHomeAsUpEnabled$default(Lcom/discord/app/AppFragment;ZLjava/lang/Integer;Ljava/lang/Integer;ILjava/lang/Object;)Landroidx/appcompat/widget/Toolbar;
|
|
|
|
iget-object p1, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->state:Lcom/discord/utilities/stateful/StatefulViews;
|
|
|
|
invoke-virtual {p1, p0}, Lcom/discord/utilities/stateful/StatefulViews;->setupUnsavedChangesConfirmation(Lcom/discord/app/AppFragment;)V
|
|
|
|
iget-object p1, p0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->state:Lcom/discord/utilities/stateful/StatefulViews;
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getSaveButton()Lcom/google/android/material/floatingactionbutton/FloatingActionButton;
|
|
|
|
move-result-object v0
|
|
|
|
const/4 v1, 0x1
|
|
|
|
new-array v1, v1, [Landroid/widget/TextView;
|
|
|
|
const/4 v2, 0x0
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getNewPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v3
|
|
|
|
aput-object v3, v1, v2
|
|
|
|
invoke-virtual {p1, p0, v0, v1}, Lcom/discord/utilities/stateful/StatefulViews;->setupTextWatcherWithSaveAction(Lcom/discord/app/AppFragment;Landroid/view/View;[Landroid/widget/TextView;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getCurrentPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object p1
|
|
|
|
new-instance v0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$onViewBound$1;
|
|
|
|
invoke-direct {v0, p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$onViewBound$1;-><init>(Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;)V
|
|
|
|
invoke-static {p1, p0, v0}, Lcom/discord/utilities/view/text/TextWatcherKt;->addBindedTextWatcher(Landroid/widget/TextView;Landroidx/fragment/app/Fragment;Lkotlin/jvm/functions/Function1;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getNewPassword()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object p1
|
|
|
|
new-instance v0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$onViewBound$2;
|
|
|
|
invoke-direct {v0, p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$onViewBound$2;-><init>(Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;)V
|
|
|
|
invoke-static {p1, p0, v0}, Lcom/discord/utilities/view/text/TextWatcherKt;->addBindedTextWatcher(Landroid/widget/TextView;Landroidx/fragment/app/Fragment;Lkotlin/jvm/functions/Function1;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;->getTwoFA()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object p1
|
|
|
|
new-instance v0, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$onViewBound$3;
|
|
|
|
invoke-direct {v0, p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$onViewBound$3;-><init>(Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;)V
|
|
|
|
invoke-static {p1, p0, v0}, Lcom/discord/utilities/view/text/TextWatcherKt;->addBindedTextWatcher(Landroid/widget/TextView;Landroidx/fragment/app/Fragment;Lkotlin/jvm/functions/Function1;)V
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
const-string p1, "view"
|
|
|
|
invoke-static {p1}, Ly/u/b/j;->a(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public onViewBoundOrOnResume()V
|
|
.locals 12
|
|
|
|
invoke-super {p0}, Lcom/discord/app/AppFragment;->onViewBoundOrOnResume()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/WidgetSettingsAccountChangePassword;
|
|
|
|
new-instance v9, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$onViewBoundOrOnResume$1;
|
|
|
|
invoke-direct {v9, p0}, Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword$onViewBoundOrOnResume$1;-><init>(Lcom/discord/widgets/settings/account/WidgetSettingsAccountChangePassword;)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
|