372 lines
8.6 KiB
Smali
372 lines
8.6 KiB
Smali
.class public final Lf/a/b/n;
|
|
.super Ljava/lang/Object;
|
|
.source "AppToast.kt"
|
|
|
|
|
|
# direct methods
|
|
.method public static final a(Landroid/content/Context;Ljava/lang/CharSequence;I)V
|
|
.locals 1
|
|
|
|
const/4 v0, 0x0
|
|
|
|
if-eqz p0, :cond_1
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
invoke-virtual {p0, p2}, Landroid/content/Context;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object p2
|
|
|
|
const-string v0, "context.getString(toastResId)"
|
|
|
|
invoke-static {p2, v0}, Lj0/n/c/h;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-static {p0, p1, p2}, Lf/a/b/n;->b(Landroid/content/Context;Ljava/lang/CharSequence;Ljava/lang/String;)V
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
const-string p0, "text"
|
|
|
|
invoke-static {p0}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
throw v0
|
|
|
|
:cond_1
|
|
const-string p0, "context"
|
|
|
|
invoke-static {p0}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method public static final b(Landroid/content/Context;Ljava/lang/CharSequence;Ljava/lang/String;)V
|
|
.locals 3
|
|
|
|
const/4 v0, 0x0
|
|
|
|
if-eqz p1, :cond_3
|
|
|
|
if-eqz p2, :cond_2
|
|
|
|
const-string v1, "clipboard"
|
|
|
|
invoke-virtual {p0, v1}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;
|
|
|
|
move-result-object v1
|
|
|
|
instance-of v2, v1, Landroid/content/ClipboardManager;
|
|
|
|
if-nez v2, :cond_0
|
|
|
|
move-object v1, v0
|
|
|
|
:cond_0
|
|
check-cast v1, Landroid/content/ClipboardManager;
|
|
|
|
const-string v2, ""
|
|
|
|
invoke-static {v2, p1}, Landroid/content/ClipData;->newPlainText(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Landroid/content/ClipData;
|
|
|
|
move-result-object p1
|
|
|
|
if-eqz v1, :cond_1
|
|
|
|
invoke-virtual {v1, p1}, Landroid/content/ClipboardManager;->setPrimaryClip(Landroid/content/ClipData;)V
|
|
|
|
:cond_1
|
|
const/4 p1, 0x0
|
|
|
|
const/16 v1, 0xc
|
|
|
|
invoke-static {p0, p2, p1, v0, v1}, Lf/a/b/n;->k(Landroid/content/Context;Ljava/lang/CharSequence;ILcom/discord/utilities/view/ToastManager;I)V
|
|
|
|
return-void
|
|
|
|
:cond_2
|
|
const-string p0, "toastText"
|
|
|
|
invoke-static {p0}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
throw v0
|
|
|
|
:cond_3
|
|
const-string p0, "text"
|
|
|
|
invoke-static {p0}, Lj0/n/c/h;->c(Ljava/lang/String;)V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method public static synthetic c(Landroid/content/Context;Ljava/lang/CharSequence;II)V
|
|
.locals 0
|
|
|
|
and-int/lit8 p3, p3, 0x4
|
|
|
|
if-eqz p3, :cond_0
|
|
|
|
const p2, 0x7f1204cd
|
|
|
|
:cond_0
|
|
invoke-static {p0, p1, p2}, Lf/a/b/n;->a(Landroid/content/Context;Ljava/lang/CharSequence;I)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final d(Landroid/content/Context;I)V
|
|
.locals 3
|
|
.param p1 # I
|
|
.annotation build Landroidx/annotation/StringRes;
|
|
.end annotation
|
|
.end param
|
|
|
|
const/4 v0, 0x0
|
|
|
|
const/4 v1, 0x0
|
|
|
|
const/16 v2, 0xc
|
|
|
|
invoke-static {p0, p1, v0, v1, v2}, Lf/a/b/n;->j(Landroid/content/Context;IILcom/discord/utilities/view/ToastManager;I)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final e(Landroid/content/Context;IILcom/discord/utilities/view/ToastManager;)V
|
|
.locals 0
|
|
.param p1 # I
|
|
.annotation build Landroidx/annotation/StringRes;
|
|
.end annotation
|
|
.end param
|
|
|
|
if-eqz p0, :cond_0
|
|
|
|
invoke-virtual {p0, p1}, Landroid/content/Context;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 p1, 0x0
|
|
|
|
:goto_0
|
|
invoke-static {p0, p1, p2, p3}, Lf/a/b/n;->f(Landroid/content/Context;Ljava/lang/CharSequence;ILcom/discord/utilities/view/ToastManager;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final f(Landroid/content/Context;Ljava/lang/CharSequence;ILcom/discord/utilities/view/ToastManager;)V
|
|
.locals 3
|
|
|
|
if-eqz p0, :cond_2
|
|
|
|
new-instance v0, Landroid/widget/Toast;
|
|
|
|
invoke-direct {v0, p0}, Landroid/widget/Toast;-><init>(Landroid/content/Context;)V
|
|
|
|
new-instance v1, Landroid/view/ContextThemeWrapper;
|
|
|
|
const v2, 0x7f13036f
|
|
|
|
invoke-direct {v1, p0, v2}, Landroid/view/ContextThemeWrapper;-><init>(Landroid/content/Context;I)V
|
|
|
|
instance-of p0, p1, Lcom/facebook/drawee/span/DraweeSpanStringBuilder;
|
|
|
|
if-eqz p0, :cond_0
|
|
|
|
new-instance p0, Lcom/discord/utilities/view/text/SimpleDraweeSpanTextView;
|
|
|
|
invoke-direct {p0, v1}, Lcom/discord/utilities/view/text/SimpleDraweeSpanTextView;-><init>(Landroid/content/Context;)V
|
|
|
|
check-cast p1, Lcom/facebook/drawee/span/DraweeSpanStringBuilder;
|
|
|
|
invoke-virtual {p0, p1}, Lcom/discord/utilities/view/text/SimpleDraweeSpanTextView;->setDraweeSpanStringBuilder(Lcom/facebook/drawee/span/DraweeSpanStringBuilder;)V
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
new-instance p0, Landroid/widget/TextView;
|
|
|
|
invoke-direct {p0, v1}, Landroid/widget/TextView;-><init>(Landroid/content/Context;)V
|
|
|
|
invoke-virtual {p0, p1}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V
|
|
|
|
:goto_0
|
|
invoke-virtual {v0, p0}, Landroid/widget/Toast;->setView(Landroid/view/View;)V
|
|
|
|
invoke-virtual {v0, p2}, Landroid/widget/Toast;->setDuration(I)V
|
|
|
|
if-eqz p3, :cond_1
|
|
|
|
invoke-virtual {p3, v0}, Lcom/discord/utilities/view/ToastManager;->show(Landroid/widget/Toast;)V
|
|
|
|
goto :goto_1
|
|
|
|
:cond_1
|
|
invoke-virtual {v0}, Landroid/widget/Toast;->show()V
|
|
|
|
:cond_2
|
|
:goto_1
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final g(Landroidx/fragment/app/Fragment;I)V
|
|
.locals 2
|
|
.param p1 # I
|
|
.annotation build Landroidx/annotation/StringRes;
|
|
.end annotation
|
|
.end param
|
|
|
|
const/4 v0, 0x0
|
|
|
|
const/4 v1, 0x4
|
|
|
|
invoke-static {p0, p1, v0, v1}, Lf/a/b/n;->l(Landroidx/fragment/app/Fragment;III)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final h(Landroidx/fragment/app/Fragment;II)V
|
|
.locals 2
|
|
.param p1 # I
|
|
.annotation build Landroidx/annotation/StringRes;
|
|
.end annotation
|
|
.end param
|
|
|
|
const/4 v0, 0x0
|
|
|
|
if-eqz p0, :cond_0
|
|
|
|
invoke-virtual {p0}, Landroidx/fragment/app/Fragment;->getContext()Landroid/content/Context;
|
|
|
|
move-result-object v1
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
invoke-virtual {v1, p1}, Landroid/content/Context;->getString(I)Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
move-object p1, v0
|
|
|
|
:goto_0
|
|
if-eqz p0, :cond_1
|
|
|
|
invoke-virtual {p0}, Landroidx/fragment/app/Fragment;->getContext()Landroid/content/Context;
|
|
|
|
move-result-object p0
|
|
|
|
goto :goto_1
|
|
|
|
:cond_1
|
|
move-object p0, v0
|
|
|
|
:goto_1
|
|
const/16 v1, 0x8
|
|
|
|
invoke-static {p0, p1, p2, v0, v1}, Lf/a/b/n;->k(Landroid/content/Context;Ljava/lang/CharSequence;ILcom/discord/utilities/view/ToastManager;I)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static final i(Landroidx/fragment/app/Fragment;Ljava/lang/CharSequence;)V
|
|
.locals 2
|
|
|
|
const/4 v0, 0x0
|
|
|
|
const/4 v1, 0x4
|
|
|
|
invoke-static {p0, p1, v0, v1}, Lf/a/b/n;->m(Landroidx/fragment/app/Fragment;Ljava/lang/CharSequence;II)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static synthetic j(Landroid/content/Context;IILcom/discord/utilities/view/ToastManager;I)V
|
|
.locals 0
|
|
|
|
and-int/lit8 p3, p4, 0x4
|
|
|
|
if-eqz p3, :cond_0
|
|
|
|
const/4 p2, 0x0
|
|
|
|
:cond_0
|
|
and-int/lit8 p3, p4, 0x8
|
|
|
|
const/4 p3, 0x0
|
|
|
|
invoke-static {p0, p1, p2, p3}, Lf/a/b/n;->e(Landroid/content/Context;IILcom/discord/utilities/view/ToastManager;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static synthetic k(Landroid/content/Context;Ljava/lang/CharSequence;ILcom/discord/utilities/view/ToastManager;I)V
|
|
.locals 1
|
|
|
|
and-int/lit8 v0, p4, 0x4
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
const/4 p2, 0x0
|
|
|
|
:cond_0
|
|
and-int/lit8 p4, p4, 0x8
|
|
|
|
if-eqz p4, :cond_1
|
|
|
|
const/4 p3, 0x0
|
|
|
|
:cond_1
|
|
invoke-static {p0, p1, p2, p3}, Lf/a/b/n;->f(Landroid/content/Context;Ljava/lang/CharSequence;ILcom/discord/utilities/view/ToastManager;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static synthetic l(Landroidx/fragment/app/Fragment;III)V
|
|
.locals 0
|
|
|
|
and-int/lit8 p3, p3, 0x4
|
|
|
|
if-eqz p3, :cond_0
|
|
|
|
const/4 p2, 0x0
|
|
|
|
:cond_0
|
|
invoke-static {p0, p1, p2}, Lf/a/b/n;->h(Landroidx/fragment/app/Fragment;II)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static m(Landroidx/fragment/app/Fragment;Ljava/lang/CharSequence;II)V
|
|
.locals 1
|
|
|
|
and-int/lit8 p3, p3, 0x4
|
|
|
|
if-eqz p3, :cond_0
|
|
|
|
const/4 p2, 0x0
|
|
|
|
:cond_0
|
|
const/4 p3, 0x0
|
|
|
|
if-eqz p0, :cond_1
|
|
|
|
invoke-virtual {p0}, Landroidx/fragment/app/Fragment;->getContext()Landroid/content/Context;
|
|
|
|
move-result-object p0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_1
|
|
move-object p0, p3
|
|
|
|
:goto_0
|
|
const/16 v0, 0x8
|
|
|
|
invoke-static {p0, p1, p2, p3, v0}, Lf/a/b/n;->k(Landroid/content/Context;Ljava/lang/CharSequence;ILcom/discord/utilities/view/ToastManager;I)V
|
|
|
|
return-void
|
|
.end method
|