.class Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;
.super Ljava/lang/Object;
.source "ShortTimeRainDropDrawView.java"

# interfaces
.implements Ljava/lang/Runnable;


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x2
    name = "CalculateRunnable"
.end annotation


# instance fields
.field final synthetic a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;


# direct methods
.method private constructor <init>(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)V
    .locals 0

    .line 232
    iput-object p1, p0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method

.method synthetic constructor <init>(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$1;)V
    .locals 0

    .line 232
    invoke-direct {p0, p1}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;-><init>(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)V

    return-void
.end method

.method private a(FFF)F
    .locals 1

    cmpg-float v0, p3, p1

    if-gez v0, :cond_0

    goto :goto_0

    :cond_0
    cmpl-float p1, p3, p2

    if-lez p1, :cond_1

    move p1, p2

    goto :goto_0

    :cond_1
    move p1, p3

    :goto_0
    return p1
.end method


# virtual methods
.method public run()V
    .locals 16

    move-object/from16 v0, p0

    .line 235
    iget-object v1, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v1}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->a(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)Landroid/graphics/Bitmap;

    move-result-object v1

    if-eqz v1, :cond_8

    iget-object v1, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v1}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->a(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)Landroid/graphics/Bitmap;

    move-result-object v1

    invoke-virtual {v1}, Landroid/graphics/Bitmap;->isRecycled()Z

    move-result v1

    if-nez v1, :cond_8

    .line 236
    iget-object v1, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v1}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->b(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)I

    move-result v1

    int-to-long v1, v1

    iget-object v3, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v3}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->c(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)J

    move-result-wide v3

    const/4 v5, 0x0

    cmp-long v6, v1, v3

    if-lez v6, :cond_0

    .line 237
    iget-object v1, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v1, v5}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->a(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;I)I

    .line 239
    :cond_0
    iget-object v1, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v1}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->d(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)I

    move-result v1

    int-to-float v1, v1

    iget-object v2, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v2}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->c(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)J

    move-result-wide v2

    long-to-float v2, v2

    div-float/2addr v1, v2

    const/high16 v2, 0x3f800000    # 1.0f

    const/4 v3, 0x0

    .line 240
    invoke-direct {v0, v3, v2, v1}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a(FFF)F

    move-result v1

    const/4 v4, 0x2

    .line 241
    new-array v4, v4, [F

    fill-array-data v4, :array_0

    .line 244
    iget-object v6, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v6}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->e(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)Z

    move-result v6

    const/high16 v7, 0x437f0000    # 255.0f

    if-nez v6, :cond_1

    sub-float v6, v2, v1

    mul-float v6, v6, v7

    float-to-int v6, v6

    const/4 v8, 0x0

    goto :goto_0

    :cond_1
    const/16 v6, 0xff

    const/high16 v8, 0x44340000    # 720.0f

    mul-float v8, v8, v1

    float-to-int v8, v8

    :goto_0
    move v10, v1

    const/4 v9, 0x0

    .line 252
    :goto_1
    iget-object v11, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v11}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->f(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)I

    move-result v11

    if-ge v9, v11, :cond_6

    .line 253
    iget-object v11, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v11}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->e(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)Z

    move-result v11

    if-eqz v11, :cond_2

    .line 254
    invoke-static {}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->b()[F

    move-result-object v10

    aget v10, v10, v9

    sub-float v10, v1, v10

    const v11, 0x3f15c28f    # 0.585f

    div-float/2addr v10, v11

    invoke-direct {v0, v3, v2, v10}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a(FFF)F

    move-result v10

    .line 256
    :cond_2
    iget-object v11, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v11}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->g(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)[Landroid/graphics/PathMeasure;

    move-result-object v11

    aget-object v11, v11, v9

    .line 257
    invoke-virtual {v11}, Landroid/graphics/PathMeasure;->getLength()F

    move-result v12

    mul-float v12, v12, v10

    const/4 v13, 0x0

    invoke-virtual {v11, v12, v4, v13}, Landroid/graphics/PathMeasure;->getPosTan(F[F[F)Z

    .line 258
    iget-object v11, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v11}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->h(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)[Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;

    move-result-object v11

    aget-object v11, v11, v9

    const/4 v12, 0x1

    if-nez v11, :cond_3

    .line 259
    new-instance v11, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;

    invoke-direct {v11, v13}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;-><init>(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$1;)V

    .line 260
    new-instance v13, Landroid/graphics/RectF;

    aget v14, v4, v5

    iget-object v15, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v15}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->i(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)I

    move-result v15

    int-to-float v15, v15

    sub-float/2addr v14, v15

    aget v15, v4, v12

    iget-object v7, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v7}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->i(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)I

    move-result v7

    int-to-float v7, v7

    sub-float/2addr v15, v7

    aget v7, v4, v5

    iget-object v2, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v2}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->i(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)I

    move-result v2

    int-to-float v2, v2

    add-float/2addr v7, v2

    aget v2, v4, v12

    iget-object v3, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v3}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->i(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)I

    move-result v3

    int-to-float v3, v3

    add-float/2addr v2, v3

    invoke-direct {v13, v14, v15, v7, v2}, Landroid/graphics/RectF;-><init>(FFFF)V

    invoke-static {v11, v13}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;->a(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;Landroid/graphics/RectF;)Landroid/graphics/RectF;

    .line 261
    invoke-static {v11, v6}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;->a(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;I)I

    .line 262
    invoke-static {v11, v8}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;->b(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;I)I

    .line 263
    iget-object v2, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v2}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->h(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)[Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;

    move-result-object v2

    aput-object v11, v2, v9

    goto :goto_2

    .line 265
    :cond_3
    iget-object v2, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v2}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->h(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)[Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;

    move-result-object v2

    aget-object v2, v2, v9

    invoke-static {v2}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;->c(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;)Landroid/graphics/RectF;

    move-result-object v2

    aget v3, v4, v5

    iget-object v7, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v7}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->i(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)I

    move-result v7

    int-to-float v7, v7

    sub-float/2addr v3, v7

    aget v7, v4, v12

    iget-object v11, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v11}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->i(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)I

    move-result v11

    int-to-float v11, v11

    sub-float/2addr v7, v11

    aget v11, v4, v5

    iget-object v13, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v13}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->i(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)I

    move-result v13

    int-to-float v13, v13

    add-float/2addr v11, v13

    aget v13, v4, v12

    iget-object v14, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v14}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->i(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)I

    move-result v14

    int-to-float v14, v14

    add-float/2addr v13, v14

    invoke-virtual {v2, v3, v7, v11, v13}, Landroid/graphics/RectF;->set(FFFF)V

    .line 266
    iget-object v2, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v2}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->h(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)[Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;

    move-result-object v2

    aget-object v2, v2, v9

    invoke-static {v2, v6}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;->a(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;I)I

    .line 267
    iget-object v2, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v2}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->h(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)[Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;

    move-result-object v2

    aget-object v2, v2, v9

    invoke-static {v2, v8}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;->b(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;I)I

    .line 270
    :goto_2
    iget-object v2, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v2}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->e(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)Z

    move-result v2

    if-eqz v2, :cond_5

    .line 271
    aget v2, v4, v12

    iget-object v3, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v3}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->i(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)I

    move-result v3

    int-to-float v3, v3

    sub-float/2addr v2, v3

    iget-object v3, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-virtual {v3}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->getHeight()I

    move-result v3

    int-to-float v3, v3

    div-float v3, v2, v3

    const/4 v2, 0x0

    cmpg-float v7, v3, v2

    if-gez v7, :cond_4

    const/4 v3, 0x0

    .line 275
    :cond_4
    iget-object v7, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-static {v7}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->h(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;)[Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;

    move-result-object v7

    aget-object v7, v7, v9

    const/high16 v11, 0x3f800000    # 1.0f

    sub-float v3, v11, v3

    const/high16 v12, 0x437f0000    # 255.0f

    mul-float v3, v3, v12

    float-to-int v3, v3

    invoke-static {v7, v3}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;->a(Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$DrawingRect;I)I

    goto :goto_3

    :cond_5
    const/4 v2, 0x0

    const/high16 v11, 0x3f800000    # 1.0f

    const/high16 v12, 0x437f0000    # 255.0f

    :goto_3
    add-int/lit8 v9, v9, 0x1

    const/high16 v2, 0x3f800000    # 1.0f

    const/4 v3, 0x0

    const/high16 v7, 0x437f0000    # 255.0f

    goto/16 :goto_1

    .line 279
    :cond_6
    sget v1, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v2, 0x10

    if-lt v1, v2, :cond_7

    .line 280
    iget-object v1, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-virtual {v1}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->postInvalidateOnAnimation()V

    goto :goto_4

    .line 282
    :cond_7
    iget-object v1, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    invoke-virtual {v1}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->postInvalidate()V

    .line 284
    :goto_4
    iget-object v1, v0, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView$CalculateRunnable;->a:Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;

    const-wide/16 v2, 0x28

    invoke-virtual {v1, v0, v2, v3}, Lcom/moji/mjweather/shorttime/view/ShortTimeRainDropDrawView;->postDelayed(Ljava/lang/Runnable;J)Z

    :cond_8
    return-void

    :array_0
    .array-data 4
        0x0
        0x0
    .end array-data
.end method
