117 lines
3.7 KiB
Smali
117 lines
3.7 KiB
Smali
.class public final Lcom/discord/utilities/images/MGImagesBitmap;
|
|
.super Ljava/lang/Object;
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/MemberClasses;
|
|
value = {
|
|
Lcom/discord/utilities/images/MGImagesBitmap$CirclePostProcessor;
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field private static final DECODE_ERROR:Ljava/lang/String; = "Unable to decode bitmap."
|
|
|
|
.field public static final INSTANCE:Lcom/discord/utilities/images/MGImagesBitmap;
|
|
|
|
|
|
# direct methods
|
|
.method static constructor <clinit>()V
|
|
.locals 1
|
|
|
|
new-instance v0, Lcom/discord/utilities/images/MGImagesBitmap;
|
|
|
|
invoke-direct {v0}, Lcom/discord/utilities/images/MGImagesBitmap;-><init>()V
|
|
|
|
sput-object v0, Lcom/discord/utilities/images/MGImagesBitmap;->INSTANCE:Lcom/discord/utilities/images/MGImagesBitmap;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private constructor <init>()V
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public final getBitmap(Ljava/lang/String;IIZLkotlin/jvm/functions/Function1;Lkotlin/jvm/functions/Function1;)V
|
|
.locals 2
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/lang/String;",
|
|
"IIZ",
|
|
"Lkotlin/jvm/functions/Function1<",
|
|
"-",
|
|
"Landroid/graphics/Bitmap;",
|
|
"Lkotlin/Unit;",
|
|
">;",
|
|
"Lkotlin/jvm/functions/Function1<",
|
|
"-",
|
|
"Ljava/lang/Throwable;",
|
|
"Lkotlin/Unit;",
|
|
">;)V"
|
|
}
|
|
.end annotation
|
|
|
|
const-string v0, "imageUrl"
|
|
|
|
invoke-static {p1, v0}, Lkotlin/jvm/internal/j;->h(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const-string v0, "onSuccess"
|
|
|
|
invoke-static {p5, v0}, Lkotlin/jvm/internal/j;->h(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const-string v0, "onError"
|
|
|
|
invoke-static {p6, v0}, Lkotlin/jvm/internal/j;->h(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-static {}, Lcom/facebook/drawee/backends/pipeline/c;->fQ()Lcom/facebook/imagepipeline/b/g;
|
|
|
|
move-result-object v0
|
|
|
|
const/4 v1, 0x0
|
|
|
|
invoke-static {p1, p2, p3, v1}, Lcom/discord/utilities/images/MGImages;->getImageRequest(Ljava/lang/String;IIZ)Lcom/facebook/imagepipeline/request/ImageRequestBuilder;
|
|
|
|
move-result-object p1
|
|
|
|
if-eqz p4, :cond_0
|
|
|
|
new-instance p4, Lcom/discord/utilities/images/MGImagesBitmap$CirclePostProcessor;
|
|
|
|
invoke-direct {p4, p2, p3}, Lcom/discord/utilities/images/MGImagesBitmap$CirclePostProcessor;-><init>(II)V
|
|
|
|
check-cast p4, Lcom/facebook/imagepipeline/request/c;
|
|
|
|
invoke-virtual {p1, p4}, Lcom/facebook/imagepipeline/request/ImageRequestBuilder;->a(Lcom/facebook/imagepipeline/request/c;)Lcom/facebook/imagepipeline/request/ImageRequestBuilder;
|
|
|
|
:cond_0
|
|
invoke-virtual {p1}, Lcom/facebook/imagepipeline/request/ImageRequestBuilder;->jy()Lcom/facebook/imagepipeline/request/b;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-virtual {v0, p1}, Lcom/facebook/imagepipeline/b/g;->b(Lcom/facebook/imagepipeline/request/b;)Lcom/facebook/datasource/DataSource;
|
|
|
|
move-result-object p1
|
|
|
|
new-instance p2, Lcom/discord/utilities/images/MGImagesBitmap$getBitmap$2;
|
|
|
|
invoke-direct {p2, p5, p6}, Lcom/discord/utilities/images/MGImagesBitmap$getBitmap$2;-><init>(Lkotlin/jvm/functions/Function1;Lkotlin/jvm/functions/Function1;)V
|
|
|
|
check-cast p2, Lcom/facebook/datasource/d;
|
|
|
|
sget-object p3, Lcom/discord/utilities/images/MGImagesBitmap$getBitmap$3;->INSTANCE:Lcom/discord/utilities/images/MGImagesBitmap$getBitmap$3;
|
|
|
|
check-cast p3, Ljava/util/concurrent/Executor;
|
|
|
|
invoke-interface {p1, p2, p3}, Lcom/facebook/datasource/DataSource;->a(Lcom/facebook/datasource/d;Ljava/util/concurrent/Executor;)V
|
|
|
|
return-void
|
|
.end method
|