121 lines
3.7 KiB
Smali
121 lines
3.7 KiB
Smali
.class public final Lcom/discord/utilities/textprocessing/node/InviteNode;
|
|
.super Lcom/discord/simpleast/core/node/Node;
|
|
.source "InviteNode.kt"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"<T::",
|
|
"Lcom/discord/utilities/textprocessing/node/BasicRenderContext;",
|
|
">",
|
|
"Lcom/discord/simpleast/core/node/Node<",
|
|
"TT;>;"
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# instance fields
|
|
.field private final inviteUrl:Ljava/lang/String;
|
|
|
|
|
|
# direct methods
|
|
.method public constructor <init>(Ljava/lang/String;)V
|
|
.locals 1
|
|
|
|
const-string v0, "inviteUrl"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/j;->h(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-direct {p0}, Lcom/discord/simpleast/core/node/Node;-><init>()V
|
|
|
|
iput-object p1, p0, Lcom/discord/utilities/textprocessing/node/InviteNode;->inviteUrl:Ljava/lang/String;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public final render(Landroid/text/SpannableStringBuilder;Lcom/discord/utilities/textprocessing/node/BasicRenderContext;)V
|
|
.locals 3
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Landroid/text/SpannableStringBuilder;",
|
|
"TT;)V"
|
|
}
|
|
.end annotation
|
|
|
|
const-string v0, "builder"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/j;->h(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const-string v0, "renderContext"
|
|
|
|
invoke-static {p2, v0}, Lkotlin/jvm/internal/j;->h(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-interface {p2}, Lcom/discord/utilities/textprocessing/node/BasicRenderContext;->getContext()Landroid/content/Context;
|
|
|
|
move-result-object p2
|
|
|
|
const v0, 0x7f06008f
|
|
|
|
invoke-static {p2, v0}, Lcom/discord/utilities/color/ColorCompat;->getColor(Landroid/content/Context;I)I
|
|
|
|
move-result p2
|
|
|
|
iget-object v0, p0, Lcom/discord/utilities/textprocessing/node/InviteNode;->inviteUrl:Ljava/lang/String;
|
|
|
|
const/16 v1, 0x2f
|
|
|
|
invoke-static {v0, v1}, Lkotlin/text/l;->a(Ljava/lang/String;C)Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
new-instance v1, Lcom/discord/utilities/spans/ClickableSpan;
|
|
|
|
invoke-static {p2}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
|
|
|
|
move-result-object p2
|
|
|
|
new-instance v2, Lcom/discord/utilities/textprocessing/node/InviteNode$render$clickableSpan$1;
|
|
|
|
invoke-direct {v2, v0}, Lcom/discord/utilities/textprocessing/node/InviteNode$render$clickableSpan$1;-><init>(Ljava/lang/String;)V
|
|
|
|
check-cast v2, Lkotlin/jvm/functions/Function1;
|
|
|
|
const/4 v0, 0x1
|
|
|
|
invoke-direct {v1, p2, v0, v2}, Lcom/discord/utilities/spans/ClickableSpan;-><init>(Ljava/lang/Integer;ZLkotlin/jvm/functions/Function1;)V
|
|
|
|
invoke-virtual {p1}, Landroid/text/SpannableStringBuilder;->length()I
|
|
|
|
move-result p2
|
|
|
|
iget-object v0, p0, Lcom/discord/utilities/textprocessing/node/InviteNode;->inviteUrl:Ljava/lang/String;
|
|
|
|
check-cast v0, Ljava/lang/CharSequence;
|
|
|
|
invoke-virtual {p1, v0}, Landroid/text/SpannableStringBuilder;->append(Ljava/lang/CharSequence;)Landroid/text/SpannableStringBuilder;
|
|
|
|
invoke-virtual {p1}, Landroid/text/SpannableStringBuilder;->length()I
|
|
|
|
move-result v0
|
|
|
|
const/16 v2, 0x21
|
|
|
|
invoke-virtual {p1, v1, p2, v0, v2}, Landroid/text/SpannableStringBuilder;->setSpan(Ljava/lang/Object;III)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public final bridge synthetic render(Landroid/text/SpannableStringBuilder;Ljava/lang/Object;)V
|
|
.locals 0
|
|
|
|
check-cast p2, Lcom/discord/utilities/textprocessing/node/BasicRenderContext;
|
|
|
|
invoke-virtual {p0, p1, p2}, Lcom/discord/utilities/textprocessing/node/InviteNode;->render(Landroid/text/SpannableStringBuilder;Lcom/discord/utilities/textprocessing/node/BasicRenderContext;)V
|
|
|
|
return-void
|
|
.end method
|