Rabbit-R1/android (non root)/smali/smali_classes2/com/airbnb/lottie/parser/DropShadowEffectParser.smali
2024-05-21 17:08:36 -04:00

396 lines
11 KiB
Smali

.class public Lcom/airbnb/lottie/parser/DropShadowEffectParser;
.super Ljava/lang/Object;
.source "DropShadowEffectParser.java"
# static fields
.field private static final DROP_SHADOW_EFFECT_NAMES:Lcom/airbnb/lottie/parser/moshi/JsonReader$Options;
.field private static final INNER_EFFECT_NAMES:Lcom/airbnb/lottie/parser/moshi/JsonReader$Options;
# instance fields
.field private color:Lcom/airbnb/lottie/model/animatable/AnimatableColorValue;
.field private direction:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
.field private distance:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
.field private opacity:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
.field private radius:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
# direct methods
.method static constructor <clinit>()V
.locals 2
const-string v0, "ef"
.line 14
filled-new-array {v0}, [Ljava/lang/String;
move-result-object v0
invoke-static {v0}, Lcom/airbnb/lottie/parser/moshi/JsonReader$Options;->of([Ljava/lang/String;)Lcom/airbnb/lottie/parser/moshi/JsonReader$Options;
move-result-object v0
sput-object v0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->DROP_SHADOW_EFFECT_NAMES:Lcom/airbnb/lottie/parser/moshi/JsonReader$Options;
const-string v0, "nm"
const-string v1, "v"
.line 17
filled-new-array {v0, v1}, [Ljava/lang/String;
move-result-object v0
invoke-static {v0}, Lcom/airbnb/lottie/parser/moshi/JsonReader$Options;->of([Ljava/lang/String;)Lcom/airbnb/lottie/parser/moshi/JsonReader$Options;
move-result-object v0
sput-object v0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->INNER_EFFECT_NAMES:Lcom/airbnb/lottie/parser/moshi/JsonReader$Options;
return-void
.end method
.method public constructor <init>()V
.locals 0
.line 12
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
return-void
.end method
.method private maybeParseInnerEffect(Lcom/airbnb/lottie/parser/moshi/JsonReader;Lcom/airbnb/lottie/LottieComposition;)V
.locals 5
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/io/IOException;
}
.end annotation
.line 52
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->beginObject()V
const-string v0, ""
.line 53
:goto_0
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->hasNext()Z
move-result v1
if-eqz v1, :cond_7
sget-object v1, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->INNER_EFFECT_NAMES:Lcom/airbnb/lottie/parser/moshi/JsonReader$Options;
.line 54
invoke-virtual {p1, v1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->selectName(Lcom/airbnb/lottie/parser/moshi/JsonReader$Options;)I
move-result v1
if-eqz v1, :cond_6
const/4 v2, 0x1
if-eq v1, v2, :cond_0
.line 81
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->skipName()V
.line 82
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->skipValue()V
goto :goto_0
.line 59
:cond_0
invoke-virtual {v0}, Ljava/lang/String;->hashCode()I
invoke-virtual {v0}, Ljava/lang/String;->hashCode()I
move-result v1
const/4 v3, 0x0
const/4 v4, -0x1
sparse-switch v1, :sswitch_data_0
:goto_1
move v2, v4
goto :goto_2
:sswitch_0
const-string v1, "Softness"
invoke-virtual {v0, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v1
if-nez v1, :cond_1
goto :goto_1
:cond_1
const/4 v2, 0x4
goto :goto_2
:sswitch_1
const-string v1, "Shadow Color"
invoke-virtual {v0, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v1
if-nez v1, :cond_2
goto :goto_1
:cond_2
const/4 v2, 0x3
goto :goto_2
:sswitch_2
const-string v1, "Direction"
invoke-virtual {v0, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v1
if-nez v1, :cond_3
goto :goto_1
:cond_3
const/4 v2, 0x2
goto :goto_2
:sswitch_3
const-string v1, "Opacity"
invoke-virtual {v0, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v1
if-nez v1, :cond_5
goto :goto_1
:sswitch_4
const-string v1, "Distance"
invoke-virtual {v0, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v1
if-nez v1, :cond_4
goto :goto_1
:cond_4
move v2, v3
:cond_5
:goto_2
packed-switch v2, :pswitch_data_0
.line 76
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->skipValue()V
goto :goto_0
.line 73
:pswitch_0
invoke-static {p1, p2}, Lcom/airbnb/lottie/parser/AnimatableValueParser;->parseFloat(Lcom/airbnb/lottie/parser/moshi/JsonReader;Lcom/airbnb/lottie/LottieComposition;)Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
move-result-object v1
iput-object v1, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->radius:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
goto :goto_0
.line 61
:pswitch_1
invoke-static {p1, p2}, Lcom/airbnb/lottie/parser/AnimatableValueParser;->parseColor(Lcom/airbnb/lottie/parser/moshi/JsonReader;Lcom/airbnb/lottie/LottieComposition;)Lcom/airbnb/lottie/model/animatable/AnimatableColorValue;
move-result-object v1
iput-object v1, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->color:Lcom/airbnb/lottie/model/animatable/AnimatableColorValue;
goto :goto_0
.line 67
:pswitch_2
invoke-static {p1, p2, v3}, Lcom/airbnb/lottie/parser/AnimatableValueParser;->parseFloat(Lcom/airbnb/lottie/parser/moshi/JsonReader;Lcom/airbnb/lottie/LottieComposition;Z)Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
move-result-object v1
iput-object v1, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->direction:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
goto :goto_0
.line 64
:pswitch_3
invoke-static {p1, p2, v3}, Lcom/airbnb/lottie/parser/AnimatableValueParser;->parseFloat(Lcom/airbnb/lottie/parser/moshi/JsonReader;Lcom/airbnb/lottie/LottieComposition;Z)Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
move-result-object v1
iput-object v1, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->opacity:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
goto :goto_0
.line 70
:pswitch_4
invoke-static {p1, p2}, Lcom/airbnb/lottie/parser/AnimatableValueParser;->parseFloat(Lcom/airbnb/lottie/parser/moshi/JsonReader;Lcom/airbnb/lottie/LottieComposition;)Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
move-result-object v1
iput-object v1, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->distance:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
goto/16 :goto_0
.line 56
:cond_6
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->nextString()Ljava/lang/String;
move-result-object v0
goto/16 :goto_0
.line 85
:cond_7
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->endObject()V
return-void
:sswitch_data_0
.sparse-switch
0x150bf015 -> :sswitch_4
0x17b08feb -> :sswitch_3
0x3e12275f -> :sswitch_2
0x5237c863 -> :sswitch_1
0x5279bda1 -> :sswitch_0
.end sparse-switch
:pswitch_data_0
.packed-switch 0x0
:pswitch_4
:pswitch_3
:pswitch_2
:pswitch_1
:pswitch_0
.end packed-switch
.end method
# virtual methods
.method parse(Lcom/airbnb/lottie/parser/moshi/JsonReader;Lcom/airbnb/lottie/LottieComposition;)Lcom/airbnb/lottie/parser/DropShadowEffect;
.locals 6
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/io/IOException;
}
.end annotation
.line 30
:goto_0
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->hasNext()Z
move-result v0
if-eqz v0, :cond_2
sget-object v0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->DROP_SHADOW_EFFECT_NAMES:Lcom/airbnb/lottie/parser/moshi/JsonReader$Options;
.line 31
invoke-virtual {p1, v0}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->selectName(Lcom/airbnb/lottie/parser/moshi/JsonReader$Options;)I
move-result v0
if-eqz v0, :cond_0
.line 40
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->skipName()V
.line 41
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->skipValue()V
goto :goto_0
.line 33
:cond_0
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->beginArray()V
.line 34
:goto_1
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->hasNext()Z
move-result v0
if-eqz v0, :cond_1
.line 35
invoke-direct {p0, p1, p2}, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->maybeParseInnerEffect(Lcom/airbnb/lottie/parser/moshi/JsonReader;Lcom/airbnb/lottie/LottieComposition;)V
goto :goto_1
.line 37
:cond_1
invoke-virtual {p1}, Lcom/airbnb/lottie/parser/moshi/JsonReader;->endArray()V
goto :goto_0
:cond_2
iget-object p1, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->color:Lcom/airbnb/lottie/model/animatable/AnimatableColorValue;
if-eqz p1, :cond_3
iget-object p1, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->opacity:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
if-eqz p1, :cond_3
iget-object p1, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->direction:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
if-eqz p1, :cond_3
iget-object p1, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->distance:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
if-eqz p1, :cond_3
iget-object p1, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->radius:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
if-eqz p1, :cond_3
.line 45
new-instance p1, Lcom/airbnb/lottie/parser/DropShadowEffect;
iget-object v1, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->color:Lcom/airbnb/lottie/model/animatable/AnimatableColorValue;
iget-object v2, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->opacity:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
iget-object v3, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->direction:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
iget-object v4, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->distance:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
iget-object v5, p0, Lcom/airbnb/lottie/parser/DropShadowEffectParser;->radius:Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;
move-object v0, p1
invoke-direct/range {v0 .. v5}, Lcom/airbnb/lottie/parser/DropShadowEffect;-><init>(Lcom/airbnb/lottie/model/animatable/AnimatableColorValue;Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;Lcom/airbnb/lottie/model/animatable/AnimatableFloatValue;)V
return-object p1
:cond_3
const/4 p0, 0x0
return-object p0
.end method