.class public Lcom/moji/mjweather/scenestore/SceneEditAdapter$EditUnUsingClickListener;
.super Ljava/lang/Object;
.source "SceneEditAdapter.java"

# interfaces
.implements Landroid/view/View$OnClickListener;


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/moji/mjweather/scenestore/SceneEditAdapter;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x1
    name = "EditUnUsingClickListener"
.end annotation


# instance fields
.field final synthetic a:Lcom/moji/mjweather/scenestore/SceneEditAdapter;

.field private final b:Lcom/moji/http/scenestore/SceneList$List$ChildList;

.field private final c:Z


# direct methods
.method private constructor <init>(Lcom/moji/mjweather/scenestore/SceneEditAdapter;Lcom/moji/http/scenestore/SceneList$List$ChildList;Z)V
    .locals 0

    .line 163
    iput-object p1, p0, Lcom/moji/mjweather/scenestore/SceneEditAdapter$EditUnUsingClickListener;->a:Lcom/moji/mjweather/scenestore/SceneEditAdapter;

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

    .line 164
    iput-object p2, p0, Lcom/moji/mjweather/scenestore/SceneEditAdapter$EditUnUsingClickListener;->b:Lcom/moji/http/scenestore/SceneList$List$ChildList;

    .line 165
    iput-boolean p3, p0, Lcom/moji/mjweather/scenestore/SceneEditAdapter$EditUnUsingClickListener;->c:Z

    return-void
.end method

.method synthetic constructor <init>(Lcom/moji/mjweather/scenestore/SceneEditAdapter;Lcom/moji/http/scenestore/SceneList$List$ChildList;ZLcom/moji/mjweather/scenestore/SceneEditAdapter$1;)V
    .locals 0

    .line 159
    invoke-direct {p0, p1, p2, p3}, Lcom/moji/mjweather/scenestore/SceneEditAdapter$EditUnUsingClickListener;-><init>(Lcom/moji/mjweather/scenestore/SceneEditAdapter;Lcom/moji/http/scenestore/SceneList$List$ChildList;Z)V

    return-void
.end method


# virtual methods
.method public onClick(Landroid/view/View;)V
    .locals 2

    .line 171
    iget-boolean v0, p0, Lcom/moji/mjweather/scenestore/SceneEditAdapter$EditUnUsingClickListener;->c:Z

    if-nez v0, :cond_3

    iget-object v0, p0, Lcom/moji/mjweather/scenestore/SceneEditAdapter$EditUnUsingClickListener;->b:Lcom/moji/http/scenestore/SceneList$List$ChildList;

    iget-boolean v0, v0, Lcom/moji/http/scenestore/SceneList$List$ChildList;->isUsing:Z

    if-eqz v0, :cond_0

    goto :goto_3

    .line 174
    :cond_0
    new-instance v0, Lcom/moji/mjweather/scenestore/model/FreeSceneManager;

    invoke-direct {v0}, Lcom/moji/mjweather/scenestore/model/FreeSceneManager;-><init>()V

    .line 175
    iget-object v1, p0, Lcom/moji/mjweather/scenestore/SceneEditAdapter$EditUnUsingClickListener;->b:Lcom/moji/http/scenestore/SceneList$List$ChildList;

    invoke-virtual {v0, v1}, Lcom/moji/mjweather/scenestore/model/FreeSceneManager;->a(Lcom/moji/http/scenestore/SceneList$List$ChildList;)Z

    move-result v1

    if-eqz v1, :cond_1

    .line 176
    invoke-virtual {p1}, Landroid/view/View;->getContext()Landroid/content/Context;

    move-result-object p1

    const v1, 0x7f0e075c

    invoke-virtual {v0, p1, v1}, Lcom/moji/mjweather/scenestore/model/FreeSceneManager;->a(Landroid/content/Context;I)V

    goto :goto_0

    .line 178
    :cond_1
    new-instance v0, Lcom/moji/mjweather/scenestore/model/SceneSwitchHelper;

    invoke-direct {v0}, Lcom/moji/mjweather/scenestore/model/SceneSwitchHelper;-><init>()V

    iget-object v1, p0, Lcom/moji/mjweather/scenestore/SceneEditAdapter$EditUnUsingClickListener;->b:Lcom/moji/http/scenestore/SceneList$List$ChildList;

    iget-object v1, v1, Lcom/moji/http/scenestore/SceneList$List$ChildList;->themeId:Ljava/lang/String;

    invoke-virtual {v0, v1}, Lcom/moji/mjweather/scenestore/model/SceneSwitchHelper;->a(Ljava/lang/String;)V

    .line 179
    new-instance v0, Lcom/moji/tipview/MJTipView$Builder;

    invoke-virtual {p1}, Landroid/view/View;->getContext()Landroid/content/Context;

    move-result-object p1

    invoke-direct {v0, p1}, Lcom/moji/tipview/MJTipView$Builder;-><init>(Landroid/content/Context;)V

    const p1, 0x7f0e0769

    invoke-virtual {v0, p1}, Lcom/moji/tipview/MJTipView$Builder;->a(I)Lcom/moji/tipview/MJTipView$Builder;

    move-result-object p1

    invoke-virtual {p1}, Lcom/moji/tipview/MJTipView$Builder;->b()V

    .line 180
    iget-object p1, p0, Lcom/moji/mjweather/scenestore/SceneEditAdapter$EditUnUsingClickListener;->a:Lcom/moji/mjweather/scenestore/SceneEditAdapter;

    invoke-static {p1}, Lcom/moji/mjweather/scenestore/SceneEditAdapter;->b(Lcom/moji/mjweather/scenestore/SceneEditAdapter;)Lcom/moji/mjweather/scenestore/SceneEditAdapter$SceneChangeListner;

    move-result-object p1

    invoke-interface {p1}, Lcom/moji/mjweather/scenestore/SceneEditAdapter$SceneChangeListner;->a()V

    .line 183
    :goto_0
    new-instance p1, Lcom/moji/preferences/ProcessPrefer;

    invoke-direct {p1}, Lcom/moji/preferences/ProcessPrefer;-><init>()V

    .line 184
    invoke-virtual {p1}, Lcom/moji/preferences/ProcessPrefer;->g()Z

    move-result p1

    .line 186
    new-instance v0, Lorg/json/JSONObject;

    invoke-direct {v0}, Lorg/json/JSONObject;-><init>()V

    :try_start_0
    const-string v1, "property1"

    if-eqz p1, :cond_2

    const-string p1, "1"

    goto :goto_1

    :cond_2
    const-string p1, "0"

    .line 188
    :goto_1
    invoke-virtual {v0, v1, p1}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;
    :try_end_0
    .catch Lorg/json/JSONException; {:try_start_0 .. :try_end_0} :catch_0

    goto :goto_2

    :catch_0
    move-exception p1

    .line 190
    invoke-virtual {p1}, Lorg/json/JSONException;->printStackTrace()V

    :goto_2
    return-void

    :cond_3
    :goto_3
    return-void
.end method
