apkfuckery/com.discord/smali_classes2/com/discord/widgets/user/phone/WidgetUserPhoneAdd.smali

573 lines
18 KiB
Smali
Raw Normal View History

2020-07-10 04:01:33 +00:00
.class public Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;
2020-05-17 12:40:10 +00:00
.super Lcom/discord/widgets/user/account/WidgetUserAccountVerifyBase;
2020-07-10 04:01:33 +00:00
.source "WidgetUserPhoneAdd.java"
2020-05-17 12:40:10 +00:00
# instance fields
2020-07-10 04:01:33 +00:00
.field public close:Landroid/view/View;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
.field public dimmer:Lcom/discord/utilities/dimmer/DimmerView;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
.field public userPhoneAddCountryCode:Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
.field public userPhoneAddNumber:Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
.field public userPhoneNext:Landroid/view/View;
2020-05-17 12:40:10 +00:00
# direct methods
2020-07-10 04:01:33 +00:00
.method public constructor <init>()V
.locals 0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {p0}, Lcom/discord/widgets/user/account/WidgetUserAccountVerifyBase;-><init>()V
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
return-void
.end method
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
.method private configureNextButtonState()V
.locals 2
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
iget-object v0, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddCountryCode:Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {v0}, Lcom/discord/utilities/view/extensions/ViewExtensions;->getTextOrEmpty(Lcom/google/android/material/textfield/TextInputLayout;)Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object v0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result v0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-nez v0, :cond_0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
iget-object v0, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddNumber:Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {v0}, Lcom/discord/utilities/view/extensions/ViewExtensions;->getTextOrEmpty(Lcom/google/android/material/textfield/TextInputLayout;)Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object v0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result v0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-nez v0, :cond_0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const/4 v0, 0x1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
goto :goto_0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
:cond_0
const/4 v0, 0x0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
:goto_0
iget-object v1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneNext:Landroid/view/View;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v1, v0}, Landroid/view/View;->setEnabled(Z)V
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
return-void
.end method
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
.method public static synthetic f(Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;Landroid/text/Editable;)Lkotlin/Unit;
.locals 0
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {p0, p1}, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->handleAreaCodeTextChanged(Landroid/text/Editable;)Lkotlin/Unit;
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
move-result-object p0
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
return-object p0
.end method
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
.method public static synthetic g(Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;Landroid/text/Editable;)Lkotlin/Unit;
.locals 0
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {p0, p1}, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->handlePhoneNumberTextChanged(Landroid/text/Editable;)Lkotlin/Unit;
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
move-result-object p0
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
return-object p0
.end method
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
.method public static getCountryCodeWithPrefix(Ljava/lang/String;)Ljava/lang/String;
.locals 2
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const-string v0, "+"
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p0, v0}, Ljava/lang/String;->startsWith(Ljava/lang/String;)Z
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result v0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-nez v0, :cond_0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p0}, Ljava/lang/String;->length()I
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result v0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-lez v0, :cond_1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
new-instance v0, Ljava/lang/StringBuilder;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const/16 v1, 0x2b
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(C)Ljava/lang/StringBuilder;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v0, p0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object p0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
return-object p0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
:cond_0
invoke-virtual {p0}, Ljava/lang/String;->length()I
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result p0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const/4 v0, 0x1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-ne p0, v0, :cond_1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const-string p0, ""
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
return-object p0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
:cond_1
const/4 p0, 0x0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
return-object p0
.end method
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
.method public static getFormattedPhoneNumber(Ljava/lang/String;)Ljava/lang/String;
.locals 4
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
new-instance v0, Ljava/lang/StringBuilder;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const-string v1, "-"
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const-string v2, ""
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p0, v1, v2}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object v1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {v0, v1}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v0}, Ljava/lang/StringBuilder;->length()I
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result v1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const/4 v2, 0x6
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const/16 v3, 0x2d
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-le v1, v2, :cond_0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v0, v2}, Ljava/lang/StringBuilder;->charAt(I)C
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result v1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-eq v1, v3, :cond_0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v0, v2, v3}, Ljava/lang/StringBuilder;->insert(IC)Ljava/lang/StringBuilder;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
:cond_0
invoke-virtual {v0}, Ljava/lang/StringBuilder;->length()I
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result v1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const/4 v2, 0x3
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-le v1, v2, :cond_1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v0, v2}, Ljava/lang/StringBuilder;->charAt(I)C
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result v1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-eq v1, v3, :cond_1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v0, v2, v3}, Ljava/lang/StringBuilder;->insert(IC)Ljava/lang/StringBuilder;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
:cond_1
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object v1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p0, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result p0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-nez p0, :cond_2
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
2020-05-17 12:40:10 +00:00
move-result-object p0
2020-07-10 04:01:33 +00:00
goto :goto_0
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
:cond_2
const/4 p0, 0x0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
:goto_0
2020-05-17 12:40:10 +00:00
return-object p0
.end method
2020-07-10 04:01:33 +00:00
.method private getPhoneNumberWithCountryCode()Ljava/lang/String;
.locals 3
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const/4 v0, 0x2
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
new-array v0, v0, [Ljava/lang/Object;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
iget-object v1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddCountryCode:Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {v1}, Lcom/discord/utilities/view/extensions/ViewExtensions;->getTextOrEmpty(Lcom/google/android/material/textfield/TextInputLayout;)Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object v1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const/4 v2, 0x0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
aput-object v1, v0, v2
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
iget-object v1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddNumber:Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {v1}, Lcom/discord/utilities/view/extensions/ViewExtensions;->getTextOrEmpty(Lcom/google/android/material/textfield/TextInputLayout;)Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object v1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const/4 v2, 0x1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
aput-object v1, v0, v2
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const-string v1, "%s%s"
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {v1, v0}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
2020-05-17 12:40:10 +00:00
move-result-object v0
2020-07-10 04:01:33 +00:00
return-object v0
.end method
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
.method private handleAreaCodeTextChanged(Landroid/text/Editable;)Lkotlin/Unit;
.locals 2
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1}, Ljava/lang/Object;->toString()Ljava/lang/String;
2020-05-17 12:40:10 +00:00
move-result-object v0
2020-07-10 04:01:33 +00:00
invoke-static {v0}, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->getCountryCodeWithPrefix(Ljava/lang/String;)Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-08 16:44:49 +00:00
move-result-object v0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-eqz v0, :cond_0
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
iget-object v1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddCountryCode:Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {v1, v0}, Lcom/discord/utilities/view/extensions/ViewExtensions;->setText(Lcom/google/android/material/textfield/TextInputLayout;Ljava/lang/CharSequence;)Lkotlin/Unit;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
iget-object v1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddCountryCode:Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {v1}, Lcom/discord/utilities/view/extensions/ViewExtensions;->setSelectionEnd(Lcom/google/android/material/textfield/TextInputLayout;)Lkotlin/Unit;
2020-05-17 12:40:10 +00:00
:cond_0
2020-07-10 04:01:33 +00:00
if-nez v0, :cond_1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-interface {p1}, Landroid/text/Editable;->length()I
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result p1
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
const/4 v0, 0x3
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-le p1, v0, :cond_1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
iget-object p1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddNumber:Lcom/google/android/material/textfield/TextInputLayout;
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1}, Landroid/widget/LinearLayout;->requestFocus()Z
2020-07-09 23:59:55 +00:00
:cond_1
2020-07-10 04:01:33 +00:00
invoke-direct {p0}, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->configureNextButtonState()V
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
sget-object p1, Lkotlin/Unit;->a:Lkotlin/Unit;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
return-object p1
.end method
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
.method private handlePhoneNumberTextChanged(Landroid/text/Editable;)Lkotlin/Unit;
.locals 1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1}, Ljava/lang/Object;->toString()Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object p1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {p1}, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->getFormattedPhoneNumber(Ljava/lang/String;)Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object p1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {p0}, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->configureNextButtonState()V
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-nez p1, :cond_0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
sget-object p1, Lkotlin/Unit;->a:Lkotlin/Unit;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
return-object p1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
:cond_0
iget-object v0, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddNumber:Lcom/google/android/material/textfield/TextInputLayout;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {v0, p1}, Lcom/discord/utilities/view/extensions/ViewExtensions;->setText(Lcom/google/android/material/textfield/TextInputLayout;Ljava/lang/CharSequence;)Lkotlin/Unit;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
iget-object p1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddNumber:Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {p1}, Lcom/discord/utilities/view/extensions/ViewExtensions;->setSelectionEnd(Lcom/google/android/material/textfield/TextInputLayout;)Lkotlin/Unit;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
sget-object p1, Lkotlin/Unit;->a:Lkotlin/Unit;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
return-object p1
2020-07-09 23:59:55 +00:00
.end method
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
.method public static launch(Landroid/content/Context;Lcom/discord/widgets/user/account/WidgetUserAccountVerifyBase$Mode;)V
.locals 2
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const/4 v0, 0x1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const/4 v1, 0x0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {p1, v0, v1, v1}, Lcom/discord/widgets/user/account/WidgetUserAccountVerifyBase;->getLaunchIntent(Lcom/discord/widgets/user/account/WidgetUserAccountVerifyBase$Mode;ZZZ)Landroid/content/Intent;
2020-05-17 12:40:10 +00:00
2020-07-09 23:59:55 +00:00
move-result-object v0
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
sget-object v1, Lcom/discord/widgets/user/account/WidgetUserAccountVerifyBase$Mode;->NO_HISTORY_FROM_USER_SETTINGS:Lcom/discord/widgets/user/account/WidgetUserAccountVerifyBase$Mode;
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
if-ne p1, v1, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
const/high16 p1, 0x40000000 # 2.0f
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v0, p1}, Landroid/content/Intent;->addFlags(I)Landroid/content/Intent;
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
:cond_0
const-class p1, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {p0, p1, v0}, Lf/a/b/l;->e(Landroid/content/Context;Ljava/lang/Class;Landroid/content/Intent;)V
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
return-void
.end method
2020-07-08 16:44:49 +00:00
2020-07-10 04:01:33 +00:00
# virtual methods
.method public getContentViewResId()I
.locals 1
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
const v0, 0x7f0d0282
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
return v0
2020-07-08 16:44:49 +00:00
.end method
2020-07-10 04:01:33 +00:00
.method public synthetic h(Landroid/view/View;Ljava/lang/Void;)V
.locals 0
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1}, Landroid/view/View;->getContext()Landroid/content/Context;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
move-result-object p1
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p0}, Lcom/discord/widgets/user/account/WidgetUserAccountVerifyBase;->getMode()Lcom/discord/widgets/user/account/WidgetUserAccountVerifyBase$Mode;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object p2
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {p1, p2}, Lcom/discord/widgets/user/phone/WidgetUserPhoneVerify;->launch(Landroid/content/Context;Lcom/discord/widgets/user/account/WidgetUserAccountVerifyBase$Mode;)V
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
return-void
2020-07-09 23:59:55 +00:00
.end method
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
.method public synthetic i(Landroid/view/View;)V
2020-07-09 23:59:55 +00:00
.locals 3
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {}, Lcom/discord/utilities/rest/RestAPI;->getApi()Lcom/discord/utilities/rest/RestAPI;
2020-05-17 12:40:10 +00:00
move-result-object v0
2020-07-10 04:01:33 +00:00
new-instance v1, Lcom/discord/restapi/RestAPIParams$Phone;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {p0}, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->getPhoneNumberWithCountryCode()Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object v2
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {v1, v2}, Lcom/discord/restapi/RestAPIParams$Phone;-><init>(Ljava/lang/String;)V
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v0, v1}, Lcom/discord/utilities/rest/RestAPI;->userAddPhone(Lcom/discord/restapi/RestAPIParams$Phone;)Lrx/Observable;
2020-05-17 12:40:10 +00:00
move-result-object v0
2020-07-10 04:01:33 +00:00
invoke-static {}, Lf/a/b/r;->e()Lrx/Observable$c;
2020-05-17 12:40:10 +00:00
move-result-object v1
2020-07-10 04:01:33 +00:00
invoke-virtual {v0, v1}, Lrx/Observable;->k(Lrx/Observable$c;)Lrx/Observable;
2020-05-17 12:40:10 +00:00
move-result-object v0
2020-07-10 04:01:33 +00:00
iget-object v1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->dimmer:Lcom/discord/utilities/dimmer/DimmerView;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {v1}, Lf/a/b/r;->t(Lcom/discord/utilities/dimmer/DimmerView;)Lrx/Observable$c;
2020-05-17 12:40:10 +00:00
2020-07-09 23:59:55 +00:00
move-result-object v1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {v0, v1}, Lrx/Observable;->k(Lrx/Observable$c;)Lrx/Observable;
2020-05-17 12:40:10 +00:00
2020-07-09 23:59:55 +00:00
move-result-object v0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {p0}, Lf/a/b/r;->r(Lcom/discord/app/AppComponent;)Lrx/Observable$c;
2020-05-17 12:40:10 +00:00
2020-07-09 23:59:55 +00:00
move-result-object v1
2020-07-10 04:01:33 +00:00
invoke-virtual {v0, v1}, Lrx/Observable;->k(Lrx/Observable$c;)Lrx/Observable;
2020-05-17 12:40:10 +00:00
2020-07-09 23:59:55 +00:00
move-result-object v0
2020-07-10 04:01:33 +00:00
new-instance v1, Lf/a/o/g/v/e;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {v1, p0, p1}, Lf/a/o/g/v/e;-><init>(Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;Landroid/view/View;)V
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p0}, Landroidx/fragment/app/Fragment;->getContext()Landroid/content/Context;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object p1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {v1, p1}, Lf/a/b/r;->l(Lrx/functions/Action1;Landroid/content/Context;)Lrx/Observable$c;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object p1
invoke-virtual {v0, p1}, Lrx/Observable;->k(Lrx/Observable$c;)Lrx/Observable;
2020-05-17 12:40:10 +00:00
2020-07-09 23:59:55 +00:00
return-void
.end method
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
.method public synthetic j(Landroid/view/View;)V
.locals 0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p0}, Landroidx/fragment/app/Fragment;->getActivity()Landroidx/fragment/app/FragmentActivity;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object p1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
if-eqz p1, :cond_0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p0}, Landroidx/fragment/app/Fragment;->getActivity()Landroidx/fragment/app/FragmentActivity;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object p1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1}, Landroidx/activity/ComponentActivity;->onBackPressed()V
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
:cond_0
return-void
2020-07-09 23:59:55 +00:00
.end method
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
.method public onViewBound(Landroid/view/View;)V
2020-07-09 23:59:55 +00:00
.locals 1
2020-07-10 04:01:33 +00:00
.param p1 # Landroid/view/View;
.annotation build Landroidx/annotation/NonNull;
.end annotation
.end param
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-super {p0, p1}, Lcom/discord/widgets/user/account/WidgetUserAccountVerifyBase;->onViewBound(Landroid/view/View;)V
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const v0, 0x7f0a0969
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1, v0}, Landroid/view/View;->findViewById(I)Landroid/view/View;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object v0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
check-cast v0, Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
iput-object v0, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddCountryCode:Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const v0, 0x7f0a096b
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1, v0}, Landroid/view/View;->findViewById(I)Landroid/view/View;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object v0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
check-cast v0, Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
iput-object v0, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddNumber:Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const v0, 0x7f0a096a
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1, v0}, Landroid/view/View;->findViewById(I)Landroid/view/View;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object v0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
iput-object v0, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneNext:Landroid/view/View;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const v0, 0x7f0a0265
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1, v0}, Landroid/view/View;->findViewById(I)Landroid/view/View;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
move-result-object v0
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
iput-object v0, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->close:Landroid/view/View;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
const v0, 0x7f0a02d7
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1, v0}, Landroid/view/View;->findViewById(I)Landroid/view/View;
2020-05-17 12:40:10 +00:00
2020-07-09 23:59:55 +00:00
move-result-object p1
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
check-cast p1, Lcom/discord/utilities/dimmer/DimmerView;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
iput-object p1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->dimmer:Lcom/discord/utilities/dimmer/DimmerView;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
iget-object p1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddCountryCode:Lcom/google/android/material/textfield/TextInputLayout;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
new-instance v0, Lf/a/o/g/v/a;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {v0, p0}, Lf/a/o/g/v/a;-><init>(Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;)V
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {p1, p0, v0}, Lcom/discord/utilities/view/extensions/ViewExtensions;->addBindedTextWatcher(Lcom/google/android/material/textfield/TextInputLayout;Landroidx/fragment/app/Fragment;Lkotlin/jvm/functions/Function1;)Lkotlin/Unit;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
iget-object p1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddNumber:Lcom/google/android/material/textfield/TextInputLayout;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
new-instance v0, Lf/a/o/g/v/b;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {v0, p0}, Lf/a/o/g/v/b;-><init>(Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;)V
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-static {p1, p0, v0}, Lcom/discord/utilities/view/extensions/ViewExtensions;->addBindedTextWatcher(Lcom/google/android/material/textfield/TextInputLayout;Landroidx/fragment/app/Fragment;Lkotlin/jvm/functions/Function1;)Lkotlin/Unit;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
iget-object p1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneAddNumber:Lcom/google/android/material/textfield/TextInputLayout;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1}, Landroid/widget/LinearLayout;->requestFocus()Z
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
iget-object p1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->userPhoneNext:Landroid/view/View;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
new-instance v0, Lf/a/o/g/v/d;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {v0, p0}, Lf/a/o/g/v/d;-><init>(Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;)V
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1, v0}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
iget-object p1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->close:Landroid/view/View;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p0}, Lcom/discord/widgets/user/account/WidgetUserAccountVerifyBase;->isForced()Z
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
move-result v0
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
if-eqz v0, :cond_0
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
const/16 v0, 0x8
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
goto :goto_0
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
:cond_0
const/4 v0, 0x0
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
:goto_0
invoke-virtual {p1, v0}, Landroid/view/View;->setVisibility(I)V
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
iget-object p1, p0, Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;->close:Landroid/view/View;
2020-05-17 12:40:10 +00:00
2020-07-10 04:01:33 +00:00
new-instance v0, Lf/a/o/g/v/c;
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-direct {v0, p0}, Lf/a/o/g/v/c;-><init>(Lcom/discord/widgets/user/phone/WidgetUserPhoneAdd;)V
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
invoke-virtual {p1, v0}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
2020-07-09 23:59:55 +00:00
2020-07-10 04:01:33 +00:00
return-void
2020-05-17 12:40:10 +00:00
.end method