LottieAnimationTextView.smali

.class public Lcom/lottie/LottieAnimationTextView;
.super Landroid/widget/TextView;
.source "LottieAnimationTextView.java"


# static fields
.field private static final btF:Ljava/util/Map;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Ljava/util/Map",
            "<",
            "Ljava/lang/String;",
            "Lcom/lottie/bk;",
            ">;"
        }
    .end annotation
.end field

.field private static final btG:Ljava/util/Map;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Ljava/util/Map",
            "<",
            "Ljava/lang/String;",
            "Ljava/lang/ref/WeakReference",
            "<",
            "Lcom/lottie/bk;",
            ">;>;"
        }
    .end annotation
.end field


# instance fields
.field private brC:Lcom/lottie/bk;

.field private final brT:Lcom/lottie/bm;

.field btH:Landroid/graphics/Matrix;

.field private btI:Lcom/lottie/LottieAnimationTextView$CacheStrategy;

.field private btJ:Ljava/lang/String;

.field private btK:Lcom/lottie/af;

.field private btL:Landroid/graphics/BitmapShader;

.field private btM:Landroid/graphics/Canvas;

.field private mBitmap:Landroid/graphics/Bitmap;


# direct methods
.method static constructor <clinit>()V
    .registers 1

    .prologue
    .line 50
    const-class v0, Lcom/lottie/LottieAnimationTextView;

    invoke-virtual {v0}, Ljava/lang/Class;->getSimpleName()Ljava/lang/String;

    .line 62
    new-instance v0, Ljava/util/HashMap;

    invoke-direct {v0}, Ljava/util/HashMap;-><init>()V

    sput-object v0, Lcom/lottie/LottieAnimationTextView;->btF:Ljava/util/Map;

    .line 63
    new-instance v0, Ljava/util/HashMap;

    invoke-direct {v0}, Ljava/util/HashMap;-><init>()V

    sput-object v0, Lcom/lottie/LottieAnimationTextView;->btG:Ljava/util/Map;

    return-void
.end method

.method public constructor <init>(Landroid/content/Context;)V
    .registers 4
    .annotation build Landroid/support/annotation/Keep;
    .end annotation

    .prologue
    const/4 v1, 0x0

    .line 90
    invoke-direct {p0, p1}, Landroid/widget/TextView;-><init>(Landroid/content/Context;)V

    .line 66
    new-instance v0, Lcom/lottie/LottieAnimationTextView$1;

    invoke-direct {v0, p0}, Lcom/lottie/LottieAnimationTextView$1;-><init>(Lcom/lottie/LottieAnimationTextView;)V

    .line 75
    new-instance v0, Lcom/lottie/bm;

    invoke-direct {v0}, Lcom/lottie/bm;-><init>()V

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    .line 76
    new-instance v0, Landroid/graphics/Matrix;

    invoke-direct {v0}, Landroid/graphics/Matrix;-><init>()V

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btH:Landroid/graphics/Matrix;

    .line 185
    iput-object v1, p0, Lcom/lottie/LottieAnimationTextView;->mBitmap:Landroid/graphics/Bitmap;

    .line 186
    iput-object v1, p0, Lcom/lottie/LottieAnimationTextView;->btL:Landroid/graphics/BitmapShader;

    .line 187
    new-instance v0, Landroid/graphics/Canvas;

    invoke-direct {v0}, Landroid/graphics/Canvas;-><init>()V

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btM:Landroid/graphics/Canvas;

    .line 91
    invoke-direct {p0, v1}, Lcom/lottie/LottieAnimationTextView;->a(Landroid/util/AttributeSet;)V

    .line 92
    return-void
.end method

.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;)V
    .registers 5

    .prologue
    const/4 v1, 0x0

    .line 95
    invoke-direct {p0, p1, p2}, Landroid/widget/TextView;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;)V

    .line 66
    new-instance v0, Lcom/lottie/LottieAnimationTextView$1;

    invoke-direct {v0, p0}, Lcom/lottie/LottieAnimationTextView$1;-><init>(Lcom/lottie/LottieAnimationTextView;)V

    .line 75
    new-instance v0, Lcom/lottie/bm;

    invoke-direct {v0}, Lcom/lottie/bm;-><init>()V

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    .line 76
    new-instance v0, Landroid/graphics/Matrix;

    invoke-direct {v0}, Landroid/graphics/Matrix;-><init>()V

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btH:Landroid/graphics/Matrix;

    .line 185
    iput-object v1, p0, Lcom/lottie/LottieAnimationTextView;->mBitmap:Landroid/graphics/Bitmap;

    .line 186
    iput-object v1, p0, Lcom/lottie/LottieAnimationTextView;->btL:Landroid/graphics/BitmapShader;

    .line 187
    new-instance v0, Landroid/graphics/Canvas;

    invoke-direct {v0}, Landroid/graphics/Canvas;-><init>()V

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btM:Landroid/graphics/Canvas;

    .line 96
    invoke-direct {p0, p2}, Lcom/lottie/LottieAnimationTextView;->a(Landroid/util/AttributeSet;)V

    .line 97
    return-void
.end method

.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V
    .registers 6

    .prologue
    const/4 v1, 0x0

    .line 100
    invoke-direct {p0, p1, p2, p3}, Landroid/widget/TextView;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V

    .line 66
    new-instance v0, Lcom/lottie/LottieAnimationTextView$1;

    invoke-direct {v0, p0}, Lcom/lottie/LottieAnimationTextView$1;-><init>(Lcom/lottie/LottieAnimationTextView;)V

    .line 75
    new-instance v0, Lcom/lottie/bm;

    invoke-direct {v0}, Lcom/lottie/bm;-><init>()V

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    .line 76
    new-instance v0, Landroid/graphics/Matrix;

    invoke-direct {v0}, Landroid/graphics/Matrix;-><init>()V

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btH:Landroid/graphics/Matrix;

    .line 185
    iput-object v1, p0, Lcom/lottie/LottieAnimationTextView;->mBitmap:Landroid/graphics/Bitmap;

    .line 186
    iput-object v1, p0, Lcom/lottie/LottieAnimationTextView;->btL:Landroid/graphics/BitmapShader;

    .line 187
    new-instance v0, Landroid/graphics/Canvas;

    invoke-direct {v0}, Landroid/graphics/Canvas;-><init>()V

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btM:Landroid/graphics/Canvas;

    .line 101
    invoke-direct {p0, p2}, Lcom/lottie/LottieAnimationTextView;->a(Landroid/util/AttributeSet;)V

    .line 102
    return-void
.end method

.method static synthetic Gw()Ljava/util/Map;
    .registers 1

    .prologue
    .line 49
    sget-object v0, Lcom/lottie/LottieAnimationTextView;->btF:Ljava/util/Map;

    return-object v0
.end method

.method static synthetic Gx()Ljava/util/Map;
    .registers 1

    .prologue
    .line 49
    sget-object v0, Lcom/lottie/LottieAnimationTextView;->btG:Ljava/util/Map;

    return-object v0
.end method

.method static synthetic a(Lcom/lottie/LottieAnimationTextView;)Lcom/lottie/af;
    .registers 2

    .prologue
    .line 49
    const/4 v0, 0x0

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btK:Lcom/lottie/af;

    return-object v0
.end method

.method private a(Landroid/util/AttributeSet;)V
    .registers 8

    .prologue
    const/4 v5, 0x1

    const/4 v4, 0x0

    const/4 v3, 0x0

    .line 105
    invoke-virtual {p0}, Lcom/lottie/LottieAnimationTextView;->getContext()Landroid/content/Context;

    move-result-object v0

    sget-object v1, Lcom/lottie/cb;->LottieAnimationTextView:[I

    invoke-virtual {v0, p1, v1}, Landroid/content/Context;->obtainStyledAttributes(Landroid/util/AttributeSet;[I)Landroid/content/res/TypedArray;

    move-result-object v0

    .line 106
    sget v1, Lcom/lottie/cb;->LottieAnimationTextView_lottie_txt_fileName:I

    invoke-virtual {v0, v1}, Landroid/content/res/TypedArray;->getString(I)Ljava/lang/String;

    move-result-object v1

    .line 107
    invoke-virtual {p0}, Lcom/lottie/LottieAnimationTextView;->isInEditMode()Z

    move-result v2

    if-nez v2, :cond_1e

    if-eqz v1, :cond_1e

    .line 108
    invoke-direct {p0, v1}, Lcom/lottie/LottieAnimationTextView;->fU(Ljava/lang/String;)V

    .line 111
    :cond_1e
    sget v1, Lcom/lottie/cb;->LottieAnimationTextView_lottie_txt_autoPlay:I

    invoke-virtual {v0, v1, v4}, Landroid/content/res/TypedArray;->getBoolean(IZ)Z

    move-result v1

    if-eqz v1, :cond_2b

    .line 113
    iget-object v1, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v1}, Lcom/lottie/bm;->Gy()V

    .line 116
    :cond_2b
    iget-object v1, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    sget v2, Lcom/lottie/cb;->LottieAnimationTextView_lottie_txt_loop:I

    invoke-virtual {v0, v2, v4}, Landroid/content/res/TypedArray;->getBoolean(IZ)Z

    move-result v2

    invoke-virtual {v1, v2}, Lcom/lottie/bm;->aZ(Z)V

    .line 117
    sget v1, Lcom/lottie/cb;->LottieAnimationTextView_lottie_txt_imageAssetsFolder:I

    invoke-virtual {v0, v1}, Landroid/content/res/TypedArray;->getString(I)Ljava/lang/String;

    move-result-object v1

    .line 1388
    iget-object v2, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    .line 2154
    iput-object v1, v2, Lcom/lottie/bm;->bup:Ljava/lang/String;

    .line 118
    sget v1, Lcom/lottie/cb;->LottieAnimationTextView_lottie_txt_progress:I

    invoke-virtual {v0, v1, v3}, Landroid/content/res/TypedArray;->getFloat(IF)F

    move-result v1

    invoke-direct {p0, v1}, Lcom/lottie/LottieAnimationTextView;->setProgress(F)V

    .line 119
    sget v1, Lcom/lottie/cb;->LottieAnimationTextView_lottie_txt_cacheStrategy:I

    sget-object v2, Lcom/lottie/LottieAnimationTextView$CacheStrategy;->None:Lcom/lottie/LottieAnimationTextView$CacheStrategy;

    .line 121
    invoke-virtual {v2}, Lcom/lottie/LottieAnimationTextView$CacheStrategy;->ordinal()I

    move-result v2

    .line 119
    invoke-virtual {v0, v1, v2}, Landroid/content/res/TypedArray;->getInt(II)I

    move-result v1

    .line 122
    invoke-static {}, Lcom/lottie/LottieAnimationTextView$CacheStrategy;->values()[Lcom/lottie/LottieAnimationTextView$CacheStrategy;

    move-result-object v2

    aget-object v1, v2, v1

    iput-object v1, p0, Lcom/lottie/LottieAnimationTextView;->btI:Lcom/lottie/LottieAnimationTextView$CacheStrategy;

    .line 123
    invoke-virtual {v0}, Landroid/content/res/TypedArray;->recycle()V

    .line 124
    const/4 v0, 0x0

    invoke-virtual {p0, v5, v0}, Lcom/lottie/LottieAnimationTextView;->setLayerType(ILandroid/graphics/Paint;)V

    .line 126
    sget v0, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v1, 0x11

    if-lt v0, v1, :cond_82

    .line 127
    invoke-virtual {p0}, Lcom/lottie/LottieAnimationTextView;->getContext()Landroid/content/Context;

    move-result-object v0

    invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

    move-result-object v0

    const-string v1, "animator_duration_scale"

    const/high16 v2, 0x3f800000    # 1.0f

    invoke-static {v0, v1, v2}, Landroid/provider/Settings$Global;->getFloat(Landroid/content/ContentResolver;Ljava/lang/String;F)F

    move-result v0

    .line 129
    cmpl-float v0, v0, v3

    if-nez v0, :cond_82

    .line 130
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    .line 2329
    iput-boolean v5, v0, Lcom/lottie/bm;->bus:Z

    .line 133
    :cond_82
    return-void
.end method

.method static synthetic b(Lcom/lottie/LottieAnimationTextView;)Lcom/lottie/bk;
    .registers 2

    .prologue
    .line 49
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brC:Lcom/lottie/bk;

    return-object v0
.end method

.method private fU(Ljava/lang/String;)V
    .registers 5

    .prologue
    .line 239
    iget-object v1, p0, Lcom/lottie/LottieAnimationTextView;->btI:Lcom/lottie/LottieAnimationTextView$CacheStrategy;

    .line 5252
    iput-object p1, p0, Lcom/lottie/LottieAnimationTextView;->btJ:Ljava/lang/String;

    .line 5253
    sget-object v0, Lcom/lottie/LottieAnimationTextView;->btG:Ljava/util/Map;

    invoke-interface {v0, p1}, Ljava/util/Map;->containsKey(Ljava/lang/Object;)Z

    move-result v0

    if-eqz v0, :cond_24

    .line 5254
    sget-object v0, Lcom/lottie/LottieAnimationTextView;->btG:Ljava/util/Map;

    invoke-interface {v0, p1}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Ljava/lang/ref/WeakReference;

    .line 5255
    invoke-virtual {v0}, Ljava/lang/ref/WeakReference;->get()Ljava/lang/Object;

    move-result-object v2

    if-eqz v2, :cond_38

    .line 5256
    invoke-virtual {v0}, Ljava/lang/ref/WeakReference;->get()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/lottie/bk;

    invoke-virtual {p0, v0}, Lcom/lottie/LottieAnimationTextView;->c(Lcom/lottie/bk;)V

    .line 5261
    :goto_23
    return-void

    .line 5259
    :cond_24
    sget-object v0, Lcom/lottie/LottieAnimationTextView;->btF:Ljava/util/Map;

    invoke-interface {v0, p1}, Ljava/util/Map;->containsKey(Ljava/lang/Object;)Z

    move-result v0

    if-eqz v0, :cond_38

    .line 5260
    sget-object v0, Lcom/lottie/LottieAnimationTextView;->btF:Ljava/util/Map;

    invoke-interface {v0, p1}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/lottie/bk;

    invoke-virtual {p0, v0}, Lcom/lottie/LottieAnimationTextView;->c(Lcom/lottie/bk;)V

    goto :goto_23

    .line 5264
    :cond_38
    iput-object p1, p0, Lcom/lottie/LottieAnimationTextView;->btJ:Ljava/lang/String;

    .line 5265
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0}, Lcom/lottie/bm;->Gz()V

    .line 5295
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btK:Lcom/lottie/af;

    if-eqz v0, :cond_4b

    .line 5296
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btK:Lcom/lottie/af;

    invoke-interface {v0}, Lcom/lottie/af;->cancel()V

    .line 5297
    const/4 v0, 0x0

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btK:Lcom/lottie/af;

    .line 5267
    :cond_4b
    invoke-virtual {p0}, Lcom/lottie/LottieAnimationTextView;->getContext()Landroid/content/Context;

    move-result-object v0

    new-instance v2, Lcom/lottie/LottieAnimationTextView$2;

    invoke-direct {v2, p0, v1, p1}, Lcom/lottie/LottieAnimationTextView$2;-><init>(Lcom/lottie/LottieAnimationTextView;Lcom/lottie/LottieAnimationTextView$CacheStrategy;Ljava/lang/String;)V

    invoke-static {v0, p1, v2}, Lcom/lottie/bl;->a(Landroid/content/Context;Ljava/lang/String;Lcom/lottie/bt;)Lcom/lottie/af;

    move-result-object v0

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btK:Lcom/lottie/af;

    goto :goto_23
.end method

.method private setProgress(F)V
    .registers 3

    .prologue
    .line 463
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0, p1}, Lcom/lottie/bm;->setProgress(F)V

    .line 464
    return-void
.end method


# virtual methods
.method final Gv()V
    .registers 3

    .prologue
    .line 358
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {p0}, Lcom/lottie/LottieAnimationTextView;->getDrawableState()[I

    move-result-object v1

    invoke-virtual {v0, v1}, Lcom/lottie/bm;->setState([I)Z

    .line 359
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0}, Lcom/lottie/bm;->isStateful()Z

    move-result v0

    if-eqz v0, :cond_1f

    .line 360
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {p0}, Lcom/lottie/LottieAnimationTextView;->getDrawableState()[I

    move-result-object v1

    invoke-virtual {v0, v1}, Lcom/lottie/bm;->setState([I)Z

    .line 361
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0}, Lcom/lottie/bm;->jumpToCurrentState()V

    .line 363
    :cond_1f
    return-void
.end method

.method public final c(Lcom/lottie/bk;)V
    .registers 4

    .prologue
    .line 310
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0, p0}, Lcom/lottie/bm;->setCallback(Landroid/graphics/drawable/Drawable$Callback;)V

    .line 312
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0, p1}, Lcom/lottie/bm;->d(Lcom/lottie/bk;)Z

    move-result v0

    .line 313
    if-nez v0, :cond_e

    .line 325
    :goto_d
    return-void

    .line 5333
    :cond_e
    invoke-virtual {p0}, Lcom/lottie/LottieAnimationTextView;->getViewTreeObserver()Landroid/view/ViewTreeObserver;

    move-result-object v0

    new-instance v1, Lcom/lottie/LottieAnimationTextView$3;

    invoke-direct {v1, p0}, Lcom/lottie/LottieAnimationTextView$3;-><init>(Lcom/lottie/LottieAnimationTextView;)V

    invoke-virtual {v0, v1}, Landroid/view/ViewTreeObserver;->addOnPreDrawListener(Landroid/view/ViewTreeObserver$OnPreDrawListener;)V

    .line 320
    invoke-virtual {p0}, Lcom/lottie/LottieAnimationTextView;->Gv()V

    .line 322
    iput-object p1, p0, Lcom/lottie/LottieAnimationTextView;->brC:Lcom/lottie/bk;

    .line 324
    invoke-virtual {p0}, Lcom/lottie/LottieAnimationTextView;->requestLayout()V

    goto :goto_d
.end method

.method public draw(Landroid/graphics/Canvas;)V
    .registers 2

    .prologue
    .line 329
    invoke-super {p0, p1}, Landroid/widget/TextView;->draw(Landroid/graphics/Canvas;)V

    .line 330
    return-void
.end method

.method public invalidateDrawable(Landroid/graphics/drawable/Drawable;)V
    .registers 3

    .prologue
    .line 137
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    if-ne p1, v0, :cond_8

    .line 138
    invoke-virtual {p0}, Lcom/lottie/LottieAnimationTextView;->invalidate()V

    .line 142
    :goto_7
    return-void

    .line 140
    :cond_8
    invoke-super {p0, p1}, Landroid/widget/TextView;->invalidateDrawable(Landroid/graphics/drawable/Drawable;)V

    goto :goto_7
.end method

.method protected onDetachedFromWindow()V
    .registers 2

    .prologue
    .line 223
    .line 5229
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0}, Lcom/lottie/bm;->Gr()V

    .line 224
    invoke-super {p0}, Landroid/widget/TextView;->onDetachedFromWindow()V

    .line 225
    return-void
.end method

.method protected onDraw(Landroid/graphics/Canvas;)V
    .registers 8

    .prologue
    const/4 v5, 0x0

    const/4 v4, 0x0

    .line 147
    .line 3156
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    .line 3341
    iget-object v0, v0, Lcom/lottie/bm;->bul:Landroid/animation/ValueAnimator;

    invoke-virtual {v0}, Landroid/animation/ValueAnimator;->isRunning()Z

    move-result v0

    .line 3156
    if-eqz v0, :cond_7f

    .line 3160
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0}, Lcom/lottie/bm;->getIntrinsicHeight()I

    move-result v0

    if-gtz v0, :cond_1c

    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    .line 3161
    invoke-virtual {v0}, Lcom/lottie/bm;->getIntrinsicWidth()I

    move-result v0

    if-lez v0, :cond_7f

    .line 3165
    :cond_1c
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->mBitmap:Landroid/graphics/Bitmap;

    if-eqz v0, :cond_27

    .line 3166
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->mBitmap:Landroid/graphics/Bitmap;

    invoke-virtual {v0}, Landroid/graphics/Bitmap;->recycle()V

    .line 3167
    iput-object v5, p0, Lcom/lottie/LottieAnimationTextView;->mBitmap:Landroid/graphics/Bitmap;

    .line 3169
    :cond_27
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0}, Lcom/lottie/bm;->getIntrinsicWidth()I

    move-result v1

    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0}, Lcom/lottie/bm;->getIntrinsicHeight()I

    move-result v2

    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    .line 3170
    invoke-virtual {v0}, Lcom/lottie/bm;->getOpacity()I

    move-result v0

    const/4 v3, -0x1

    if-eq v0, v3, :cond_83

    sget-object v0, Landroid/graphics/Bitmap$Config;->ARGB_8888:Landroid/graphics/Bitmap$Config;

    .line 3169
    :goto_3e
    invoke-static {v1, v2, v0}, Landroid/graphics/Bitmap;->createBitmap(IILandroid/graphics/Bitmap$Config;)Landroid/graphics/Bitmap;

    move-result-object v0

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->mBitmap:Landroid/graphics/Bitmap;

    .line 3171
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btM:Landroid/graphics/Canvas;

    iget-object v1, p0, Lcom/lottie/LottieAnimationTextView;->mBitmap:Landroid/graphics/Bitmap;

    invoke-virtual {v0, v1}, Landroid/graphics/Canvas;->setBitmap(Landroid/graphics/Bitmap;)V

    .line 3172
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    iget-object v1, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v1}, Lcom/lottie/bm;->getIntrinsicWidth()I

    move-result v1

    iget-object v2, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    .line 3173
    invoke-virtual {v2}, Lcom/lottie/bm;->getIntrinsicHeight()I

    move-result v2

    .line 3172
    invoke-virtual {v0, v4, v4, v1, v2}, Lcom/lottie/bm;->setBounds(IIII)V

    .line 3175
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    iget-object v1, p0, Lcom/lottie/LottieAnimationTextView;->btM:Landroid/graphics/Canvas;

    invoke-virtual {v0, v1}, Lcom/lottie/bm;->draw(Landroid/graphics/Canvas;)V

    .line 3177
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btL:Landroid/graphics/BitmapShader;

    if-eqz v0, :cond_69

    .line 3178
    iput-object v5, p0, Lcom/lottie/LottieAnimationTextView;->btL:Landroid/graphics/BitmapShader;

    .line 3180
    :cond_69
    new-instance v0, Landroid/graphics/BitmapShader;

    iget-object v1, p0, Lcom/lottie/LottieAnimationTextView;->mBitmap:Landroid/graphics/Bitmap;

    sget-object v2, Landroid/graphics/Shader$TileMode;->CLAMP:Landroid/graphics/Shader$TileMode;

    sget-object v3, Landroid/graphics/Shader$TileMode;->CLAMP:Landroid/graphics/Shader$TileMode;

    invoke-direct {v0, v1, v2, v3}, Landroid/graphics/BitmapShader;-><init>(Landroid/graphics/Bitmap;Landroid/graphics/Shader$TileMode;Landroid/graphics/Shader$TileMode;)V

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btL:Landroid/graphics/BitmapShader;

    .line 3182
    invoke-virtual {p0}, Lcom/lottie/LottieAnimationTextView;->getPaint()Landroid/text/TextPaint;

    move-result-object v0

    iget-object v1, p0, Lcom/lottie/LottieAnimationTextView;->btL:Landroid/graphics/BitmapShader;

    invoke-virtual {v0, v1}, Landroid/text/TextPaint;->setShader(Landroid/graphics/Shader;)Landroid/graphics/Shader;

    .line 148
    :cond_7f
    invoke-super {p0, p1}, Landroid/widget/TextView;->onDraw(Landroid/graphics/Canvas;)V

    .line 149
    return-void

    .line 3170
    :cond_83
    sget-object v0, Landroid/graphics/Bitmap$Config;->RGB_565:Landroid/graphics/Bitmap$Config;

    goto :goto_3e
.end method

.method public onRestoreInstanceState(Landroid/os/Parcelable;)V
    .registers 4

    .prologue
    .line 203
    instance-of v0, p1, Lcom/lottie/LottieAnimationTextView$SavedState;

    if-nez v0, :cond_8

    .line 204
    invoke-super {p0, p1}, Landroid/widget/TextView;->onRestoreInstanceState(Landroid/os/Parcelable;)V

    .line 219
    :cond_7
    :goto_7
    return-void

    .line 208
    :cond_8
    check-cast p1, Lcom/lottie/LottieAnimationTextView$SavedState;

    .line 209
    invoke-virtual {p1}, Lcom/lottie/LottieAnimationTextView$SavedState;->getSuperState()Landroid/os/Parcelable;

    move-result-object v0

    invoke-super {p0, v0}, Landroid/widget/TextView;->onRestoreInstanceState(Landroid/os/Parcelable;)V

    .line 210
    iget-object v0, p1, Lcom/lottie/LottieAnimationTextView$SavedState;->btJ:Ljava/lang/String;

    iput-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btJ:Ljava/lang/String;

    .line 211
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btJ:Ljava/lang/String;

    invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    if-nez v0, :cond_22

    .line 212
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btJ:Ljava/lang/String;

    invoke-direct {p0, v0}, Lcom/lottie/LottieAnimationTextView;->fU(Ljava/lang/String;)V

    .line 214
    :cond_22
    iget v0, p1, Lcom/lottie/LottieAnimationTextView$SavedState;->progress:F

    invoke-direct {p0, v0}, Lcom/lottie/LottieAnimationTextView;->setProgress(F)V

    .line 215
    iget-boolean v0, p1, Lcom/lottie/LottieAnimationTextView$SavedState;->btS:Z

    .line 4410
    iget-object v1, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v1, v0}, Lcom/lottie/bm;->aZ(Z)V

    .line 216
    iget-boolean v0, p1, Lcom/lottie/LottieAnimationTextView$SavedState;->btR:Z

    if-eqz v0, :cond_7

    .line 4418
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0}, Lcom/lottie/bm;->Gy()V

    goto :goto_7
.end method

.method public onSaveInstanceState()Landroid/os/Parcelable;
    .registers 3

    .prologue
    .line 192
    invoke-super {p0}, Landroid/widget/TextView;->onSaveInstanceState()Landroid/os/Parcelable;

    move-result-object v0

    .line 193
    new-instance v1, Lcom/lottie/LottieAnimationTextView$SavedState;

    invoke-direct {v1, v0}, Lcom/lottie/LottieAnimationTextView$SavedState;-><init>(Landroid/os/Parcelable;)V

    .line 194
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->btJ:Ljava/lang/String;

    iput-object v0, v1, Lcom/lottie/LottieAnimationTextView$SavedState;->btJ:Ljava/lang/String;

    .line 195
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0}, Lcom/lottie/bm;->getProgress()F

    move-result v0

    iput v0, v1, Lcom/lottie/LottieAnimationTextView$SavedState;->progress:F

    .line 196
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    .line 4341
    iget-object v0, v0, Lcom/lottie/bm;->bul:Landroid/animation/ValueAnimator;

    invoke-virtual {v0}, Landroid/animation/ValueAnimator;->isRunning()Z

    move-result v0

    .line 196
    iput-boolean v0, v1, Lcom/lottie/LottieAnimationTextView$SavedState;->btR:Z

    .line 197
    iget-object v0, p0, Lcom/lottie/LottieAnimationTextView;->brT:Lcom/lottie/bm;

    invoke-virtual {v0}, Lcom/lottie/bm;->isLooping()Z

    move-result v0

    iput-boolean v0, v1, Lcom/lottie/LottieAnimationTextView$SavedState;->btS:Z

    .line 198
    return-object v1
.end method