362 lines
8.9 KiB
Smali
362 lines
8.9 KiB
Smali
.class public final Lcom/discord/app/AppTextView;
|
|
.super Landroidx/appcompat/widget/AppCompatTextView;
|
|
.source "AppTextView.kt"
|
|
|
|
|
|
# instance fields
|
|
.field private uZ:I
|
|
|
|
.field private va:I
|
|
|
|
.field private vb:Ljava/lang/String;
|
|
|
|
|
|
# direct methods
|
|
.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/app/AppTextView;-><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/app/AppTextView;-><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 5
|
|
|
|
const-string v0, "context"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/k;->h(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-direct {p0, p1, p2, p3}, Landroidx/appcompat/widget/AppCompatTextView;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V
|
|
|
|
const/4 v0, -0x1
|
|
|
|
iput v0, p0, Lcom/discord/app/AppTextView;->va:I
|
|
|
|
if-eqz p2, :cond_1
|
|
|
|
sget-object v1, Lcom/discord/R$a;->AppTextView:[I
|
|
|
|
const/4 v2, 0x0
|
|
|
|
invoke-virtual {p1, p2, v1, p3, v2}, Landroid/content/Context;->obtainStyledAttributes(Landroid/util/AttributeSet;[III)Landroid/content/res/TypedArray;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {p1, v2}, Landroid/content/res/TypedArray;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object p2
|
|
|
|
iput-object p2, p0, Lcom/discord/app/AppTextView;->vb:Ljava/lang/String;
|
|
|
|
const/4 p2, 0x3
|
|
|
|
invoke-virtual {p1, p2, v0}, Landroid/content/res/TypedArray;->getInt(II)I
|
|
|
|
move-result p2
|
|
|
|
iput p2, p0, Lcom/discord/app/AppTextView;->va:I
|
|
|
|
const/4 p2, 0x2
|
|
|
|
invoke-virtual {p1, p2, v0}, Landroid/content/res/TypedArray;->getResourceId(II)I
|
|
|
|
move-result p2
|
|
|
|
iput p2, p0, Lcom/discord/app/AppTextView;->uZ:I
|
|
|
|
const/4 p2, 0x1
|
|
|
|
invoke-virtual {p1, p2, v2}, Landroid/content/res/TypedArray;->getBoolean(IZ)Z
|
|
|
|
move-result p3
|
|
|
|
invoke-virtual {p1}, Landroid/content/res/TypedArray;->recycle()V
|
|
|
|
iget p1, p0, Lcom/discord/app/AppTextView;->uZ:I
|
|
|
|
if-lez p1, :cond_0
|
|
|
|
iget p1, p0, Lcom/discord/app/AppTextView;->va:I
|
|
|
|
if-lez p1, :cond_0
|
|
|
|
new-array v0, v2, [Ljava/lang/Object;
|
|
|
|
invoke-static {v0, v2}, Ljava/util/Arrays;->copyOf([Ljava/lang/Object;I)[Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {p0}, Lcom/discord/app/AppTextView;->getResources()Landroid/content/res/Resources;
|
|
|
|
move-result-object v1
|
|
|
|
iget v3, p0, Lcom/discord/app/AppTextView;->uZ:I
|
|
|
|
new-array p2, p2, [Ljava/lang/Object;
|
|
|
|
invoke-static {p1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object v4
|
|
|
|
aput-object v4, p2, v2
|
|
|
|
invoke-virtual {v1, v3, p1, p2}, Landroid/content/res/Resources;->getQuantityString(II[Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
sget-object p2, Lkotlin/jvm/internal/z;->bkH:Lkotlin/jvm/internal/z;
|
|
|
|
const-string p2, "quantityString"
|
|
|
|
invoke-static {p1, p2}, Lkotlin/jvm/internal/k;->g(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
array-length p2, v0
|
|
|
|
invoke-static {v0, p2}, Ljava/util/Arrays;->copyOf([Ljava/lang/Object;I)[Ljava/lang/Object;
|
|
|
|
move-result-object p2
|
|
|
|
array-length v0, p2
|
|
|
|
invoke-static {p2, v0}, Ljava/util/Arrays;->copyOf([Ljava/lang/Object;I)[Ljava/lang/Object;
|
|
|
|
move-result-object p2
|
|
|
|
invoke-static {p1, p2}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
const-string p2, "java.lang.String.format(format, *args)"
|
|
|
|
invoke-static {p1, p2}, Lkotlin/jvm/internal/k;->g(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
check-cast p1, Ljava/lang/CharSequence;
|
|
|
|
invoke-virtual {p0, p1}, Lcom/discord/app/AppTextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
:cond_0
|
|
if-eqz p3, :cond_1
|
|
|
|
iget-object p1, p0, Lcom/discord/app/AppTextView;->vb:Ljava/lang/String;
|
|
|
|
new-array p2, v2, [Ljava/lang/Object;
|
|
|
|
invoke-virtual {p0, p1, p2}, Lcom/discord/app/AppTextView;->g(Ljava/lang/String;[Ljava/lang/Object;)V
|
|
|
|
:cond_1
|
|
return-void
|
|
.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/app/AppTextView;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public final varargs a(I[Ljava/lang/Object;)V
|
|
.locals 1
|
|
.param p1 # I
|
|
.annotation build Landroidx/annotation/StringRes;
|
|
.end annotation
|
|
.end param
|
|
|
|
const-string v0, "formatArgs"
|
|
|
|
invoke-static {p2, v0}, Lkotlin/jvm/internal/k;->h(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-virtual {p0}, Lcom/discord/app/AppTextView;->getResources()Landroid/content/res/Resources;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {v0, p1}, Landroid/content/res/Resources;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
array-length v0, p2
|
|
|
|
invoke-static {p2, v0}, Ljava/util/Arrays;->copyOf([Ljava/lang/Object;I)[Ljava/lang/Object;
|
|
|
|
move-result-object p2
|
|
|
|
invoke-virtual {p0, p1, p2}, Lcom/discord/app/AppTextView;->g(Ljava/lang/String;[Ljava/lang/Object;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public final varargs g(Ljava/lang/String;[Ljava/lang/Object;)V
|
|
.locals 2
|
|
|
|
const-string v0, "formatArgs"
|
|
|
|
invoke-static {p2, v0}, Lkotlin/jvm/internal/k;->h(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
if-eqz p1, :cond_2
|
|
|
|
array-length v0, p2
|
|
|
|
const/4 v1, 0x1
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
const/4 v0, 0x1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 v0, 0x0
|
|
|
|
:goto_0
|
|
xor-int/2addr v0, v1
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
array-length v0, p2
|
|
|
|
invoke-static {p2, v0}, Ljava/util/Arrays;->copyOf([Ljava/lang/Object;I)[Ljava/lang/Object;
|
|
|
|
move-result-object p2
|
|
|
|
array-length v0, p2
|
|
|
|
invoke-static {p2, v0}, Ljava/util/Arrays;->copyOf([Ljava/lang/Object;I)[Ljava/lang/Object;
|
|
|
|
move-result-object p2
|
|
|
|
invoke-static {p1, p2}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
const-string p2, "java.lang.String.format(this, *args)"
|
|
|
|
invoke-static {p1, p2}, Lkotlin/jvm/internal/k;->g(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
:cond_1
|
|
check-cast p1, Ljava/lang/CharSequence;
|
|
|
|
invoke-static {p1}, Lcom/discord/simpleast/core/a/b;->a(Ljava/lang/CharSequence;)Landroid/text/SpannableStringBuilder;
|
|
|
|
move-result-object p1
|
|
|
|
goto :goto_1
|
|
|
|
:cond_2
|
|
const/4 p1, 0x0
|
|
|
|
:goto_1
|
|
check-cast p1, Ljava/lang/CharSequence;
|
|
|
|
invoke-virtual {p0, p1}, Lcom/discord/app/AppTextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public final getAttrText()Ljava/lang/String;
|
|
.locals 1
|
|
|
|
iget-object v0, p0, Lcom/discord/app/AppTextView;->vb:Ljava/lang/String;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method public final setAttrText(Ljava/lang/String;)V
|
|
.locals 0
|
|
|
|
iput-object p1, p0, Lcom/discord/app/AppTextView;->vb:Ljava/lang/String;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public final varargs setTextFormatArgs([Ljava/lang/Object;)V
|
|
.locals 2
|
|
|
|
const-string v0, "formatArgs"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/k;->h(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
sget-object v0, Lkotlin/jvm/internal/z;->bkH:Lkotlin/jvm/internal/z;
|
|
|
|
iget-object v0, p0, Lcom/discord/app/AppTextView;->vb:Ljava/lang/String;
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
const-string v0, ""
|
|
|
|
:cond_0
|
|
array-length v1, p1
|
|
|
|
invoke-static {p1, v1}, Ljava/util/Arrays;->copyOf([Ljava/lang/Object;I)[Ljava/lang/Object;
|
|
|
|
move-result-object p1
|
|
|
|
array-length v1, p1
|
|
|
|
invoke-static {p1, v1}, Ljava/util/Arrays;->copyOf([Ljava/lang/Object;I)[Ljava/lang/Object;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-static {v0, p1}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
const-string v0, "java.lang.String.format(format, *args)"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/k;->g(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
check-cast p1, Ljava/lang/CharSequence;
|
|
|
|
invoke-virtual {p0, p1}, Lcom/discord/app/AppTextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
return-void
|
|
.end method
|