471 lines
15 KiB
Smali
471 lines
15 KiB
Smali
.class public final Lcom/discord/widgets/guilds/join/ChannelViewHolder;
|
|
.super Lcom/discord/widgets/guilds/join/BaseChannelViewHolder;
|
|
.source "WidgetGuildWelcomeSheetChannelAdapter.kt"
|
|
|
|
|
|
# static fields
|
|
.field public static final synthetic $$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
|
|
# instance fields
|
|
.field public final descriptionView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final emojiImageView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final nameView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final unicodeEmojiView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final welcomeChannel$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
|
|
# direct methods
|
|
.method public static constructor <clinit>()V
|
|
.locals 6
|
|
|
|
const-class v0, Lcom/discord/widgets/guilds/join/ChannelViewHolder;
|
|
|
|
const/4 v1, 0x5
|
|
|
|
new-array v1, v1, [Lkotlin/reflect/KProperty;
|
|
|
|
new-instance v2, Lj0/n/c/q;
|
|
|
|
invoke-static {v0}, Lj0/n/c/s;->getOrCreateKotlinClass(Ljava/lang/Class;)Lj0/r/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "welcomeChannel"
|
|
|
|
const-string v5, "getWelcomeChannel()Landroidx/cardview/widget/CardView;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lj0/n/c/q;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-static {v2}, Lj0/n/c/s;->property1(Lj0/n/c/p;)Lj0/r/d;
|
|
|
|
const/4 v3, 0x0
|
|
|
|
aput-object v2, v1, v3
|
|
|
|
new-instance v2, Lj0/n/c/q;
|
|
|
|
invoke-static {v0}, Lj0/n/c/s;->getOrCreateKotlinClass(Ljava/lang/Class;)Lj0/r/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "emojiImageView"
|
|
|
|
const-string v5, "getEmojiImageView()Lcom/facebook/drawee/view/SimpleDraweeView;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lj0/n/c/q;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-static {v2}, Lj0/n/c/s;->property1(Lj0/n/c/p;)Lj0/r/d;
|
|
|
|
const/4 v3, 0x1
|
|
|
|
aput-object v2, v1, v3
|
|
|
|
new-instance v2, Lj0/n/c/q;
|
|
|
|
invoke-static {v0}, Lj0/n/c/s;->getOrCreateKotlinClass(Ljava/lang/Class;)Lj0/r/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "descriptionView"
|
|
|
|
const-string v5, "getDescriptionView()Landroid/widget/TextView;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lj0/n/c/q;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-static {v2}, Lj0/n/c/s;->property1(Lj0/n/c/p;)Lj0/r/d;
|
|
|
|
const/4 v3, 0x2
|
|
|
|
aput-object v2, v1, v3
|
|
|
|
new-instance v2, Lj0/n/c/q;
|
|
|
|
invoke-static {v0}, Lj0/n/c/s;->getOrCreateKotlinClass(Ljava/lang/Class;)Lj0/r/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "nameView"
|
|
|
|
const-string v5, "getNameView()Landroid/widget/TextView;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Lj0/n/c/q;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-static {v2}, Lj0/n/c/s;->property1(Lj0/n/c/p;)Lj0/r/d;
|
|
|
|
const/4 v3, 0x3
|
|
|
|
aput-object v2, v1, v3
|
|
|
|
new-instance v2, Lj0/n/c/q;
|
|
|
|
invoke-static {v0}, Lj0/n/c/s;->getOrCreateKotlinClass(Ljava/lang/Class;)Lj0/r/b;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v3, "unicodeEmojiView"
|
|
|
|
const-string v4, "getUnicodeEmojiView()Landroid/widget/TextView;"
|
|
|
|
invoke-direct {v2, v0, v3, v4}, Lj0/n/c/q;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-static {v2}, Lj0/n/c/s;->property1(Lj0/n/c/p;)Lj0/r/d;
|
|
|
|
const/4 v0, 0x4
|
|
|
|
aput-object v2, v1, v0
|
|
|
|
sput-object v1, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Landroid/view/View;)V
|
|
.locals 0
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
invoke-direct {p0, p1}, Lcom/discord/widgets/guilds/join/BaseChannelViewHolder;-><init>(Landroid/view/View;)V
|
|
|
|
const p1, 0x7f0a0470
|
|
|
|
invoke-static {p0, p1}, Lj0/i/t;->k(Landroidx/recyclerview/widget/RecyclerView$ViewHolder;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->welcomeChannel$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const p1, 0x7f0a0473
|
|
|
|
invoke-static {p0, p1}, Lj0/i/t;->k(Landroidx/recyclerview/widget/RecyclerView$ViewHolder;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->emojiImageView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const p1, 0x7f0a0471
|
|
|
|
invoke-static {p0, p1}, Lj0/i/t;->k(Landroidx/recyclerview/widget/RecyclerView$ViewHolder;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->descriptionView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const p1, 0x7f0a0476
|
|
|
|
invoke-static {p0, p1}, Lj0/i/t;->k(Landroidx/recyclerview/widget/RecyclerView$ViewHolder;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->nameView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const p1, 0x7f0a0478
|
|
|
|
invoke-static {p0, p1}, Lj0/i/t;->k(Landroidx/recyclerview/widget/RecyclerView$ViewHolder;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->unicodeEmojiView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
const-string p1, "itemView"
|
|
|
|
invoke-static {p1}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method private final getDescriptionView()Landroid/widget/TextView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->descriptionView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/4 v2, 0x2
|
|
|
|
aget-object v1, v1, v2
|
|
|
|
invoke-interface {v0, p0, v1}, Lkotlin/properties/ReadOnlyProperty;->getValue(Ljava/lang/Object;Lkotlin/reflect/KProperty;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Landroid/widget/TextView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getEmojiImageView()Lcom/facebook/drawee/view/SimpleDraweeView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->emojiImageView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->$$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/facebook/drawee/view/SimpleDraweeView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getNameView()Landroid/widget/TextView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->nameView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->$$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, Landroid/widget/TextView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getUnicodeEmojiView()Landroid/widget/TextView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->unicodeEmojiView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->$$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, Landroid/widget/TextView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getWelcomeChannel()Landroidx/cardview/widget/CardView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->welcomeChannel$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
const/4 v2, 0x0
|
|
|
|
aget-object v1, v1, v2
|
|
|
|
invoke-interface {v0, p0, v1}, Lkotlin/properties/ReadOnlyProperty;->getValue(Ljava/lang/Object;Lkotlin/reflect/KProperty;)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Landroidx/cardview/widget/CardView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public bind(Lcom/discord/widgets/guilds/join/ChannelItem;)V
|
|
.locals 14
|
|
|
|
const/4 v0, 0x0
|
|
|
|
if-eqz p1, :cond_3
|
|
|
|
invoke-super {p0, p1}, Lcom/discord/widgets/guilds/join/BaseChannelViewHolder;->bind(Lcom/discord/widgets/guilds/join/ChannelItem;)V
|
|
|
|
move-object v1, p1
|
|
|
|
check-cast v1, Lcom/discord/widgets/guilds/join/ChannelItem$ChannelData;
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->getEmojiImageView()Lcom/facebook/drawee/view/SimpleDraweeView;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual {v2}, Landroid/widget/ImageView;->getLayoutParams()Landroid/view/ViewGroup$LayoutParams;
|
|
|
|
move-result-object v2
|
|
|
|
iget v2, v2, Landroid/view/ViewGroup$LayoutParams;->width:I
|
|
|
|
invoke-static {v2}, Lcom/discord/utilities/icon/IconUtils;->getMediaProxySize(I)I
|
|
|
|
move-result v2
|
|
|
|
invoke-virtual {v1}, Lcom/discord/widgets/guilds/join/ChannelItem$ChannelData;->getWelcomeChannel()Lcom/discord/models/domain/ModelGuildWelcomeChannel;
|
|
|
|
move-result-object v3
|
|
|
|
invoke-virtual {v3, v2}, Lcom/discord/models/domain/ModelGuildWelcomeChannel;->getEmojiUri(I)Ljava/lang/String;
|
|
|
|
move-result-object v5
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->getDescriptionView()Landroid/widget/TextView;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual {v1}, Lcom/discord/widgets/guilds/join/ChannelItem$ChannelData;->getWelcomeChannel()Lcom/discord/models/domain/ModelGuildWelcomeChannel;
|
|
|
|
move-result-object v3
|
|
|
|
invoke-virtual {v3}, Lcom/discord/models/domain/ModelGuildWelcomeChannel;->getDescription()Ljava/lang/String;
|
|
|
|
move-result-object v3
|
|
|
|
invoke-virtual {v2, v3}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->getNameView()Landroid/widget/TextView;
|
|
|
|
move-result-object v2
|
|
|
|
sget-object v3, Lcom/discord/stores/StoreStream;->Companion:Lcom/discord/stores/StoreStream$Companion;
|
|
|
|
invoke-virtual {v3}, Lcom/discord/stores/StoreStream$Companion;->getChannels()Lcom/discord/stores/StoreChannels;
|
|
|
|
move-result-object v3
|
|
|
|
invoke-virtual {v1}, Lcom/discord/widgets/guilds/join/ChannelItem$ChannelData;->getWelcomeChannel()Lcom/discord/models/domain/ModelGuildWelcomeChannel;
|
|
|
|
move-result-object v4
|
|
|
|
invoke-virtual {v4}, Lcom/discord/models/domain/ModelGuildWelcomeChannel;->getChannelId()J
|
|
|
|
move-result-wide v6
|
|
|
|
invoke-virtual {v3, v6, v7}, Lcom/discord/stores/StoreChannels;->getChannel$app_productionDiscordExternalRelease(J)Lcom/discord/models/domain/ModelChannel;
|
|
|
|
move-result-object v3
|
|
|
|
if-eqz v3, :cond_0
|
|
|
|
invoke-virtual {v3}, Lcom/discord/models/domain/ModelChannel;->getName()Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
:cond_0
|
|
invoke-static {v0}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v2, v0}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->getWelcomeChannel()Landroidx/cardview/widget/CardView;
|
|
|
|
move-result-object v0
|
|
|
|
new-instance v2, Lcom/discord/widgets/guilds/join/ChannelViewHolder$bind$1;
|
|
|
|
invoke-direct {v2, p1}, Lcom/discord/widgets/guilds/join/ChannelViewHolder$bind$1;-><init>(Lcom/discord/widgets/guilds/join/ChannelItem;)V
|
|
|
|
invoke-virtual {v0, v2}, Landroid/widget/FrameLayout;->setOnClickListener(Landroid/view/View$OnClickListener;)V
|
|
|
|
const/16 p1, 0x8
|
|
|
|
const/4 v0, 0x0
|
|
|
|
if-eqz v5, :cond_1
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->getEmojiImageView()Lcom/facebook/drawee/view/SimpleDraweeView;
|
|
|
|
move-result-object v4
|
|
|
|
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, 0xfc
|
|
|
|
const/4 v13, 0x0
|
|
|
|
invoke-static/range {v4 .. v13}, Lcom/discord/utilities/images/MGImages;->setImage$default(Landroid/widget/ImageView;Ljava/lang/String;IIZLkotlin/jvm/functions/Function1;Lcom/discord/utilities/images/MGImages$ChangeDetector;Ljava/util/List;ILjava/lang/Object;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->getEmojiImageView()Lcom/facebook/drawee/view/SimpleDraweeView;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v1, v0}, Landroid/view/View;->setVisibility(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->getUnicodeEmojiView()Landroid/widget/TextView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0, p1}, Landroid/view/View;->setVisibility(I)V
|
|
|
|
goto :goto_0
|
|
|
|
:cond_1
|
|
invoke-virtual {v1}, Lcom/discord/widgets/guilds/join/ChannelItem$ChannelData;->getWelcomeChannel()Lcom/discord/models/domain/ModelGuildWelcomeChannel;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual {v2}, Lcom/discord/models/domain/ModelGuildWelcomeChannel;->getEmojiName()Ljava/lang/String;
|
|
|
|
move-result-object v2
|
|
|
|
if-eqz v2, :cond_2
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->getEmojiImageView()Lcom/facebook/drawee/view/SimpleDraweeView;
|
|
|
|
move-result-object v2
|
|
|
|
invoke-virtual {v2, p1}, Landroid/view/View;->setVisibility(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->getUnicodeEmojiView()Landroid/widget/TextView;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {p1, v0}, Landroid/view/View;->setVisibility(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/guilds/join/ChannelViewHolder;->getUnicodeEmojiView()Landroid/widget/TextView;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {v1}, Lcom/discord/widgets/guilds/join/ChannelItem$ChannelData;->getWelcomeChannel()Lcom/discord/models/domain/ModelGuildWelcomeChannel;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0}, Lcom/discord/models/domain/ModelGuildWelcomeChannel;->getEmojiName()Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {p1, v0}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
:cond_2
|
|
:goto_0
|
|
return-void
|
|
|
|
:cond_3
|
|
const-string p1, "data"
|
|
|
|
invoke-static {p1}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
throw v0
|
|
.end method
|