629 lines
15 KiB
Smali
629 lines
15 KiB
Smali
.class public final Lcom/discord/views/ServerFolderView;
|
|
.super Landroid/widget/LinearLayout;
|
|
.source "ServerFolderView.kt"
|
|
|
|
|
|
# static fields
|
|
.field public static final synthetic i:[Lkotlin/reflect/KProperty;
|
|
|
|
|
|
# instance fields
|
|
.field public final d:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final e:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public final f:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
.field public g:Ljava/lang/Long;
|
|
|
|
.field public h:Z
|
|
|
|
|
|
# direct methods
|
|
.method public static constructor <clinit>()V
|
|
.locals 6
|
|
|
|
const/4 v0, 0x3
|
|
|
|
new-array v0, v0, [Lkotlin/reflect/KProperty;
|
|
|
|
new-instance v1, Ly/v/b/u;
|
|
|
|
const-class v2, Lcom/discord/views/ServerFolderView;
|
|
|
|
invoke-static {v2}, Ly/v/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Ly/z/b;
|
|
|
|
move-result-object v2
|
|
|
|
const-string v3, "folderImg"
|
|
|
|
const-string v4, "getFolderImg()Landroid/widget/ImageView;"
|
|
|
|
invoke-direct {v1, v2, v3, v4}, Ly/v/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v2, Ly/v/b/w;->a:Ly/v/b/x;
|
|
|
|
invoke-virtual {v2, v1}, Ly/v/b/x;->property1(Ly/v/b/t;)Ly/z/d;
|
|
|
|
const/4 v2, 0x0
|
|
|
|
aput-object v1, v0, v2
|
|
|
|
const/4 v1, 0x1
|
|
|
|
new-instance v2, Ly/v/b/u;
|
|
|
|
const-class v3, Lcom/discord/views/ServerFolderView;
|
|
|
|
invoke-static {v3}, Ly/v/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Ly/z/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "guildViewsContainer"
|
|
|
|
const-string v5, "getGuildViewsContainer()Landroid/view/View;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Ly/v/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Ly/v/b/w;->a:Ly/v/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Ly/v/b/x;->property1(Ly/v/b/t;)Ly/z/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
const/4 v1, 0x2
|
|
|
|
new-instance v2, Ly/v/b/u;
|
|
|
|
const-class v3, Lcom/discord/views/ServerFolderView;
|
|
|
|
invoke-static {v3}, Ly/v/b/w;->getOrCreateKotlinClass(Ljava/lang/Class;)Ly/z/b;
|
|
|
|
move-result-object v3
|
|
|
|
const-string v4, "guildViews"
|
|
|
|
const-string v5, "getGuildViews()Ljava/util/List;"
|
|
|
|
invoke-direct {v2, v3, v4, v5}, Ly/v/b/u;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
sget-object v3, Ly/v/b/w;->a:Ly/v/b/x;
|
|
|
|
invoke-virtual {v3, v2}, Ly/v/b/x;->property1(Ly/v/b/t;)Ly/z/d;
|
|
|
|
aput-object v2, v0, v1
|
|
|
|
sput-object v0, Lcom/discord/views/ServerFolderView;->i:[Lkotlin/reflect/KProperty;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Landroid/content/Context;)V
|
|
.locals 6
|
|
|
|
const/4 v2, 0x0
|
|
|
|
const/4 v3, 0x0
|
|
|
|
const/4 v4, 0x6
|
|
|
|
const/4 v5, 0x0
|
|
|
|
move-object v0, p0
|
|
|
|
move-object v1, p1
|
|
|
|
invoke-direct/range {v0 .. v5}, Lcom/discord/views/ServerFolderView;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;IILkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;)V
|
|
.locals 6
|
|
|
|
const/4 v3, 0x0
|
|
|
|
const/4 v4, 0x4
|
|
|
|
const/4 v5, 0x0
|
|
|
|
move-object v0, p0
|
|
|
|
move-object v1, p1
|
|
|
|
move-object v2, p2
|
|
|
|
invoke-direct/range {v0 .. v5}, Lcom/discord/views/ServerFolderView;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;IILkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V
|
|
.locals 0
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
invoke-direct {p0, p1, p2, p3}, Landroid/widget/LinearLayout;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V
|
|
|
|
const p2, 0x7f0a036f
|
|
|
|
invoke-static {p0, p2}, Lf/o/a/j/a;->a(Landroid/view/View;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p2
|
|
|
|
iput-object p2, p0, Lcom/discord/views/ServerFolderView;->d:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const p2, 0x7f0a0426
|
|
|
|
invoke-static {p0, p2}, Lf/o/a/j/a;->a(Landroid/view/View;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p2
|
|
|
|
iput-object p2, p0, Lcom/discord/views/ServerFolderView;->e:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const/4 p2, 0x4
|
|
|
|
new-array p2, p2, [I
|
|
|
|
fill-array-data p2, :array_0
|
|
|
|
invoke-static {}, Lf/o/a/j/a;->c()Lkotlin/jvm/functions/Function2;
|
|
|
|
move-result-object p3
|
|
|
|
invoke-static {p2, p3}, Lf/o/a/j/a;->a([ILkotlin/jvm/functions/Function2;)La0/h;
|
|
|
|
move-result-object p2
|
|
|
|
iput-object p2, p0, Lcom/discord/views/ServerFolderView;->f:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
const p2, 0x7f0d010d
|
|
|
|
invoke-static {p1, p2, p0}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;
|
|
|
|
const/4 p1, 0x1
|
|
|
|
invoke-virtual {p0, p1}, Landroid/widget/LinearLayout;->setOrientation(I)V
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
const-string p1, "context"
|
|
|
|
invoke-static {p1}, Ly/v/b/j;->a(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
|
|
nop
|
|
|
|
:array_0
|
|
.array-data 4
|
|
0x7f0a0420
|
|
0x7f0a0421
|
|
0x7f0a0422
|
|
0x7f0a0423
|
|
.end array-data
|
|
.end method
|
|
|
|
.method public synthetic constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;IILkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
.locals 0
|
|
|
|
and-int/lit8 p5, p4, 0x2
|
|
|
|
if-eqz p5, :cond_0
|
|
|
|
const/4 p2, 0x0
|
|
|
|
:cond_0
|
|
and-int/lit8 p4, p4, 0x4
|
|
|
|
if-eqz p4, :cond_1
|
|
|
|
const/4 p3, 0x0
|
|
|
|
:cond_1
|
|
invoke-direct {p0, p1, p2, p3}, Lcom/discord/views/ServerFolderView;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final synthetic a(Lcom/discord/views/ServerFolderView;)V
|
|
.locals 0
|
|
|
|
invoke-virtual {p0}, Lcom/discord/views/ServerFolderView;->a()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private final getFolderImg()Landroid/widget/ImageView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/views/ServerFolderView;->d:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/views/ServerFolderView;->i:[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/ImageView;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getGuildViews()Ljava/util/List;
|
|
.locals 3
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"()",
|
|
"Ljava/util/List<",
|
|
"Lcom/discord/views/GuildView;",
|
|
">;"
|
|
}
|
|
.end annotation
|
|
|
|
iget-object v0, p0, Lcom/discord/views/ServerFolderView;->f:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/views/ServerFolderView;->i:[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, Ljava/util/List;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private final getGuildViewsContainer()Landroid/view/View;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/views/ServerFolderView;->e:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/views/ServerFolderView;->i:[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/view/View;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public final a()V
|
|
.locals 3
|
|
|
|
iget-boolean v0, p0, Lcom/discord/views/ServerFolderView;->h:Z
|
|
|
|
const/4 v1, 0x0
|
|
|
|
const/16 v2, 0x8
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
invoke-direct {p0}, Lcom/discord/views/ServerFolderView;->getFolderImg()Landroid/widget/ImageView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setVisibility(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/views/ServerFolderView;->getGuildViewsContainer()Landroid/view/View;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0, v2}, Landroid/view/View;->setVisibility(I)V
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
invoke-direct {p0}, Lcom/discord/views/ServerFolderView;->getFolderImg()Landroid/widget/ImageView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0, v2}, Landroid/widget/ImageView;->setVisibility(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/views/ServerFolderView;->getGuildViewsContainer()Landroid/view/View;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
|
|
|
|
:goto_0
|
|
return-void
|
|
.end method
|
|
|
|
.method public final a(I)V
|
|
.locals 2
|
|
.param p1 # I
|
|
.annotation build Landroidx/annotation/AnimRes;
|
|
.end annotation
|
|
.end param
|
|
|
|
invoke-virtual {p0}, Landroid/widget/LinearLayout;->getContext()Landroid/content/Context;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-static {v0, p1}, Landroid/view/animation/AnimationUtils;->loadAnimation(Landroid/content/Context;I)Landroid/view/animation/Animation;
|
|
|
|
move-result-object p1
|
|
|
|
new-instance v0, Lcom/discord/views/ServerFolderView$a;
|
|
|
|
invoke-direct {v0, p0}, Lcom/discord/views/ServerFolderView$a;-><init>(Lcom/discord/views/ServerFolderView;)V
|
|
|
|
invoke-virtual {p1, v0}, Landroid/view/animation/Animation;->setAnimationListener(Landroid/view/animation/Animation$AnimationListener;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/views/ServerFolderView;->getFolderImg()Landroid/widget/ImageView;
|
|
|
|
move-result-object v0
|
|
|
|
const/4 v1, 0x0
|
|
|
|
invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setVisibility(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/views/ServerFolderView;->getGuildViewsContainer()Landroid/view/View;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/views/ServerFolderView;->getFolderImg()Landroid/widget/ImageView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0, p1}, Landroid/widget/ImageView;->startAnimation(Landroid/view/animation/Animation;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public final a(JZLjava/util/List;Ljava/lang/Integer;)V
|
|
.locals 10
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(JZ",
|
|
"Ljava/util/List<",
|
|
"+",
|
|
"Lcom/discord/models/domain/ModelGuild;",
|
|
">;",
|
|
"Ljava/lang/Integer;",
|
|
")V"
|
|
}
|
|
.end annotation
|
|
|
|
const/4 v0, 0x0
|
|
|
|
if-eqz p4, :cond_a
|
|
|
|
iget-object v1, p0, Lcom/discord/views/ServerFolderView;->g:Ljava/lang/Long;
|
|
|
|
const/4 v2, 0x1
|
|
|
|
const/4 v3, 0x0
|
|
|
|
if-nez v1, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
invoke-virtual {v1}, Ljava/lang/Long;->longValue()J
|
|
|
|
move-result-wide v4
|
|
|
|
cmp-long v1, v4, p1
|
|
|
|
if-nez v1, :cond_1
|
|
|
|
iget-boolean v1, p0, Lcom/discord/views/ServerFolderView;->h:Z
|
|
|
|
if-eq v1, p3, :cond_1
|
|
|
|
const/4 v1, 0x1
|
|
|
|
goto :goto_1
|
|
|
|
:cond_1
|
|
:goto_0
|
|
const/4 v1, 0x0
|
|
|
|
:goto_1
|
|
invoke-static {p1, p2}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/discord/views/ServerFolderView;->g:Ljava/lang/Long;
|
|
|
|
if-eqz p3, :cond_4
|
|
|
|
iput-boolean v2, p0, Lcom/discord/views/ServerFolderView;->h:Z
|
|
|
|
if-eqz v1, :cond_2
|
|
|
|
const p1, 0x7f010026
|
|
|
|
invoke-virtual {p0, p1}, Lcom/discord/views/ServerFolderView;->a(I)V
|
|
|
|
goto :goto_2
|
|
|
|
:cond_2
|
|
invoke-virtual {p0}, Lcom/discord/views/ServerFolderView;->a()V
|
|
|
|
:goto_2
|
|
if-eqz p5, :cond_3
|
|
|
|
invoke-virtual {p5}, Ljava/lang/Integer;->intValue()I
|
|
|
|
move-result p1
|
|
|
|
goto :goto_3
|
|
|
|
:cond_3
|
|
invoke-virtual {p0}, Landroid/widget/LinearLayout;->getContext()Landroid/content/Context;
|
|
|
|
move-result-object p1
|
|
|
|
const p2, 0x7f060050
|
|
|
|
invoke-static {p1, p2}, Landroidx/core/content/ContextCompat;->getColor(Landroid/content/Context;I)I
|
|
|
|
move-result p1
|
|
|
|
:goto_3
|
|
int-to-long p1, p1
|
|
|
|
const-wide p3, 0xff000000L
|
|
|
|
add-long/2addr p1, p3
|
|
|
|
long-to-int p2, p1
|
|
|
|
invoke-direct {p0}, Lcom/discord/views/ServerFolderView;->getFolderImg()Landroid/widget/ImageView;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-static {p2}, Landroid/content/res/ColorStateList;->valueOf(I)Landroid/content/res/ColorStateList;
|
|
|
|
move-result-object p2
|
|
|
|
invoke-static {p1, p2}, Landroidx/core/widget/ImageViewCompat;->setImageTintList(Landroid/widget/ImageView;Landroid/content/res/ColorStateList;)V
|
|
|
|
goto :goto_8
|
|
|
|
:cond_4
|
|
iput-boolean v3, p0, Lcom/discord/views/ServerFolderView;->h:Z
|
|
|
|
if-eqz v1, :cond_5
|
|
|
|
const p1, 0x7f010027
|
|
|
|
invoke-virtual {p0, p1}, Lcom/discord/views/ServerFolderView;->a(I)V
|
|
|
|
goto :goto_4
|
|
|
|
:cond_5
|
|
invoke-virtual {p0}, Lcom/discord/views/ServerFolderView;->a()V
|
|
|
|
:goto_4
|
|
invoke-direct {p0}, Lcom/discord/views/ServerFolderView;->getGuildViews()Ljava/util/List;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-interface {p1}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object p1
|
|
|
|
const/4 p2, 0x0
|
|
|
|
:goto_5
|
|
invoke-interface {p1}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result p3
|
|
|
|
if-eqz p3, :cond_9
|
|
|
|
invoke-interface {p1}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object p3
|
|
|
|
add-int/lit8 p5, p2, 0x1
|
|
|
|
if-ltz p2, :cond_8
|
|
|
|
check-cast p3, Lcom/discord/views/GuildView;
|
|
|
|
invoke-static {p4}, Lf/o/a/j/a;->getLastIndex(Ljava/util/List;)I
|
|
|
|
move-result v1
|
|
|
|
if-lt v1, p2, :cond_7
|
|
|
|
invoke-interface {p4, p2}, Ljava/util/List;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object p2
|
|
|
|
check-cast p2, Lcom/discord/models/domain/ModelGuild;
|
|
|
|
invoke-virtual {p2}, Lcom/discord/models/domain/ModelGuild;->hasIcon()Z
|
|
|
|
move-result v1
|
|
|
|
if-eqz v1, :cond_6
|
|
|
|
const/4 v6, 0x0
|
|
|
|
const/4 v7, 0x0
|
|
|
|
const/16 v8, 0xc
|
|
|
|
const/4 v9, 0x0
|
|
|
|
const-string v5, "asset://asset/images/default_icon.jpg"
|
|
|
|
move-object v4, p2
|
|
|
|
invoke-static/range {v4 .. v9}, Lcom/discord/utilities/icon/IconUtils;->getForGuild$default(Lcom/discord/models/domain/ModelGuild;Ljava/lang/String;ZLjava/lang/Integer;ILjava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object v1
|
|
|
|
goto :goto_6
|
|
|
|
:cond_6
|
|
move-object v1, v0
|
|
|
|
:goto_6
|
|
invoke-virtual {p3, v3}, Landroid/view/ViewGroup;->setVisibility(I)V
|
|
|
|
invoke-virtual {p2}, Lcom/discord/models/domain/ModelGuild;->getShortName()Ljava/lang/String;
|
|
|
|
move-result-object p2
|
|
|
|
const-string v2, "guild.shortName"
|
|
|
|
invoke-static {p2, v2}, Ly/v/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-virtual {p3, p2, v1}, Lcom/discord/views/GuildView;->a(Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
goto :goto_7
|
|
|
|
:cond_7
|
|
const/16 p2, 0x8
|
|
|
|
invoke-virtual {p3, p2}, Landroid/view/ViewGroup;->setVisibility(I)V
|
|
|
|
:goto_7
|
|
move p2, p5
|
|
|
|
goto :goto_5
|
|
|
|
:cond_8
|
|
invoke-static {}, Lf/o/a/j/a;->throwIndexOverflow()V
|
|
|
|
throw v0
|
|
|
|
:cond_9
|
|
:goto_8
|
|
return-void
|
|
|
|
:cond_a
|
|
const-string p1, "guilds"
|
|
|
|
invoke-static {p1}, Ly/v/b/j;->a(Ljava/lang/String;)V
|
|
|
|
throw v0
|
|
.end method
|