.class Lcom/moji/appwidget/core/WidgetWeatherObserver$DelayHandler;
.super Landroid/os/Handler;
.source "WidgetWeatherObserver.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/moji/appwidget/core/WidgetWeatherObserver;
.end annotation

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


# instance fields
.field final synthetic a:Lcom/moji/appwidget/core/WidgetWeatherObserver;


# direct methods
.method public constructor <init>(Lcom/moji/appwidget/core/WidgetWeatherObserver;Landroid/os/Looper;)V
    .locals 0

    .line 51
    iput-object p1, p0, Lcom/moji/appwidget/core/WidgetWeatherObserver$DelayHandler;->a:Lcom/moji/appwidget/core/WidgetWeatherObserver;

    .line 52
    invoke-direct {p0, p2}, Landroid/os/Handler;-><init>(Landroid/os/Looper;)V

    return-void
.end method


# virtual methods
.method public dispatchMessage(Landroid/os/Message;)V
    .locals 3

    .line 57
    invoke-super {p0, p1}, Landroid/os/Handler;->dispatchMessage(Landroid/os/Message;)V

    .line 58
    iget v0, p1, Landroid/os/Message;->what:I

    const/16 v1, 0xb

    if-eq v0, v1, :cond_0

    goto :goto_0

    .line 61
    :cond_0
    :try_start_0
    iget-object p1, p1, Landroid/os/Message;->obj:Ljava/lang/Object;

    check-cast p1, Landroid/net/Uri;

    if-eqz p1, :cond_2

    .line 63
    invoke-virtual {p1}, Landroid/net/Uri;->getPathSegments()Ljava/util/List;

    move-result-object v0

    if-eqz v0, :cond_2

    .line 64
    invoke-interface {v0}, Ljava/util/List;->size()I

    move-result v0

    const/4 v1, 0x1

    if-le v0, v1, :cond_2

    .line 65
    invoke-virtual {p1}, Landroid/net/Uri;->getPathSegments()Ljava/util/List;

    move-result-object p1

    invoke-interface {p1, v1}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object p1

    check-cast p1, Ljava/lang/String;

    invoke-static {p1}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I

    move-result p1

    .line 66
    invoke-static {}, Lcom/moji/areamanagement/MJAreaManager;->a()Lcom/moji/common/area/AreaInfo;

    move-result-object v0

    if-eqz v0, :cond_2

    .line 67
    iget v2, v0, Lcom/moji/common/area/AreaInfo;->cityId:I

    if-eq p1, v2, :cond_1

    iget-boolean v0, v0, Lcom/moji/common/area/AreaInfo;->isLocation:Z

    if-eqz v0, :cond_2

    const/4 v0, -0x1

    invoke-static {v0, v1}, Lcom/moji/common/area/AreaInfo;->getCacheKey(IZ)I

    move-result v0

    if-ne p1, v0, :cond_2

    .line 68
    :cond_1
    invoke-static {}, Lcom/moji/appwidget/core/MJWidgetManager;->a()Lcom/moji/appwidget/core/MJWidgetManager;

    move-result-object p1

    invoke-static {}, Lcom/moji/tool/AppDelegate;->a()Landroid/content/Context;

    move-result-object v0

    sget-object v1, Lcom/moji/appwidget/core/ELayer;->FACE:Lcom/moji/appwidget/core/ELayer;

    const/4 v2, 0x0

    new-array v2, v2, [Lcom/moji/appwidget/core/EWidgetSize;

    invoke-virtual {p1, v0, v1, v2}, Lcom/moji/appwidget/core/MJWidgetManager;->a(Landroid/content/Context;Lcom/moji/appwidget/core/ELayer;[Lcom/moji/appwidget/core/EWidgetSize;)V

    .line 69
    iget-object p1, p0, Lcom/moji/appwidget/core/WidgetWeatherObserver$DelayHandler;->a:Lcom/moji/appwidget/core/WidgetWeatherObserver;

    invoke-virtual {p1}, Lcom/moji/appwidget/core/WidgetWeatherObserver;->a()V
    :try_end_0
    .catch Ljava/lang/NumberFormatException; {:try_start_0 .. :try_end_0} :catch_0

    goto :goto_0

    :catch_0
    move-exception p1

    const-string v0, "WidgetWeatherObserver"

    .line 74
    invoke-static {v0, p1}, Lcom/moji/tool/log/MJLogger;->a(Ljava/lang/String;Ljava/lang/Throwable;)V

    :cond_2
    :goto_0
    return-void
.end method
