414 lines
16 KiB
Smali
414 lines
16 KiB
Smali
.class public final Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;
|
|
.super Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$Item;
|
|
.source "WidgetChannelsListAdapter.kt"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/EnclosingClass;
|
|
value = Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter;
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/InnerClass;
|
|
accessFlags = 0x19
|
|
name = "ItemChannelCategory"
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/MemberClasses;
|
|
value = {
|
|
Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field public static final synthetic $$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
.field public static final ANIMATION_DURATION:J = 0x12cL
|
|
|
|
.field public static final ARROW_ANIM_COLLAPSE:Landroid/view/animation/RotateAnimation;
|
|
|
|
.field public static final ARROW_ANIM_EXPAND:Landroid/view/animation/RotateAnimation;
|
|
|
|
.field public static final Companion:Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;
|
|
|
|
|
|
# instance fields
|
|
.field public final addChannel$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final arrow$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public isCollapsed:Z
|
|
|
|
.field public final nameTextView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
|
|
# direct methods
|
|
.method public static constructor <clinit>()V
|
|
.locals 8
|
|
|
|
const-class v0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;
|
|
|
|
const/4 v1, 0x3
|
|
|
|
new-array v1, v1, [Lkotlin/reflect/KProperty;
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
invoke-static {v0}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "nameTextView"
|
|
|
|
const-string v5, "getNameTextView()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;
|
|
|
|
const/4 v3, 0x0
|
|
|
|
aput-object v2, v1, v3
|
|
|
|
new-instance v2, Lw/u/b/u;
|
|
|
|
invoke-static {v0}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v4
|
|
|
|
const-string v5, "arrow"
|
|
|
|
const-string v6, "getArrow()Landroid/widget/ImageView;"
|
|
|
|
invoke-direct {v2, v4, v5, v6}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v4, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v4, v2}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
const/4 v4, 0x1
|
|
|
|
aput-object v2, v1, v4
|
|
|
|
const/4 v2, 0x2
|
|
|
|
new-instance v5, Lw/u/b/u;
|
|
|
|
invoke-static {v0}, Lw/u/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Lw/y/b;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v6, "addChannel"
|
|
|
|
const-string v7, "getAddChannel()Landroid/widget/ImageView;"
|
|
|
|
invoke-direct {v5, v0, v6, v7}, Lw/u/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v0, Lw/u/b/w;->a:Lw/u/b/x;
|
|
|
|
invoke-virtual {v0, v5}, Lw/u/b/x;->property1(Lw/u/b/t;)Lw/y/d;
|
|
|
|
aput-object v5, v1, v2
|
|
|
|
sput-object v1, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
new-instance v0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
invoke-direct {v0, v1}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;-><init>(Lkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
|
|
sput-object v0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->Companion:Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;
|
|
|
|
sget-object v0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->Companion:Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;
|
|
|
|
invoke-static {v0, v4}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;->access$getAnimation(Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;Z)Landroid/view/animation/RotateAnimation;
|
|
|
|
move-result-object v0
|
|
|
|
sput-object v0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->ARROW_ANIM_EXPAND:Landroid/view/animation/RotateAnimation;
|
|
|
|
sget-object v0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->Companion:Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;
|
|
|
|
invoke-static {v0, v3}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;->access$getAnimation(Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;Z)Landroid/view/animation/RotateAnimation;
|
|
|
|
move-result-object v0
|
|
|
|
sput-object v0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->ARROW_ANIM_COLLAPSE:Landroid/view/animation/RotateAnimation;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(ILcom/discord/widgets/channels/list/WidgetChannelsListAdapter;)V
|
|
.locals 0
|
|
|
|
if-eqz p2, :cond_0
|
|
|
|
invoke-direct {p0, p1, p2}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$Item;-><init>(ILcom/discord/widgets/channels/list/WidgetChannelsListAdapter;)V
|
|
|
|
const p1, 0x7f0a0198
|
|
|
|
invoke-static {p0, p1}, Lx/a/a2/w;->a(Landroidx/recyclerview/widget/RecyclerView$ViewHolder;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->nameTextView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const p1, 0x7f0a0197
|
|
|
|
invoke-static {p0, p1}, Lx/a/a2/w;->a(Landroidx/recyclerview/widget/RecyclerView$ViewHolder;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->arrow$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const p1, 0x7f0a0196
|
|
|
|
invoke-static {p0, p1}, Lx/a/a2/w;->a(Landroidx/recyclerview/widget/RecyclerView$ViewHolder;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->addChannel$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
const-string p1, "adapter"
|
|
|
|
invoke-static {p1}, Lw/u/b/j;->a(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method private final getAddChannel()Landroid/widget/ImageView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->addChannel$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->$$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/ImageView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getArrow()Landroid/widget/ImageView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->arrow$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->$$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/ImageView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getNameTextView()Landroid/widget/TextView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->nameTextView$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->$$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
|
|
|
|
|
|
# virtual methods
|
|
.method public onConfigure(ILcom/discord/widgets/channels/list/items/ChannelListItem;)V
|
|
.locals 2
|
|
|
|
if-eqz p2, :cond_3
|
|
|
|
invoke-super {p0, p1, p2}, Lcom/discord/utilities/mg_recycler/MGRecyclerViewHolder;->onConfigure(ILjava/lang/Object;)V
|
|
|
|
check-cast p2, Lcom/discord/widgets/channels/list/items/ChannelListItemCategory;
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->getNameTextView()Landroid/widget/TextView;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {p2}, Lcom/discord/widgets/channels/list/items/ChannelListItemCategory;->getChannel()Lcom/discord/models/domain/ModelChannel;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0}, Lcom/discord/models/domain/ModelChannel;->getName()Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {p1, v0}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
sget-object p1, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->Companion:Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->getNameTextView()Landroid/widget/TextView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0}, Landroid/widget/TextView;->getContext()Landroid/content/Context;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "nameTextView.context"
|
|
|
|
invoke-static {v0, v1}, Lw/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-static {p1, p2, v0}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;->access$getChannelColor(Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;Lcom/discord/widgets/channels/list/items/ChannelListItemCategory;Landroid/content/Context;)I
|
|
|
|
move-result p1
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->getNameTextView()Landroid/widget/TextView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0, p1}, Landroid/widget/TextView;->setTextColor(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->getArrow()Landroid/widget/ImageView;
|
|
|
|
move-result-object v0
|
|
|
|
sget-object v1, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->Companion:Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;
|
|
|
|
invoke-static {v1, p2}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;->access$getArrowDrawable(Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$Companion;Lcom/discord/widgets/channels/list/items/ChannelListItemCategory;)I
|
|
|
|
move-result v1
|
|
|
|
invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setImageResource(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->getArrow()Landroid/widget/ImageView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-static {p1}, Landroid/content/res/ColorStateList;->valueOf(I)Landroid/content/res/ColorStateList;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setImageTintList(Landroid/content/res/ColorStateList;)V
|
|
|
|
iget-boolean v0, p0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->isCollapsed:Z
|
|
|
|
invoke-virtual {p2}, Lcom/discord/widgets/channels/list/items/ChannelListItemCategory;->isCollapsed()Z
|
|
|
|
move-result v1
|
|
|
|
if-eq v0, v1, :cond_1
|
|
|
|
invoke-virtual {p2}, Lcom/discord/widgets/channels/list/items/ChannelListItemCategory;->isCollapsed()Z
|
|
|
|
move-result v0
|
|
|
|
iput-boolean v0, p0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->isCollapsed:Z
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->getArrow()Landroid/widget/ImageView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {p2}, Lcom/discord/widgets/channels/list/items/ChannelListItemCategory;->isCollapsed()Z
|
|
|
|
move-result v1
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
sget-object v1, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->ARROW_ANIM_COLLAPSE:Landroid/view/animation/RotateAnimation;
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
sget-object v1, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->ARROW_ANIM_EXPAND:Landroid/view/animation/RotateAnimation;
|
|
|
|
:goto_0
|
|
invoke-virtual {v0, v1}, Landroid/widget/ImageView;->startAnimation(Landroid/view/animation/Animation;)V
|
|
|
|
:cond_1
|
|
invoke-direct {p0}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->getAddChannel()Landroid/widget/ImageView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {p2}, Lcom/discord/widgets/channels/list/items/ChannelListItemCategory;->getCanManageChannels()Z
|
|
|
|
move-result v1
|
|
|
|
if-eqz v1, :cond_2
|
|
|
|
const/4 v1, 0x0
|
|
|
|
goto :goto_1
|
|
|
|
:cond_2
|
|
const/16 v1, 0x8
|
|
|
|
:goto_1
|
|
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->getAddChannel()Landroid/widget/ImageView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-static {p1}, Landroid/content/res/ColorStateList;->valueOf(I)Landroid/content/res/ColorStateList;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {v0, p1}, Landroid/widget/ImageView;->setImageTintList(Landroid/content/res/ColorStateList;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->getAddChannel()Landroid/widget/ImageView;
|
|
|
|
move-result-object p1
|
|
|
|
new-instance v0, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$onConfigure$1;
|
|
|
|
invoke-direct {v0, p0, p2}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory$onConfigure$1;-><init>(Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;Lcom/discord/widgets/channels/list/items/ChannelListItemCategory;)V
|
|
|
|
invoke-virtual {p1, v0}, Landroid/widget/ImageView;->setOnClickListener(Landroid/view/View$OnClickListener;)V
|
|
|
|
return-void
|
|
|
|
:cond_3
|
|
const-string p1, "data"
|
|
|
|
invoke-static {p1}, Lw/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/channels/list/items/ChannelListItem;
|
|
|
|
invoke-virtual {p0, p1, p2}, Lcom/discord/widgets/channels/list/WidgetChannelsListAdapter$ItemChannelCategory;->onConfigure(ILcom/discord/widgets/channels/list/items/ChannelListItem;)V
|
|
|
|
return-void
|
|
.end method
|