291 lines
6.8 KiB
Smali
291 lines
6.8 KiB
Smali
.class public final Lf/d/a/e$c;
|
|
.super Ljava/lang/Object;
|
|
.source "LottieCompositionFactory.java"
|
|
|
|
# interfaces
|
|
.implements Ljava/util/concurrent/Callable;
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/EnclosingMethod;
|
|
value = Lf/d/a/e;->f(Landroid/content/Context;Ljava/lang/String;)Lf/d/a/o;
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/InnerClass;
|
|
accessFlags = 0x9
|
|
name = null
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"Ljava/lang/Object;",
|
|
"Ljava/util/concurrent/Callable<",
|
|
"Lf/d/a/m<",
|
|
"Lf/d/a/d;",
|
|
">;>;"
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# instance fields
|
|
.field public final synthetic d:Landroid/content/Context;
|
|
|
|
.field public final synthetic e:Ljava/lang/String;
|
|
|
|
|
|
# direct methods
|
|
.method public constructor <init>(Landroid/content/Context;Ljava/lang/String;)V
|
|
.locals 0
|
|
|
|
iput-object p1, p0, Lf/d/a/e$c;->d:Landroid/content/Context;
|
|
|
|
iput-object p2, p0, Lf/d/a/e$c;->e:Ljava/lang/String;
|
|
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public call()Ljava/lang/Object;
|
|
.locals 10
|
|
.annotation system Ldalvik/annotation/Throws;
|
|
value = {
|
|
Ljava/lang/Exception;
|
|
}
|
|
.end annotation
|
|
|
|
iget-object v0, p0, Lf/d/a/e$c;->d:Landroid/content/Context;
|
|
|
|
iget-object v1, p0, Lf/d/a/e$c;->e:Ljava/lang/String;
|
|
|
|
new-instance v2, Lf/d/a/w/c;
|
|
|
|
invoke-direct {v2, v0, v1}, Lf/d/a/w/c;-><init>(Landroid/content/Context;Ljava/lang/String;)V
|
|
|
|
sget-object v0, Lf/d/a/w/a;->e:Lf/d/a/w/a;
|
|
|
|
iget-object v1, v2, Lf/d/a/w/c;->c:Lf/d/a/w/b;
|
|
|
|
const/4 v3, 0x0
|
|
|
|
if-eqz v1, :cond_8
|
|
|
|
sget-object v4, Lf/d/a/w/a;->d:Lf/d/a/w/a;
|
|
|
|
:try_start_0
|
|
iget-object v5, v1, Lf/d/a/w/b;->b:Ljava/lang/String;
|
|
|
|
new-instance v6, Ljava/io/File;
|
|
|
|
iget-object v7, v1, Lf/d/a/w/b;->a:Landroid/content/Context;
|
|
|
|
invoke-virtual {v7}, Landroid/content/Context;->getCacheDir()Ljava/io/File;
|
|
|
|
move-result-object v7
|
|
|
|
const/4 v8, 0x0
|
|
|
|
invoke-static {v5, v4, v8}, Lf/d/a/w/b;->a(Ljava/lang/String;Lf/d/a/w/a;Z)Ljava/lang/String;
|
|
|
|
move-result-object v9
|
|
|
|
invoke-direct {v6, v7, v9}, Ljava/io/File;-><init>(Ljava/io/File;Ljava/lang/String;)V
|
|
|
|
invoke-virtual {v6}, Ljava/io/File;->exists()Z
|
|
|
|
move-result v7
|
|
|
|
if-eqz v7, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
new-instance v6, Ljava/io/File;
|
|
|
|
iget-object v7, v1, Lf/d/a/w/b;->a:Landroid/content/Context;
|
|
|
|
invoke-virtual {v7}, Landroid/content/Context;->getCacheDir()Ljava/io/File;
|
|
|
|
move-result-object v7
|
|
|
|
invoke-static {v5, v0, v8}, Lf/d/a/w/b;->a(Ljava/lang/String;Lf/d/a/w/a;Z)Ljava/lang/String;
|
|
|
|
move-result-object v5
|
|
|
|
invoke-direct {v6, v7, v5}, Ljava/io/File;-><init>(Ljava/io/File;Ljava/lang/String;)V
|
|
|
|
invoke-virtual {v6}, Ljava/io/File;->exists()Z
|
|
|
|
move-result v5
|
|
|
|
if-eqz v5, :cond_1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_1
|
|
move-object v6, v3
|
|
|
|
:goto_0
|
|
if-nez v6, :cond_2
|
|
|
|
goto :goto_1
|
|
|
|
:cond_2
|
|
new-instance v5, Ljava/io/FileInputStream;
|
|
|
|
invoke-direct {v5, v6}, Ljava/io/FileInputStream;-><init>(Ljava/io/File;)V
|
|
:try_end_0
|
|
.catch Ljava/io/FileNotFoundException; {:try_start_0 .. :try_end_0} :catch_0
|
|
|
|
invoke-virtual {v6}, Ljava/io/File;->getAbsolutePath()Ljava/lang/String;
|
|
|
|
move-result-object v7
|
|
|
|
const-string v8, ".zip"
|
|
|
|
invoke-virtual {v7, v8}, Ljava/lang/String;->endsWith(Ljava/lang/String;)Z
|
|
|
|
move-result v7
|
|
|
|
if-eqz v7, :cond_3
|
|
|
|
move-object v4, v0
|
|
|
|
:cond_3
|
|
const-string v7, "Cache hit for "
|
|
|
|
invoke-static {v7}, Lf/e/b/a/a;->D(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
move-result-object v7
|
|
|
|
iget-object v1, v1, Lf/d/a/w/b;->b:Ljava/lang/String;
|
|
|
|
invoke-virtual {v7, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
const-string v1, " at "
|
|
|
|
invoke-virtual {v7, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
invoke-virtual {v6}, Ljava/io/File;->getAbsolutePath()Ljava/lang/String;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v7, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
invoke-virtual {v7}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-static {v1}, Lf/d/a/y/c;->a(Ljava/lang/String;)V
|
|
|
|
new-instance v1, Landroidx/core/util/Pair;
|
|
|
|
invoke-direct {v1, v4, v5}, Landroidx/core/util/Pair;-><init>(Ljava/lang/Object;Ljava/lang/Object;)V
|
|
|
|
goto :goto_2
|
|
|
|
:catch_0
|
|
:goto_1
|
|
move-object v1, v3
|
|
|
|
:goto_2
|
|
if-nez v1, :cond_4
|
|
|
|
goto :goto_4
|
|
|
|
:cond_4
|
|
iget-object v4, v1, Landroidx/core/util/Pair;->first:Ljava/lang/Object;
|
|
|
|
check-cast v4, Lf/d/a/w/a;
|
|
|
|
iget-object v1, v1, Landroidx/core/util/Pair;->second:Ljava/lang/Object;
|
|
|
|
check-cast v1, Ljava/io/InputStream;
|
|
|
|
if-ne v4, v0, :cond_5
|
|
|
|
new-instance v0, Ljava/util/zip/ZipInputStream;
|
|
|
|
invoke-direct {v0, v1}, Ljava/util/zip/ZipInputStream;-><init>(Ljava/io/InputStream;)V
|
|
|
|
iget-object v1, v2, Lf/d/a/w/c;->b:Ljava/lang/String;
|
|
|
|
invoke-static {v0, v1}, Lf/d/a/e;->g(Ljava/util/zip/ZipInputStream;Ljava/lang/String;)Lf/d/a/m;
|
|
|
|
move-result-object v0
|
|
|
|
goto :goto_3
|
|
|
|
:cond_5
|
|
iget-object v0, v2, Lf/d/a/w/c;->b:Ljava/lang/String;
|
|
|
|
invoke-static {v1, v0}, Lf/d/a/e;->c(Ljava/io/InputStream;Ljava/lang/String;)Lf/d/a/m;
|
|
|
|
move-result-object v0
|
|
|
|
:goto_3
|
|
iget-object v0, v0, Lf/d/a/m;->a:Ljava/lang/Object;
|
|
|
|
if-eqz v0, :cond_6
|
|
|
|
move-object v3, v0
|
|
|
|
check-cast v3, Lf/d/a/d;
|
|
|
|
:cond_6
|
|
:goto_4
|
|
if-eqz v3, :cond_7
|
|
|
|
new-instance v0, Lf/d/a/m;
|
|
|
|
invoke-direct {v0, v3}, Lf/d/a/m;-><init>(Ljava/lang/Object;)V
|
|
|
|
goto :goto_5
|
|
|
|
:cond_7
|
|
const-string v0, "Animation for "
|
|
|
|
invoke-static {v0}, Lf/e/b/a/a;->D(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
move-result-object v0
|
|
|
|
iget-object v1, v2, Lf/d/a/w/c;->b:Ljava/lang/String;
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
const-string v1, " not found in cache. Fetching from network."
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-static {v0}, Lf/d/a/y/c;->a(Ljava/lang/String;)V
|
|
|
|
:try_start_1
|
|
invoke-virtual {v2}, Lf/d/a/w/c;->a()Lf/d/a/m;
|
|
|
|
move-result-object v0
|
|
:try_end_1
|
|
.catch Ljava/io/IOException; {:try_start_1 .. :try_end_1} :catch_1
|
|
|
|
goto :goto_5
|
|
|
|
:catch_1
|
|
move-exception v0
|
|
|
|
new-instance v1, Lf/d/a/m;
|
|
|
|
invoke-direct {v1, v0}, Lf/d/a/m;-><init>(Ljava/lang/Throwable;)V
|
|
|
|
move-object v0, v1
|
|
|
|
:goto_5
|
|
return-object v0
|
|
|
|
:cond_8
|
|
throw v3
|
|
.end method
|