1844 lines
60 KiB
Smali
1844 lines
60 KiB
Smali
.class public final Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
.super Lcom/discord/app/AppFragment;
|
|
.source "WidgetSettingsGifting.kt"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/MemberClasses;
|
|
value = {
|
|
Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$Companion;
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field public static final synthetic $$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
.field public static final Companion:Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$Companion;
|
|
|
|
.field public static final VIEW_INDEX_FAILURE:I = 0x1
|
|
|
|
.field public static final VIEW_INDEX_LOADED:I = 0x2
|
|
|
|
.field public static final VIEW_INDEX_LOADING:I
|
|
|
|
|
|
# instance fields
|
|
.field public adapter:Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter;
|
|
|
|
.field public final buyNitroClassicMonthly$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final buyNitroClassicYearly$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final buyNitroMonthly$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final buyNitroYearly$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final codeInput$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final codeInputProgress$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final codeInputWrap$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public connection:Landroid/content/ServiceConnection;
|
|
|
|
.field public final flipper$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final nitroClassicLearnMore$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final nitroLearnMore$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final recyclerView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final retry$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public viewModel:Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel;
|
|
|
|
|
|
# direct methods
|
|
.method public static constructor <clinit>()V
|
|
.locals 6
|
|
|
|
const/16 v0, 0xc
|
|
|
|
new-array v0, v0, [Lkotlin/reflect/KProperty;
|
|
|
|
new-instance v1, Lw/u/b/u;
|
|
|
|
const-class v2, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
invoke-static {v2}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v2
|
|
|
|
const-string v3, "retry"
|
|
|
|
const-string v4, "getRetry()Landroid/view/View;"
|
|
|
|
invoke-direct {v1, v2, v3, v4}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v2, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v2, v1}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
const/4 v2, 0x0
|
|
|
|
aput-object v1, v0, v2
|
|
|
|
const/4 v1, 0x1
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
invoke-static {v3}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "flipper"
|
|
|
|
const-string v5, "getFlipper()Lcom/discord/app/AppViewFlipper;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/4 v1, 0x2
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
invoke-static {v3}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "recyclerView"
|
|
|
|
const-string v5, "getRecyclerView()Landroidx/recyclerview/widget/RecyclerView;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/4 v1, 0x3
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
invoke-static {v3}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "codeInput"
|
|
|
|
const-string v5, "getCodeInput()Landroidx/appcompat/widget/AppCompatEditText;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/4 v1, 0x4
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
invoke-static {v3}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "codeInputWrap"
|
|
|
|
const-string v5, "getCodeInputWrap()Lcom/google/android/material/textfield/TextInputLayout;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/4 v1, 0x5
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
invoke-static {v3}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "codeInputProgress"
|
|
|
|
const-string v5, "getCodeInputProgress()Landroid/view/View;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/4 v1, 0x6
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
invoke-static {v3}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "buyNitroYearly"
|
|
|
|
const-string v5, "getBuyNitroYearly()Lcom/discord/views/BoxedButton;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/4 v1, 0x7
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
invoke-static {v3}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "buyNitroMonthly"
|
|
|
|
const-string v5, "getBuyNitroMonthly()Landroid/widget/Button;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/16 v1, 0x8
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
invoke-static {v3}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "nitroLearnMore"
|
|
|
|
const-string v5, "getNitroLearnMore()Landroid/widget/TextView;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/16 v1, 0x9
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
invoke-static {v3}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "buyNitroClassicYearly"
|
|
|
|
const-string v5, "getBuyNitroClassicYearly()Lcom/discord/views/BoxedButton;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/16 v1, 0xa
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
invoke-static {v3}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "buyNitroClassicMonthly"
|
|
|
|
const-string v5, "getBuyNitroClassicMonthly()Landroid/widget/Button;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/16 v1, 0xb
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
const-class v3, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
invoke-static {v3}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "nitroClassicLearnMore"
|
|
|
|
const-string v5, "getNitroClassicLearnMore()Landroid/widget/TextView;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
sput-object v0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
new-instance v0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$Companion;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
invoke-direct {v0, v1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$Companion;-><init>(Lkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
|
|
sput-object v0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->Companion:Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$Companion;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>()V
|
|
.locals 1
|
|
|
|
invoke-direct {p0}, Lcom/discord/app/AppFragment;-><init>()V
|
|
|
|
const v0, 0x7f0a07f0
|
|
|
|
invoke-static {p0, v0}, Lx/a/a2/w;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->retry$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a07e6
|
|
|
|
invoke-static {p0, v0}, Lx/a/a2/w;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->flipper$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a07f1
|
|
|
|
invoke-static {p0, v0}, Lx/a/a2/w;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->recyclerView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a07e7
|
|
|
|
invoke-static {p0, v0}, Lx/a/a2/w;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->codeInput$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a07e9
|
|
|
|
invoke-static {p0, v0}, Lx/a/a2/w;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->codeInputWrap$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a07e8
|
|
|
|
invoke-static {p0, v0}, Lx/a/a2/w;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->codeInputProgress$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a07ef
|
|
|
|
invoke-static {p0, v0}, Lx/a/a2/w;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->buyNitroYearly$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a07ee
|
|
|
|
invoke-static {p0, v0}, Lx/a/a2/w;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->buyNitroMonthly$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a07ed
|
|
|
|
invoke-static {p0, v0}, Lx/a/a2/w;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->nitroLearnMore$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a07ec
|
|
|
|
invoke-static {p0, v0}, Lx/a/a2/w;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->buyNitroClassicYearly$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a07eb
|
|
|
|
invoke-static {p0, v0}, Lx/a/a2/w;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->buyNitroClassicMonthly$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const v0, 0x7f0a07ea
|
|
|
|
invoke-static {p0, v0}, Lx/a/a2/w;->b(Landroidx/fragment/app/Fragment;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->nitroClassicLearnMore$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final synthetic access$configureUI(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState;)V
|
|
.locals 0
|
|
|
|
invoke-direct {p0, p1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->configureUI(Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final synthetic access$getCodeInput$p(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;)Landroidx/appcompat/widget/AppCompatEditText;
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getCodeInput()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public static final synthetic access$getViewModel$p(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;)Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel;
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->viewModel:Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel;
|
|
|
|
if-eqz p0, :cond_0
|
|
|
|
return-object p0
|
|
|
|
:cond_0
|
|
const-string p0, "viewModel"
|
|
|
|
invoke-static {p0}, Lw/u/b/j;->throwUninitializedPropertyAccessException(Ljava/lang/String;)V
|
|
|
|
const/4 p0, 0x0
|
|
|
|
throw p0
|
|
.end method
|
|
|
|
.method public static final synthetic access$openWebBilling(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;)V
|
|
.locals 0
|
|
|
|
invoke-direct {p0, p1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->openWebBilling(Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final synthetic access$setViewModel$p(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel;)V
|
|
.locals 0
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->viewModel:Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private final configureUI(Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState;)V
|
|
.locals 11
|
|
|
|
instance-of v0, p1, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loading;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getFlipper()Lcom/discord/app/AppViewFlipper;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {p1, v1}, Lcom/discord/app/AppViewFlipper;->setDisplayedChild(I)V
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
instance-of v0, p1, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Failure;
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getFlipper()Lcom/discord/app/AppViewFlipper;
|
|
|
|
move-result-object p1
|
|
|
|
const/4 v0, 0x1
|
|
|
|
invoke-virtual {p1, v0}, Lcom/discord/app/AppViewFlipper;->setDisplayedChild(I)V
|
|
|
|
return-void
|
|
|
|
:cond_1
|
|
instance-of v0, p1, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;
|
|
|
|
const/4 v2, 0x2
|
|
|
|
if-eqz v0, :cond_2
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getFlipper()Lcom/discord/app/AppViewFlipper;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0, v2}, Lcom/discord/app/AppViewFlipper;->setDisplayedChild(I)V
|
|
|
|
:cond_2
|
|
check-cast p1, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;
|
|
|
|
invoke-virtual {p1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;->getResolvingGiftState()Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ResolvingGiftState;
|
|
|
|
move-result-object v0
|
|
|
|
instance-of v0, v0, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ResolvingGiftState$Resolving;
|
|
|
|
invoke-virtual {p1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;->getResolvingGiftState()Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ResolvingGiftState;
|
|
|
|
move-result-object v3
|
|
|
|
instance-of v3, v3, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ResolvingGiftState$Error;
|
|
|
|
const/4 v4, 0x0
|
|
|
|
if-eqz v3, :cond_3
|
|
|
|
const v3, 0x7f1200e1
|
|
|
|
invoke-virtual {p0, v3}, Landroidx/fragment/app/Fragment;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object v3
|
|
|
|
goto :goto_0
|
|
|
|
:cond_3
|
|
move-object v3, v4
|
|
|
|
:goto_0
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getCodeInputProgress()Landroid/view/View;
|
|
|
|
move-result-object v5
|
|
|
|
if-eqz v0, :cond_4
|
|
|
|
const/4 v6, 0x0
|
|
|
|
goto :goto_1
|
|
|
|
:cond_4
|
|
const/16 v6, 0x8
|
|
|
|
:goto_1
|
|
invoke-virtual {v5, v6}, Landroid/view/View;->setVisibility(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getCodeInput()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v5
|
|
|
|
xor-int/lit8 v6, v0, 0x1
|
|
|
|
const/4 v7, 0x0
|
|
|
|
invoke-static {v5, v6, v7, v2, v4}, Lcom/discord/utilities/view/extensions/ViewExtensions;->setEnabledAlpha$default(Landroid/view/View;ZFILjava/lang/Object;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getCodeInput()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v2
|
|
|
|
if-eqz v0, :cond_5
|
|
|
|
goto :goto_2
|
|
|
|
:cond_5
|
|
const/high16 v1, 0x80000
|
|
|
|
:goto_2
|
|
invoke-virtual {v2, v1}, Landroid/widget/EditText;->setInputType(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getCodeInputWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0, v3}, Lcom/google/android/material/textfield/TextInputLayout;->setError(Ljava/lang/CharSequence;)V
|
|
|
|
iget-object v5, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->adapter:Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter;
|
|
|
|
if-eqz v5, :cond_6
|
|
|
|
invoke-direct {p0, p1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->generateListItems(Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;)Ljava/util/List;
|
|
|
|
move-result-object v6
|
|
|
|
new-instance v7, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$configureUI$1;
|
|
|
|
invoke-direct {v7, p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$configureUI$1;-><init>(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;)V
|
|
|
|
new-instance v8, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$configureUI$2;
|
|
|
|
invoke-direct {v8, p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$configureUI$2;-><init>(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;)V
|
|
|
|
sget-object v9, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$configureUI$3;->INSTANCE:Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$configureUI$3;
|
|
|
|
sget-object v10, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$configureUI$4;->INSTANCE:Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$configureUI$4;
|
|
|
|
invoke-virtual/range {v5 .. v10}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter;->configure(Ljava/util/List;Lkotlin/jvm/functions/Function2;Lkotlin/jvm/functions/Function1;Lkotlin/jvm/functions/Function1;Lkotlin/jvm/functions/Function2;)V
|
|
|
|
return-void
|
|
|
|
:cond_6
|
|
const-string p1, "adapter"
|
|
|
|
invoke-static {p1}, Lw/u/b/j;->throwUninitializedPropertyAccessException(Ljava/lang/String;)V
|
|
|
|
throw v4
|
|
.end method
|
|
|
|
.method private final generateListItems(Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;)Ljava/util/List;
|
|
.locals 31
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;",
|
|
")",
|
|
"Ljava/util/List<",
|
|
"Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter$GiftItem;",
|
|
">;"
|
|
}
|
|
.end annotation
|
|
|
|
new-instance v0, Ljava/util/ArrayList;
|
|
|
|
invoke-direct {v0}, Ljava/util/ArrayList;-><init>()V
|
|
|
|
invoke-virtual/range {p1 .. p1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;->getMyEntitlements()Ljava/util/Map;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-interface {v1}, Ljava/util/Map;->isEmpty()Z
|
|
|
|
move-result v1
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
new-instance v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter$GiftItem;
|
|
|
|
const/4 v3, 0x0
|
|
|
|
const/4 v4, 0x0
|
|
|
|
const/4 v5, 0x0
|
|
|
|
const/4 v6, 0x0
|
|
|
|
const/4 v7, 0x0
|
|
|
|
const/4 v8, 0x0
|
|
|
|
const/4 v9, 0x0
|
|
|
|
const/4 v10, 0x0
|
|
|
|
const/4 v11, 0x0
|
|
|
|
const/16 v12, 0x1fe
|
|
|
|
const/4 v13, 0x0
|
|
|
|
move-object v2, v1
|
|
|
|
invoke-direct/range {v2 .. v13}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter$GiftItem;-><init>(ILcom/discord/models/domain/ModelGift;Lcom/discord/models/domain/ModelEntitlement;Ljava/lang/Boolean;Lcom/discord/models/domain/ModelSku;Ljava/lang/Integer;Ljava/lang/Long;Ljava/lang/Boolean;Ljava/lang/Boolean;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
|
|
invoke-interface {v0, v1}, Ljava/util/List;->add(Ljava/lang/Object;)Z
|
|
|
|
goto/16 :goto_a
|
|
|
|
:cond_0
|
|
invoke-virtual/range {p1 .. p1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;->getMyEntitlements()Ljava/util/Map;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-interface {v1}, Ljava/util/Map;->keySet()Ljava/util/Set;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-interface {v1}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object v1
|
|
|
|
:cond_1
|
|
invoke-interface {v1}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v2
|
|
|
|
if-eqz v2, :cond_e
|
|
|
|
invoke-interface {v1}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
check-cast v2, Ljava/lang/Number;
|
|
|
|
invoke-virtual {v2}, Ljava/lang/Number;->longValue()J
|
|
|
|
move-result-wide v2
|
|
|
|
invoke-virtual/range {p1 .. p1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;->getMyEntitlements()Ljava/util/Map;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-static {v2, v3}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-interface {v4, v2}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
check-cast v2, Ljava/util/List;
|
|
|
|
if-eqz v2, :cond_2
|
|
|
|
invoke-static {v2}, Lw/q/l;->first(Ljava/util/List;)Ljava/lang/Object;
|
|
|
|
move-result-object v4
|
|
|
|
check-cast v4, Lcom/discord/models/domain/ModelEntitlement;
|
|
|
|
if-eqz v4, :cond_2
|
|
|
|
invoke-virtual {v4}, Lcom/discord/models/domain/ModelEntitlement;->getSku()Lcom/discord/models/domain/ModelSku;
|
|
|
|
move-result-object v4
|
|
|
|
move-object v10, v4
|
|
|
|
goto :goto_0
|
|
|
|
:cond_2
|
|
const/4 v10, 0x0
|
|
|
|
:goto_0
|
|
invoke-virtual/range {p1 .. p1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;->getExpandedSkuIds()Ljava/util/Set;
|
|
|
|
move-result-object v4
|
|
|
|
if-eqz v10, :cond_3
|
|
|
|
invoke-virtual {v10}, Lcom/discord/models/domain/ModelSku;->getId()J
|
|
|
|
move-result-wide v5
|
|
|
|
invoke-static {v5, v6}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
|
|
|
|
move-result-object v5
|
|
|
|
goto :goto_1
|
|
|
|
:cond_3
|
|
const/4 v5, 0x0
|
|
|
|
:goto_1
|
|
invoke-static {v4, v5}, Lw/q/l;->contains(Ljava/lang/Iterable;Ljava/lang/Object;)Z
|
|
|
|
move-result v4
|
|
|
|
new-instance v15, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter$GiftItem;
|
|
|
|
const/4 v6, 0x1
|
|
|
|
const/4 v7, 0x0
|
|
|
|
const/4 v8, 0x0
|
|
|
|
const/16 v17, 0x0
|
|
|
|
if-eqz v2, :cond_4
|
|
|
|
invoke-interface {v2}, Ljava/util/List;->size()I
|
|
|
|
move-result v5
|
|
|
|
invoke-static {v5}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v5
|
|
|
|
goto :goto_2
|
|
|
|
:cond_4
|
|
invoke-static/range {v17 .. v17}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v5
|
|
|
|
:goto_2
|
|
move-object v11, v5
|
|
|
|
invoke-static {v4}, Ljava/lang/Boolean;->valueOf(Z)Ljava/lang/Boolean;
|
|
|
|
move-result-object v9
|
|
|
|
const/4 v12, 0x0
|
|
|
|
const/4 v13, 0x0
|
|
|
|
const/4 v14, 0x0
|
|
|
|
const/16 v16, 0x1c6
|
|
|
|
const/16 v18, 0x0
|
|
|
|
move-object v5, v15
|
|
|
|
move-object v3, v15
|
|
|
|
move/from16 v15, v16
|
|
|
|
move-object/from16 v16, v18
|
|
|
|
invoke-direct/range {v5 .. v16}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter$GiftItem;-><init>(ILcom/discord/models/domain/ModelGift;Lcom/discord/models/domain/ModelEntitlement;Ljava/lang/Boolean;Lcom/discord/models/domain/ModelSku;Ljava/lang/Integer;Ljava/lang/Long;Ljava/lang/Boolean;Ljava/lang/Boolean;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
|
|
invoke-interface {v0, v3}, Ljava/util/List;->add(Ljava/lang/Object;)Z
|
|
|
|
if-eqz v2, :cond_1
|
|
|
|
invoke-interface {v2}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object v3
|
|
|
|
const/4 v5, 0x0
|
|
|
|
const/4 v6, 0x0
|
|
|
|
:goto_3
|
|
invoke-interface {v3}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v7
|
|
|
|
if-eqz v7, :cond_1
|
|
|
|
invoke-interface {v3}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v7
|
|
|
|
add-int/lit8 v8, v5, 0x1
|
|
|
|
if-ltz v5, :cond_d
|
|
|
|
move-object/from16 v22, v7
|
|
|
|
check-cast v22, Lcom/discord/models/domain/ModelEntitlement;
|
|
|
|
invoke-virtual/range {p1 .. p1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;->getMyGifts()Ljava/util/Map;
|
|
|
|
move-result-object v7
|
|
|
|
invoke-virtual/range {v22 .. v22}, Lcom/discord/models/domain/ModelEntitlement;->getSkuId()J
|
|
|
|
move-result-wide v9
|
|
|
|
invoke-static {v9, v10}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
|
|
|
|
move-result-object v9
|
|
|
|
invoke-interface {v7, v9}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move-result-object v7
|
|
|
|
check-cast v7, Ljava/util/List;
|
|
|
|
if-eqz v7, :cond_5
|
|
|
|
invoke-interface {v7}, Ljava/util/List;->size()I
|
|
|
|
move-result v9
|
|
|
|
goto :goto_4
|
|
|
|
:cond_5
|
|
const/4 v9, -0x1
|
|
|
|
:goto_4
|
|
if-lt v5, v9, :cond_7
|
|
|
|
:cond_6
|
|
const/16 v21, 0x0
|
|
|
|
goto :goto_5
|
|
|
|
:cond_7
|
|
if-eqz v7, :cond_6
|
|
|
|
invoke-interface {v7, v5}, Ljava/util/List;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object v7
|
|
|
|
check-cast v7, Lcom/discord/models/domain/ModelGift;
|
|
|
|
move-object/from16 v21, v7
|
|
|
|
:goto_5
|
|
const/4 v7, 0x1
|
|
|
|
if-nez v21, :cond_9
|
|
|
|
if-lt v6, v7, :cond_8
|
|
|
|
goto :goto_9
|
|
|
|
:cond_8
|
|
add-int/lit8 v6, v6, 0x1
|
|
|
|
:cond_9
|
|
new-instance v9, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter$GiftItem;
|
|
|
|
const/16 v20, 0x2
|
|
|
|
invoke-virtual/range {v22 .. v22}, Lcom/discord/models/domain/ModelEntitlement;->getSubscriptionPlan()Lcom/discord/models/domain/ModelSubscriptionPlan;
|
|
|
|
move-result-object v10
|
|
|
|
if-eqz v10, :cond_a
|
|
|
|
invoke-virtual {v10}, Lcom/discord/models/domain/ModelSubscriptionPlan;->getId()J
|
|
|
|
move-result-wide v10
|
|
|
|
invoke-static {v10, v11}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
|
|
|
|
move-result-object v10
|
|
|
|
move-object/from16 v26, v10
|
|
|
|
goto :goto_6
|
|
|
|
:cond_a
|
|
const/16 v26, 0x0
|
|
|
|
:goto_6
|
|
const/16 v24, 0x0
|
|
|
|
const/16 v25, 0x0
|
|
|
|
invoke-static {v4}, Ljava/lang/Boolean;->valueOf(Z)Ljava/lang/Boolean;
|
|
|
|
move-result-object v23
|
|
|
|
invoke-interface {v2}, Ljava/util/List;->size()I
|
|
|
|
move-result v10
|
|
|
|
sub-int/2addr v10, v7
|
|
|
|
if-ne v5, v10, :cond_b
|
|
|
|
const/4 v5, 0x1
|
|
|
|
goto :goto_7
|
|
|
|
:cond_b
|
|
const/4 v5, 0x0
|
|
|
|
:goto_7
|
|
invoke-static {v5}, Ljava/lang/Boolean;->valueOf(Z)Ljava/lang/Boolean;
|
|
|
|
move-result-object v27
|
|
|
|
if-eqz v21, :cond_c
|
|
|
|
invoke-virtual/range {v21 .. v21}, Lcom/discord/models/domain/ModelGift;->getCode()Ljava/lang/String;
|
|
|
|
move-result-object v5
|
|
|
|
invoke-virtual/range {p1 .. p1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$ViewState$Loaded;->getLastCopiedCode()Ljava/lang/String;
|
|
|
|
move-result-object v10
|
|
|
|
invoke-static {v5, v10}, Lw/u/b/j;->areEqual(Ljava/lang/Object;Ljava/lang/Object;)Z
|
|
|
|
move-result v5
|
|
|
|
if-eqz v5, :cond_c
|
|
|
|
goto :goto_8
|
|
|
|
:cond_c
|
|
const/4 v7, 0x0
|
|
|
|
:goto_8
|
|
invoke-static {v7}, Ljava/lang/Boolean;->valueOf(Z)Ljava/lang/Boolean;
|
|
|
|
move-result-object v28
|
|
|
|
const/16 v29, 0x30
|
|
|
|
const/16 v30, 0x0
|
|
|
|
move-object/from16 v19, v9
|
|
|
|
invoke-direct/range {v19 .. v30}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter$GiftItem;-><init>(ILcom/discord/models/domain/ModelGift;Lcom/discord/models/domain/ModelEntitlement;Ljava/lang/Boolean;Lcom/discord/models/domain/ModelSku;Ljava/lang/Integer;Ljava/lang/Long;Ljava/lang/Boolean;Ljava/lang/Boolean;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
|
|
invoke-interface {v0, v9}, Ljava/util/List;->add(Ljava/lang/Object;)Z
|
|
|
|
:goto_9
|
|
move v5, v8
|
|
|
|
goto/16 :goto_3
|
|
|
|
:cond_d
|
|
invoke-static {}, Le/k/a/c/e/p/g;->throwIndexOverflow()V
|
|
|
|
const/4 v0, 0x0
|
|
|
|
throw v0
|
|
|
|
:cond_e
|
|
:goto_a
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getBuyNitroClassicMonthly()Landroid/widget/Button;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->buyNitroClassicMonthly$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/16 v2, 0xa
|
|
|
|
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 getBuyNitroClassicYearly()Lcom/discord/views/BoxedButton;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->buyNitroClassicYearly$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/16 v2, 0x9
|
|
|
|
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/BoxedButton;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getBuyNitroMonthly()Landroid/widget/Button;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->buyNitroMonthly$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/4 v2, 0x7
|
|
|
|
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 getBuyNitroYearly()Lcom/discord/views/BoxedButton;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->buyNitroYearly$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/4 v2, 0x6
|
|
|
|
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/BoxedButton;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getCodeInput()Landroidx/appcompat/widget/AppCompatEditText;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->codeInput$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$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, Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getCodeInputProgress()Landroid/view/View;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->codeInputProgress$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$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, Landroid/view/View;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getCodeInputWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->codeInputWrap$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$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 getFlipper()Lcom/discord/app/AppViewFlipper;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->flipper$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$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, Lcom/discord/app/AppViewFlipper;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getNitroClassicLearnMore()Landroid/widget/TextView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->nitroClassicLearnMore$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/16 v2, 0xb
|
|
|
|
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 getNitroLearnMore()Landroid/widget/TextView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->nitroLearnMore$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/16 v2, 0x8
|
|
|
|
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 getRecyclerView()Landroidx/recyclerview/widget/RecyclerView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->recyclerView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$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/recyclerview/widget/RecyclerView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getRetry()Landroid/view/View;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->retry$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->$$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/view/View;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method public static final launch(Landroid/content/Context;)V
|
|
.locals 1
|
|
|
|
sget-object v0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->Companion:Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$Companion;
|
|
|
|
invoke-virtual {v0, p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$Companion;->launch(Landroid/content/Context;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private final openWebBilling(Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;)V
|
|
.locals 9
|
|
|
|
new-instance v8, Lcom/discord/utilities/analytics/Traits$Location;
|
|
|
|
const-string v1, "User Settings"
|
|
|
|
const-string v2, "Gifting"
|
|
|
|
const-string v3, "Button CTA"
|
|
|
|
const-string v4, "buy"
|
|
|
|
const/4 v5, 0x0
|
|
|
|
const/16 v6, 0x10
|
|
|
|
const/4 v7, 0x0
|
|
|
|
move-object v0, v8
|
|
|
|
invoke-direct/range {v0 .. v7}, Lcom/discord/utilities/analytics/Traits$Location;-><init>(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Integer;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
|
|
sget-object v0, Lcom/discord/utilities/premium/PremiumUtils;->INSTANCE:Lcom/discord/utilities/premium/PremiumUtils;
|
|
|
|
const/4 v4, 0x1
|
|
|
|
move-object v1, p0
|
|
|
|
move-object v2, p1
|
|
|
|
move-object v3, v8
|
|
|
|
invoke-static/range {v0 .. v7}, Lcom/discord/utilities/premium/PremiumUtils;->openWebPurchasePremium$default(Lcom/discord/utilities/premium/PremiumUtils;Lcom/discord/app/AppFragment;Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;Lcom/discord/utilities/analytics/Traits$Location;ZLandroid/net/Uri;ILjava/lang/Object;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public getContentViewResId()I
|
|
.locals 1
|
|
|
|
const v0, 0x7f0d0230
|
|
|
|
return v0
|
|
.end method
|
|
|
|
.method public onPause()V
|
|
.locals 2
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->connection:Landroid/content/ServiceConnection;
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
invoke-virtual {p0}, Landroidx/fragment/app/Fragment;->requireContext()Landroid/content/Context;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v1, v0}, Landroid/content/Context;->unbindService(Landroid/content/ServiceConnection;)V
|
|
|
|
:cond_0
|
|
const/4 v0, 0x0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->connection:Landroid/content/ServiceConnection;
|
|
|
|
invoke-super {p0}, Lcom/discord/app/AppFragment;->onPause()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public onResume()V
|
|
.locals 3
|
|
|
|
invoke-super {p0}, Lcom/discord/app/AppFragment;->onResume()V
|
|
|
|
sget-object v0, Lcom/discord/utilities/premium/PremiumUtils;->INSTANCE:Lcom/discord/utilities/premium/PremiumUtils;
|
|
|
|
invoke-virtual {p0}, Landroidx/fragment/app/Fragment;->requireContext()Landroid/content/Context;
|
|
|
|
move-result-object v1
|
|
|
|
const-string v2, "requireContext()"
|
|
|
|
invoke-static {v1, v2}, Lw/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-virtual {v0, v1}, Lcom/discord/utilities/premium/PremiumUtils;->warmupBillingTabs(Landroid/content/Context;)Landroidx/browser/customtabs/CustomTabsServiceConnection;
|
|
|
|
move-result-object v0
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->connection:Landroid/content/ServiceConnection;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public onViewBound(Landroid/view/View;)V
|
|
.locals 16
|
|
|
|
move-object/from16 v0, p0
|
|
|
|
const/4 v1, 0x0
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
invoke-super/range {p0 .. p1}, Lcom/discord/app/AppFragment;->onViewBound(Landroid/view/View;)V
|
|
|
|
const/4 v2, 0x3
|
|
|
|
const/4 v3, 0x0
|
|
|
|
invoke-static {v0, v3, v1, v2, v1}, Lcom/discord/app/AppFragment;->setActionBarDisplayHomeAsUpEnabled$default(Lcom/discord/app/AppFragment;ZLjava/lang/Integer;ILjava/lang/Object;)Landroidx/appcompat/widget/Toolbar;
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getRetry()Landroid/view/View;
|
|
|
|
move-result-object v2
|
|
|
|
sget-object v4, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$1;->INSTANCE:Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$1;
|
|
|
|
invoke-virtual {v2, v4}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getCodeInput()Landroidx/appcompat/widget/AppCompatEditText;
|
|
|
|
move-result-object v2
|
|
|
|
new-instance v4, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$2;
|
|
|
|
invoke-direct {v4, v0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$2;-><init>(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;)V
|
|
|
|
const/4 v5, 0x1
|
|
|
|
invoke-static {v2, v3, v4, v5, v1}, Lcom/discord/utilities/view/extensions/ViewExtensions;->setOnImeActionDone$default(Landroid/widget/EditText;ZLkotlin/jvm/functions/Function1;ILjava/lang/Object;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getCodeInputWrap()Lcom/google/android/material/textfield/TextInputLayout;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual/range {p0 .. p0}, Landroidx/fragment/app/Fragment;->requireContext()Landroid/content/Context;
|
|
|
|
move-result-object v4
|
|
|
|
const v6, 0x7f06020b
|
|
|
|
invoke-static {v4, v6}, Lcom/discord/utilities/color/ColorCompat;->getColor(Landroid/content/Context;I)I
|
|
|
|
move-result v4
|
|
|
|
invoke-static {v4}, Landroid/content/res/ColorStateList;->valueOf(I)Landroid/content/res/ColorStateList;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-virtual {v2, v4}, Lcom/google/android/material/textfield/TextInputLayout;->setErrorTextColor(Landroid/content/res/ColorStateList;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getBuyNitroYearly()Lcom/discord/views/BoxedButton;
|
|
|
|
move-result-object v2
|
|
|
|
new-array v4, v5, [Ljava/lang/Object;
|
|
|
|
sget-object v6, Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;->PREMIUM_YEAR_TIER_2:Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;
|
|
|
|
invoke-virtual {v6}, Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;->getPrice()I
|
|
|
|
move-result v6
|
|
|
|
invoke-virtual/range {p0 .. p0}, Landroidx/fragment/app/Fragment;->requireContext()Landroid/content/Context;
|
|
|
|
move-result-object v7
|
|
|
|
const-string v8, "requireContext()"
|
|
|
|
invoke-static {v7, v8}, Lw/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-static {v6, v7}, Lcom/discord/utilities/billing/PremiumUtilsKt;->getFormattedPrice(ILandroid/content/Context;)Ljava/lang/CharSequence;
|
|
|
|
move-result-object v6
|
|
|
|
aput-object v6, v4, v3
|
|
|
|
const v6, 0x7f1202be
|
|
|
|
invoke-virtual {v0, v6, v4}, Landroidx/fragment/app/Fragment;->getString(I[Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-virtual {v2, v4}, Lcom/discord/views/BoxedButton;->setText(Ljava/lang/String;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getBuyNitroYearly()Lcom/discord/views/BoxedButton;
|
|
|
|
move-result-object v2
|
|
|
|
new-instance v4, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$3;
|
|
|
|
invoke-direct {v4, v0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$3;-><init>(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;)V
|
|
|
|
invoke-virtual {v2, v4}, Landroid/widget/FrameLayout;->setOnClickListener(Landroid/view/View$OnClickListener;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getBuyNitroMonthly()Landroid/widget/Button;
|
|
|
|
move-result-object v2
|
|
|
|
new-array v4, v5, [Ljava/lang/Object;
|
|
|
|
sget-object v7, Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;->PREMIUM_MONTH_TIER_2:Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;
|
|
|
|
invoke-virtual {v7}, Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;->getPrice()I
|
|
|
|
move-result v7
|
|
|
|
invoke-virtual/range {p0 .. p0}, Landroidx/fragment/app/Fragment;->requireContext()Landroid/content/Context;
|
|
|
|
move-result-object v9
|
|
|
|
invoke-static {v9, v8}, Lw/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-static {v7, v9}, Lcom/discord/utilities/billing/PremiumUtilsKt;->getFormattedPrice(ILandroid/content/Context;)Ljava/lang/CharSequence;
|
|
|
|
move-result-object v7
|
|
|
|
aput-object v7, v4, v3
|
|
|
|
const v7, 0x7f1202bc
|
|
|
|
invoke-virtual {v0, v7, v4}, Landroidx/fragment/app/Fragment;->getString(I[Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-virtual {v2, v4}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getBuyNitroMonthly()Landroid/widget/Button;
|
|
|
|
move-result-object v2
|
|
|
|
new-instance v4, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$4;
|
|
|
|
invoke-direct {v4, v0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$4;-><init>(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;)V
|
|
|
|
invoke-virtual {v2, v4}, Landroid/widget/Button;->setOnClickListener(Landroid/view/View$OnClickListener;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getBuyNitroClassicYearly()Lcom/discord/views/BoxedButton;
|
|
|
|
move-result-object v2
|
|
|
|
new-array v4, v5, [Ljava/lang/Object;
|
|
|
|
sget-object v9, Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;->PREMIUM_YEAR_TIER_1:Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;
|
|
|
|
invoke-virtual {v9}, Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;->getPrice()I
|
|
|
|
move-result v9
|
|
|
|
invoke-virtual/range {p0 .. p0}, Landroidx/fragment/app/Fragment;->requireContext()Landroid/content/Context;
|
|
|
|
move-result-object v10
|
|
|
|
invoke-static {v10, v8}, Lw/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-static {v9, v10}, Lcom/discord/utilities/billing/PremiumUtilsKt;->getFormattedPrice(ILandroid/content/Context;)Ljava/lang/CharSequence;
|
|
|
|
move-result-object v9
|
|
|
|
aput-object v9, v4, v3
|
|
|
|
invoke-virtual {v0, v6, v4}, Landroidx/fragment/app/Fragment;->getString(I[Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-virtual {v2, v4}, Lcom/discord/views/BoxedButton;->setText(Ljava/lang/String;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getBuyNitroClassicYearly()Lcom/discord/views/BoxedButton;
|
|
|
|
move-result-object v2
|
|
|
|
new-instance v4, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$5;
|
|
|
|
invoke-direct {v4, v0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$5;-><init>(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;)V
|
|
|
|
invoke-virtual {v2, v4}, Landroid/widget/FrameLayout;->setOnClickListener(Landroid/view/View$OnClickListener;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getBuyNitroClassicMonthly()Landroid/widget/Button;
|
|
|
|
move-result-object v2
|
|
|
|
new-array v4, v5, [Ljava/lang/Object;
|
|
|
|
sget-object v5, Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;->PREMIUM_MONTH_TIER_1:Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;
|
|
|
|
invoke-virtual {v5}, Lcom/discord/models/domain/ModelSubscriptionPlan$SubscriptionPlanType;->getPrice()I
|
|
|
|
move-result v5
|
|
|
|
invoke-virtual/range {p0 .. p0}, Landroidx/fragment/app/Fragment;->requireContext()Landroid/content/Context;
|
|
|
|
move-result-object v6
|
|
|
|
invoke-static {v6, v8}, Lw/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-static {v5, v6}, Lcom/discord/utilities/billing/PremiumUtilsKt;->getFormattedPrice(ILandroid/content/Context;)Ljava/lang/CharSequence;
|
|
|
|
move-result-object v5
|
|
|
|
aput-object v5, v4, v3
|
|
|
|
invoke-virtual {v0, v7, v4}, Landroidx/fragment/app/Fragment;->getString(I[Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-virtual {v2, v4}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getBuyNitroClassicMonthly()Landroid/widget/Button;
|
|
|
|
move-result-object v2
|
|
|
|
new-instance v4, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$6;
|
|
|
|
invoke-direct {v4, v0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$6;-><init>(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;)V
|
|
|
|
invoke-virtual {v2, v4}, Landroid/widget/Button;->setOnClickListener(Landroid/view/View$OnClickListener;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getNitroLearnMore()Landroid/widget/TextView;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual/range {p0 .. p0}, Landroidx/fragment/app/Fragment;->requireContext()Landroid/content/Context;
|
|
|
|
move-result-object v9
|
|
|
|
invoke-static {v9, v8}, Lw/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const v4, 0x7f120fb2
|
|
|
|
invoke-virtual {v0, v4}, Landroidx/fragment/app/Fragment;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object v4
|
|
|
|
const-string v5, "getString(R.string.premi\u2026ayment_gift_blurb_mobile)"
|
|
|
|
invoke-static {v4, v5}, Lw/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const/4 v6, 0x4
|
|
|
|
const-string v7, "https://discordapp.com"
|
|
|
|
const-string v15, "onClick"
|
|
|
|
invoke-static {v4, v15, v7, v3, v6}, Lw/a0/p;->replace$default(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;ZI)Ljava/lang/String;
|
|
|
|
move-result-object v10
|
|
|
|
sget-object v11, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$7;->INSTANCE:Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$7;
|
|
|
|
const/4 v12, 0x0
|
|
|
|
const/4 v13, 0x0
|
|
|
|
const/16 v14, 0x10
|
|
|
|
const/4 v4, 0x0
|
|
|
|
move-object v1, v15
|
|
|
|
move-object v15, v4
|
|
|
|
invoke-static/range {v9 .. v15}, Lcom/discord/utilities/textprocessing/Parsers;->parseMaskedLinks$default(Landroid/content/Context;Ljava/lang/CharSequence;Lkotlin/jvm/functions/Function2;Lkotlin/jvm/functions/Function1;Ljava/lang/Integer;ILjava/lang/Object;)Ljava/lang/CharSequence;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-virtual {v2, v4}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getNitroClassicLearnMore()Landroid/widget/TextView;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual/range {p0 .. p0}, Landroidx/fragment/app/Fragment;->requireContext()Landroid/content/Context;
|
|
|
|
move-result-object v9
|
|
|
|
invoke-static {v9, v8}, Lw/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const v4, 0x7f120ef2
|
|
|
|
invoke-virtual {v0, v4}, Landroidx/fragment/app/Fragment;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-static {v4, v5}, Lw/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-static {v4, v1, v7, v3, v6}, Lw/a0/p;->replace$default(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;ZI)Ljava/lang/String;
|
|
|
|
move-result-object v10
|
|
|
|
sget-object v11, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$8;->INSTANCE:Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBound$8;
|
|
|
|
const/4 v15, 0x0
|
|
|
|
invoke-static/range {v9 .. v15}, Lcom/discord/utilities/textprocessing/Parsers;->parseMaskedLinks$default(Landroid/content/Context;Ljava/lang/CharSequence;Lkotlin/jvm/functions/Function2;Lkotlin/jvm/functions/Function1;Ljava/lang/Integer;ILjava/lang/Object;)Ljava/lang/CharSequence;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v2, v1}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
sget-object v1, Lcom/discord/utilities/mg_recycler/MGRecyclerAdapter;->Companion:Lcom/discord/utilities/mg_recycler/MGRecyclerAdapter$Companion;
|
|
|
|
new-instance v2, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter;
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getRecyclerView()Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-direct {v2, v4}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter;-><init>(Landroidx/recyclerview/widget/RecyclerView;)V
|
|
|
|
invoke-virtual {v1, v2}, Lcom/discord/utilities/mg_recycler/MGRecyclerAdapter$Companion;->configure(Lcom/discord/utilities/mg_recycler/MGRecyclerAdapter;)Lcom/discord/utilities/mg_recycler/MGRecyclerAdapter;
|
|
|
|
move-result-object v1
|
|
|
|
check-cast v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter;
|
|
|
|
iput-object v1, v0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->adapter:Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingAdapter;
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getRecyclerView()Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
move-result-object v1
|
|
|
|
const/4 v2, 0x0
|
|
|
|
invoke-virtual {v1, v2}, Landroidx/recyclerview/widget/RecyclerView;->setItemAnimator(Landroidx/recyclerview/widget/RecyclerView$ItemAnimator;)V
|
|
|
|
invoke-direct/range {p0 .. p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->getRecyclerView()Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v1, v3}, Landroidx/recyclerview/widget/RecyclerView;->setHasFixedSize(Z)V
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
move-object v2, v1
|
|
|
|
const-string v1, "view"
|
|
|
|
invoke-static {v1}, Lw/u/b/j;->a(Ljava/lang/String;)V
|
|
|
|
throw v2
|
|
.end method
|
|
|
|
.method public onViewBoundOrOnResume()V
|
|
.locals 13
|
|
|
|
invoke-super {p0}, Lcom/discord/app/AppFragment;->onViewBoundOrOnResume()V
|
|
|
|
invoke-virtual {p0}, Landroidx/fragment/app/Fragment;->requireActivity()Landroidx/fragment/app/FragmentActivity;
|
|
|
|
move-result-object v0
|
|
|
|
new-instance v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$Factory;
|
|
|
|
invoke-direct {v1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel$Factory;-><init>()V
|
|
|
|
invoke-static {v0, v1}, Landroidx/lifecycle/ViewModelProviders;->of(Landroidx/fragment/app/FragmentActivity;Landroidx/lifecycle/ViewModelProvider$Factory;)Landroidx/lifecycle/ViewModelProvider;
|
|
|
|
move-result-object v0
|
|
|
|
const-class v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel;
|
|
|
|
invoke-virtual {v0, v1}, Landroidx/lifecycle/ViewModelProvider;->get(Ljava/lang/Class;)Landroidx/lifecycle/ViewModel;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "ViewModelProviders\n \u2026ingViewModel::class.java)"
|
|
|
|
invoke-static {v0, v1}, Lw/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
check-cast v0, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel;
|
|
|
|
iput-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->viewModel:Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel;
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->viewModel:Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
const-string v2, "viewModel"
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
invoke-virtual {v0}, Le/a/b/c0;->observeViewState()Lrx/Observable;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0}, Lrx/Observable;->a()Lrx/Observable;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v3, "viewModel\n .obser\u2026 .distinctUntilChanged()"
|
|
|
|
invoke-static {v0, v3}, Lw/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-static {v0, p0}, Lcom/discord/utilities/rx/ObservableExtensionsKt;->bindToComponentLifecycle(Lrx/Observable;Lcom/discord/app/AppComponent;)Lrx/Observable;
|
|
|
|
move-result-object v4
|
|
|
|
const-class v5, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;
|
|
|
|
const/4 v6, 0x0
|
|
|
|
const/4 v7, 0x0
|
|
|
|
const/4 v8, 0x0
|
|
|
|
const/4 v9, 0x0
|
|
|
|
new-instance v10, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBoundOrOnResume$1;
|
|
|
|
invoke-direct {v10, p0}, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBoundOrOnResume$1;-><init>(Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;)V
|
|
|
|
const/16 v11, 0x1e
|
|
|
|
const/4 v12, 0x0
|
|
|
|
invoke-static/range {v4 .. v12}, 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
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting;->viewModel:Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel;
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBoundOrOnResume$2;->INSTANCE:Lcom/discord/widgets/settings/premium/WidgetSettingsGifting$onViewBoundOrOnResume$2;
|
|
|
|
invoke-virtual {v0, v1}, Lcom/discord/widgets/settings/premium/WidgetSettingsGiftingViewModel;->setOnGiftCodeResolved(Lkotlin/jvm/functions/Function1;)V
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
invoke-static {v2}, Lw/u/b/j;->throwUninitializedPropertyAccessException(Ljava/lang/String;)V
|
|
|
|
throw v1
|
|
|
|
:cond_1
|
|
invoke-static {v2}, Lw/u/b/j;->throwUninitializedPropertyAccessException(Ljava/lang/String;)V
|
|
|
|
throw v1
|
|
.end method
|