213 lines
6.6 KiB
Smali
213 lines
6.6 KiB
Smali
.class public final Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView;
|
|
.super Landroid/widget/LinearLayout;
|
|
.source "GuildTemplateChannelsView.kt"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/MemberClasses;
|
|
value = {
|
|
Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView$ChannelDataPayload;,
|
|
Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView$ChannelsAdapter;,
|
|
Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView$ChannelViewHolder;
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field public static final synthetic $$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
|
|
# instance fields
|
|
.field public final channelsAdapter:Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView$ChannelsAdapter;
|
|
|
|
.field public final channelsRecycler$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
|
|
# direct methods
|
|
.method public static constructor <clinit>()V
|
|
.locals 5
|
|
|
|
const/4 v0, 0x1
|
|
|
|
new-array v0, v0, [Lkotlin/reflect/KProperty;
|
|
|
|
new-instance v1, Lw/u/b/u;
|
|
|
|
const-class v2, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView;
|
|
|
|
invoke-static {v2}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v2
|
|
|
|
const-string v3, "channelsRecycler"
|
|
|
|
const-string v4, "getChannelsRecycler()Landroidx/recyclerview/widget/RecyclerView;"
|
|
|
|
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
|
|
|
|
sput-object v0, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;)V
|
|
.locals 1
|
|
|
|
const/4 v0, 0x0
|
|
|
|
if-eqz p1, :cond_1
|
|
|
|
if-eqz p2, :cond_0
|
|
|
|
invoke-direct {p0, p1, p2}, Landroid/widget/LinearLayout;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;)V
|
|
|
|
const p2, 0x7f0a03d9
|
|
|
|
invoke-static {p0, p2}, Lx/a/a2/w;->a(Landroid/view/View;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p2
|
|
|
|
iput-object p2, p0, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView;->channelsRecycler$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const p2, 0x7f0d0044
|
|
|
|
invoke-static {p1, p2, p0}, Landroid/widget/LinearLayout;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
|
|
|
|
sget-object p1, Lcom/discord/utilities/mg_recycler/MGRecyclerAdapter;->Companion:Lcom/discord/utilities/mg_recycler/MGRecyclerAdapter$Companion;
|
|
|
|
new-instance p2, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView$ChannelsAdapter;
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView;->getChannelsRecycler()Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-direct {p2, v0}, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView$ChannelsAdapter;-><init>(Landroidx/recyclerview/widget/RecyclerView;)V
|
|
|
|
invoke-virtual {p1, p2}, Lcom/discord/utilities/mg_recycler/MGRecyclerAdapter$Companion;->configure(Lcom/discord/utilities/mg_recycler/MGRecyclerAdapter;)Lcom/discord/utilities/mg_recycler/MGRecyclerAdapter;
|
|
|
|
move-result-object p1
|
|
|
|
check-cast p1, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView$ChannelsAdapter;
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView;->channelsAdapter:Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView$ChannelsAdapter;
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView;->getChannelsRecycler()Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
move-result-object p1
|
|
|
|
const/4 p2, 0x0
|
|
|
|
invoke-virtual {p1, p2}, Landroidx/recyclerview/widget/RecyclerView;->setHasFixedSize(Z)V
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
const-string p1, "attrs"
|
|
|
|
invoke-static {p1}, Lw/u/b/j;->a(Ljava/lang/String;)V
|
|
|
|
throw v0
|
|
|
|
:cond_1
|
|
const-string p1, "context"
|
|
|
|
invoke-static {p1}, Lw/u/b/j;->a(Ljava/lang/String;)V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method private final getChannelsRecycler()Landroidx/recyclerview/widget/RecyclerView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView;->channelsRecycler$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView;->$$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/recyclerview/widget/RecyclerView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public final updateView(Ljava/util/List;)V
|
|
.locals 4
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/List<",
|
|
"+",
|
|
"Lcom/discord/models/domain/ModelChannel;",
|
|
">;)V"
|
|
}
|
|
.end annotation
|
|
|
|
if-eqz p1, :cond_1
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView;->channelsAdapter:Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView$ChannelsAdapter;
|
|
|
|
new-instance v1, Ljava/util/ArrayList;
|
|
|
|
const/16 v2, 0xa
|
|
|
|
invoke-static {p1, v2}, Le/k/a/c/e/p/g;->collectionSizeOrDefault(Ljava/lang/Iterable;I)I
|
|
|
|
move-result v2
|
|
|
|
invoke-direct {v1, v2}, Ljava/util/ArrayList;-><init>(I)V
|
|
|
|
invoke-interface {p1}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object p1
|
|
|
|
:goto_0
|
|
invoke-interface {p1}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v2
|
|
|
|
if-eqz v2, :cond_0
|
|
|
|
invoke-interface {p1}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
check-cast v2, Lcom/discord/models/domain/ModelChannel;
|
|
|
|
new-instance v3, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView$ChannelDataPayload;
|
|
|
|
invoke-direct {v3, v2}, Lcom/discord/widgets/guilds/create/GuildTemplateChannelsView$ChannelDataPayload;-><init>(Lcom/discord/models/domain/ModelChannel;)V
|
|
|
|
invoke-interface {v1, v3}, Ljava/util/Collection;->add(Ljava/lang/Object;)Z
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
invoke-virtual {v0, v1}, Lcom/discord/utilities/mg_recycler/MGRecyclerAdapterSimple;->setData(Ljava/util/List;)V
|
|
|
|
return-void
|
|
|
|
:cond_1
|
|
const-string p1, "channels"
|
|
|
|
invoke-static {p1}, Lw/u/b/j;->a(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
.end method
|