274 lines
8.8 KiB
Smali
274 lines
8.8 KiB
Smali
.class public final Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;
|
|
.super Lcom/discord/utilities/mg_recycler/MGRecyclerViewHolder;
|
|
.source "WidgetSettingsLanguageSelect.kt"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/EnclosingClass;
|
|
value = Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter;
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/InnerClass;
|
|
accessFlags = 0x19
|
|
name = "AdapterItemLocale"
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"Lcom/discord/utilities/mg_recycler/MGRecyclerViewHolder<",
|
|
"Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter;",
|
|
"Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Model$Item;",
|
|
">;"
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field public static final synthetic $$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
|
|
# instance fields
|
|
.field public final name$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final nameLocalized$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
|
|
# direct methods
|
|
.method public static constructor <clinit>()V
|
|
.locals 6
|
|
|
|
const-class v0, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;
|
|
|
|
const/4 v1, 0x2
|
|
|
|
new-array v1, v1, [Lkotlin/reflect/KProperty;
|
|
|
|
new-instance v2, Ly/u/b/u;
|
|
|
|
invoke-static {v0}, Ly/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Ly/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "name"
|
|
|
|
const-string v5, "getName()Landroid/widget/TextView;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Ly/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Ly/u/b/w;->a:Ly/u/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Ly/u/b/x;->property1(Ly/u/b/t;)Ly/y/d;
|
|
|
|
const/4 v3, 0x0
|
|
|
|
aput-object v2, v1, v3
|
|
|
|
const/4 v2, 0x1
|
|
|
|
new-instance v3, Ly/u/b/u;
|
|
|
|
invoke-static {v0}, Ly/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Ly/y/b;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v4, "nameLocalized"
|
|
|
|
const-string v5, "getNameLocalized()Landroid/widget/TextView;"
|
|
|
|
invoke-direct {v3, v0, v4, v5}, Ly/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v0, Ly/u/b/w;->a:Ly/u/b/x;
|
|
|
|
invoke-virtual {v0, v3}, Ly/u/b/x;->property1(Ly/u/b/t;)Ly/y/d;
|
|
|
|
aput-object v3, v1, v2
|
|
|
|
sput-object v1, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(ILcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter;)V
|
|
.locals 0
|
|
.param p1 # I
|
|
.annotation build Landroidx/annotation/LayoutRes;
|
|
.end annotation
|
|
.end param
|
|
|
|
if-eqz p2, :cond_0
|
|
|
|
invoke-direct {p0, p1, p2}, Lcom/discord/utilities/mg_recycler/MGRecyclerViewHolder;-><init>(ILcom/discord/utilities/mg_recycler/MGRecyclerAdapter;)V
|
|
|
|
const p1, 0x7f0a0827
|
|
|
|
invoke-static {p0, p1}, Lz/a/a2/w;->a(Landroidx/recyclerview/widget/RecyclerView$ViewHolder;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;->name$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const p1, 0x7f0a0828
|
|
|
|
invoke-static {p0, p1}, Lz/a/a2/w;->a(Landroidx/recyclerview/widget/RecyclerView$ViewHolder;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;->nameLocalized$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
new-instance p1, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale$1;
|
|
|
|
invoke-direct {p1, p2}, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale$1;-><init>(Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter;)V
|
|
|
|
const/4 p2, 0x0
|
|
|
|
new-array p2, p2, [Landroid/view/View;
|
|
|
|
invoke-virtual {p0, p1, p2}, Lcom/discord/utilities/mg_recycler/MGRecyclerViewHolder;->setOnClickListener(Lrx/functions/Action3;[Landroid/view/View;)V
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
const-string p1, "adapter"
|
|
|
|
invoke-static {p1}, Ly/u/b/j;->a(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method private final getName()Landroid/widget/TextView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;->name$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/4 v2, 0x0
|
|
|
|
aget-object v1, v1, v2
|
|
|
|
invoke-interface {v0, p0, v1}, Lkotlin/properties/ReadOnlyProperty;->getValue(Ljava/lang/Object;Lkotlin/reflect/KProperty;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Landroid/widget/TextView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getNameLocalized()Landroid/widget/TextView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;->nameLocalized$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/4 v2, 0x1
|
|
|
|
aget-object v1, v1, v2
|
|
|
|
invoke-interface {v0, p0, v1}, Lkotlin/properties/ReadOnlyProperty;->getValue(Ljava/lang/Object;Lkotlin/reflect/KProperty;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Landroid/widget/TextView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public onConfigure(ILcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Model$Item;)V
|
|
.locals 8
|
|
|
|
if-eqz p2, :cond_0
|
|
|
|
invoke-super {p0, p1, p2}, Lcom/discord/utilities/mg_recycler/MGRecyclerViewHolder;->onConfigure(ILjava/lang/Object;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;->getName()Landroid/widget/TextView;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;->getName()Landroid/widget/TextView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0}, Landroid/widget/TextView;->getContext()Landroid/content/Context;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {p2}, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Model$Item;->getLocale()Ljava/lang/String;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-static {v1}, Lcom/discord/widgets/settings/WidgetSettingsLanguage;->getLocaleResId(Ljava/lang/String;)I
|
|
|
|
move-result v1
|
|
|
|
invoke-virtual {v0, v1}, Landroid/content/Context;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {p1, v0}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;->getNameLocalized()Landroid/widget/TextView;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {p2}, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Model$Item;->getLocale()Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-static {v0}, Lcom/discord/widgets/settings/WidgetSettingsLanguage;->getAsStringInLocale(Ljava/lang/String;)Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {p1, v0}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;->getNameLocalized()Landroid/widget/TextView;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {p2}, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Model$Item;->getLocale()Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-static {p1}, Lcom/discord/widgets/settings/WidgetSettingsLanguage;->getLocaleFlagResId(Ljava/lang/String;)I
|
|
|
|
move-result v2
|
|
|
|
const/4 v3, 0x0
|
|
|
|
const/4 v4, 0x0
|
|
|
|
const/4 v5, 0x0
|
|
|
|
const/16 v6, 0xe
|
|
|
|
const/4 v7, 0x0
|
|
|
|
invoke-static/range {v1 .. v7}, Lcom/discord/utilities/drawable/DrawableCompat;->setCompoundDrawablesCompat$default(Landroid/widget/TextView;IIIIILjava/lang/Object;)V
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
const-string p1, "data"
|
|
|
|
invoke-static {p1}, Ly/u/b/j;->a(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public bridge synthetic onConfigure(ILjava/lang/Object;)V
|
|
.locals 0
|
|
|
|
check-cast p2, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Model$Item;
|
|
|
|
invoke-virtual {p0, p1, p2}, Lcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Adapter$AdapterItemLocale;->onConfigure(ILcom/discord/widgets/settings/WidgetSettingsLanguageSelect$Model$Item;)V
|
|
|
|
return-void
|
|
.end method
|