325 lines
9.1 KiB
Smali
325 lines
9.1 KiB
Smali
.class public final Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;
|
|
.super Lcom/discord/utilities/mg_recycler/MGRecyclerViewHolder;
|
|
.source "WidgetDebugging.kt"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/EnclosingClass;
|
|
value = Lcom/discord/widgets/debugging/WidgetDebugging$Adapter;
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/InnerClass;
|
|
accessFlags = 0x19
|
|
name = "Item"
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"Lcom/discord/utilities/mg_recycler/MGRecyclerViewHolder<",
|
|
"Lcom/discord/widgets/debugging/WidgetDebugging$Adapter;",
|
|
"Lcom/discord/app/AppLog$LoggedItem;",
|
|
">;"
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field public static final synthetic $$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
|
|
# instance fields
|
|
.field public final message$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, Lk0/n/c/q;
|
|
|
|
const-class v2, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;
|
|
|
|
invoke-static {v2}, Lk0/n/c/s;->getOrCreateKotlinClass(Ljava/lang/Class;)Lk0/r/b;
|
|
|
|
move-result-object v2
|
|
|
|
const-string v3, "message"
|
|
|
|
const-string v4, "getMessage()Landroid/widget/TextView;"
|
|
|
|
invoke-direct {v1, v2, v3, v4}, Lk0/n/c/q;-><init>(Lkotlin/reflect/KDeclarationContainer;Ljava/lang/String;Ljava/lang/String;)V
|
|
|
|
invoke-static {v1}, Lk0/n/c/s;->property1(Lk0/n/c/p;)Lk0/r/d;
|
|
|
|
const/4 v2, 0x0
|
|
|
|
aput-object v1, v0, v2
|
|
|
|
sput-object v0, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;->$$delegatedProperties:[Lkotlin/reflect/KProperty;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(ILcom/discord/widgets/debugging/WidgetDebugging$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, 0x7f0a02bf
|
|
|
|
invoke-static {p0, p1}, Lf/n/a/k/a;->k(Landroidx/recyclerview/widget/RecyclerView$ViewHolder;I)Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;->message$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
new-instance p1, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item$1;
|
|
|
|
invoke-direct {p1, p0}, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item$1;-><init>(Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;)V
|
|
|
|
const/4 p2, 0x0
|
|
|
|
new-array p2, p2, [Landroid/view/View;
|
|
|
|
invoke-virtual {p0, p1, p2}, Lcom/discord/utilities/mg_recycler/MGRecyclerViewHolder;->setOnLongClickListener(Lrx/functions/Action3;[Landroid/view/View;)V
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
const-string p1, "adapter"
|
|
|
|
invoke-static {p1}, Lk0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public static final synthetic access$getMessage$p(Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;)Landroid/widget/TextView;
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;->getMessage()Landroid/widget/TextView;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method private final getColor(Landroid/content/Context;I)I
|
|
.locals 1
|
|
.annotation build Landroidx/annotation/ColorInt;
|
|
.end annotation
|
|
|
|
const/4 v0, 0x2
|
|
|
|
if-eq p2, v0, :cond_3
|
|
|
|
const/4 v0, 0x3
|
|
|
|
if-eq p2, v0, :cond_2
|
|
|
|
const/4 v0, 0x5
|
|
|
|
if-eq p2, v0, :cond_1
|
|
|
|
const/4 v0, 0x6
|
|
|
|
if-eq p2, v0, :cond_0
|
|
|
|
const p2, 0x7f040409
|
|
|
|
invoke-static {p1, p2}, Lcom/discord/utilities/color/ColorCompat;->getThemedColor(Landroid/content/Context;I)I
|
|
|
|
move-result p1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const p2, 0x7f060235
|
|
|
|
invoke-static {p1, p2}, Lcom/discord/utilities/color/ColorCompat;->getColor(Landroid/content/Context;I)I
|
|
|
|
move-result p1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_1
|
|
const p2, 0x7f060252
|
|
|
|
invoke-static {p1, p2}, Lcom/discord/utilities/color/ColorCompat;->getColor(Landroid/content/Context;I)I
|
|
|
|
move-result p1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_2
|
|
const p2, 0x7f0601fb
|
|
|
|
invoke-static {p1, p2}, Lcom/discord/utilities/color/ColorCompat;->getColor(Landroid/content/Context;I)I
|
|
|
|
move-result p1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_3
|
|
const p2, 0x7f040410
|
|
|
|
invoke-static {p1, p2}, Lcom/discord/utilities/color/ColorCompat;->getThemedColor(Landroid/content/Context;I)I
|
|
|
|
move-result p1
|
|
|
|
:goto_0
|
|
return p1
|
|
.end method
|
|
|
|
.method private final getMessage()Landroid/widget/TextView;
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;->message$delegate:Lkotlin/properties/ReadOnlyProperty;
|
|
|
|
sget-object v1, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;->$$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/app/AppLog$LoggedItem;)V
|
|
.locals 3
|
|
.annotation build Landroid/annotation/SuppressLint;
|
|
value = {
|
|
"SetTextI18n"
|
|
}
|
|
.end annotation
|
|
|
|
if-eqz p2, :cond_1
|
|
|
|
invoke-super {p0, p1, p2}, Lcom/discord/utilities/mg_recycler/MGRecyclerViewHolder;->onConfigure(ILjava/lang/Object;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;->getMessage()Landroid/widget/TextView;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;->getMessage()Landroid/widget/TextView;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0}, Landroid/widget/TextView;->getContext()Landroid/content/Context;
|
|
|
|
move-result-object v0
|
|
|
|
const-string v1, "message.context"
|
|
|
|
invoke-static {v0, v1}, Lk0/n/c/h;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
iget v1, p2, Lcom/discord/app/AppLog$LoggedItem;->e:I
|
|
|
|
invoke-direct {p0, v0, v1}, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;->getColor(Landroid/content/Context;I)I
|
|
|
|
move-result v0
|
|
|
|
invoke-virtual {p1, v0}, Landroid/widget/TextView;->setTextColor(I)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;->getMessage()Landroid/widget/TextView;
|
|
|
|
move-result-object p1
|
|
|
|
new-instance v0, Ljava/lang/StringBuilder;
|
|
|
|
invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
iget-object v1, p2, Lcom/discord/app/AppLog$LoggedItem;->f:Ljava/lang/String;
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
iget-object p2, p2, Lcom/discord/app/AppLog$LoggedItem;->g:Ljava/lang/Throwable;
|
|
|
|
if-eqz p2, :cond_0
|
|
|
|
new-instance v1, Ljava/lang/StringBuilder;
|
|
|
|
invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
const/16 v2, 0xa
|
|
|
|
invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(C)Ljava/lang/StringBuilder;
|
|
|
|
invoke-virtual {v1, p2}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;
|
|
|
|
invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
move-result-object p2
|
|
|
|
if-eqz p2, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const-string p2, ""
|
|
|
|
:goto_0
|
|
invoke-virtual {v0, p2}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;
|
|
|
|
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
move-result-object p2
|
|
|
|
invoke-virtual {p1, p2}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;->getMessage()Landroid/widget/TextView;
|
|
|
|
move-result-object p1
|
|
|
|
const/4 p2, 0x2
|
|
|
|
invoke-virtual {p1, p2}, Landroid/widget/TextView;->setMaxLines(I)V
|
|
|
|
iget-object p1, p0, Landroidx/recyclerview/widget/RecyclerView$ViewHolder;->itemView:Landroid/view/View;
|
|
|
|
new-instance p2, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item$onConfigure$2;
|
|
|
|
invoke-direct {p2, p0}, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item$onConfigure$2;-><init>(Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;)V
|
|
|
|
invoke-virtual {p1, p2}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V
|
|
|
|
return-void
|
|
|
|
:cond_1
|
|
const-string p1, "data"
|
|
|
|
invoke-static {p1}, Lk0/n/c/h;->c(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/app/AppLog$LoggedItem;
|
|
|
|
invoke-virtual {p0, p1, p2}, Lcom/discord/widgets/debugging/WidgetDebugging$Adapter$Item;->onConfigure(ILcom/discord/app/AppLog$LoggedItem;)V
|
|
|
|
return-void
|
|
.end method
|