BasePayService$1.smali

.class Lcom/sandboxol/googlepay/billing/BasePayService$1;
.super Lcom/sandboxol/common/base/web/OnResponseListener;
.source "BasePayService.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingMethod;
    value = Lcom/sandboxol/googlepay/billing/BasePayService;->updateUserMoney(Landroid/content/Context;ZLcom/sandboxol/greendao/entity/User;)V
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation

.annotation system Ldalvik/annotation/Signature;
    value = {
        "Lcom/sandboxol/common/base/web/OnResponseListener<",
        "Lcom/sandboxol/center/entity/RechargeEntity;",
        ">;"
    }
.end annotation


# instance fields
.field final synthetic this$0:Lcom/sandboxol/googlepay/billing/BasePayService;

.field final synthetic val$context:Landroid/content/Context;

.field final synthetic val$isConsume:Z

.field final synthetic val$user:Lcom/sandboxol/greendao/entity/User;


# direct methods
.method constructor <init>(Lcom/sandboxol/googlepay/billing/BasePayService;ZLcom/sandboxol/greendao/entity/User;Landroid/content/Context;)V
    .registers 5

    .line 1
    iput-object p1, p0, Lcom/sandboxol/googlepay/billing/BasePayService$1;->this$0:Lcom/sandboxol/googlepay/billing/BasePayService;

    iput-boolean p2, p0, Lcom/sandboxol/googlepay/billing/BasePayService$1;->val$isConsume:Z

    iput-object p3, p0, Lcom/sandboxol/googlepay/billing/BasePayService$1;->val$user:Lcom/sandboxol/greendao/entity/User;

    iput-object p4, p0, Lcom/sandboxol/googlepay/billing/BasePayService$1;->val$context:Landroid/content/Context;

    invoke-direct {p0}, Lcom/sandboxol/common/base/web/OnResponseListener;-><init>()V

    return-void
.end method


# virtual methods
.method public onError(ILjava/lang/String;)V
    .registers 3

    return-void
.end method

.method public onServerError(I)V
    .registers 2

    return-void
.end method

.method public onSuccess(Lcom/sandboxol/center/entity/RechargeEntity;)V
    .registers 7

    .line 2
    invoke-static {}, Lcom/sandboxol/center/entity/AccountCenter;->newInstance()Lcom/sandboxol/center/entity/AccountCenter;

    move-result-object v0

    iget-object v0, v0, Lcom/sandboxol/center/entity/AccountCenter;->gDiamonds:Landroidx/databinding/ObservableField;

    invoke-virtual {p1}, Lcom/sandboxol/center/entity/RechargeEntity;->getgDiamonds()J

    move-result-wide v1

    invoke-static {v1, v2}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroidx/databinding/ObservableField;->set(Ljava/lang/Object;)V

    .line 3
    invoke-static {}, Lcom/sandboxol/center/entity/AccountCenter;->newInstance()Lcom/sandboxol/center/entity/AccountCenter;

    move-result-object v0

    iget-object v0, v0, Lcom/sandboxol/center/entity/AccountCenter;->diamonds:Landroidx/databinding/ObservableField;

    invoke-virtual {p1}, Lcom/sandboxol/center/entity/RechargeEntity;->getDiamonds()J

    move-result-wide v1

    invoke-static {v1, v2}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroidx/databinding/ObservableField;->set(Ljava/lang/Object;)V

    .line 4
    invoke-static {}, Lcom/sandboxol/center/entity/AccountCenter;->newInstance()Lcom/sandboxol/center/entity/AccountCenter;

    move-result-object v0

    iget-object v0, v0, Lcom/sandboxol/center/entity/AccountCenter;->golds:Landroidx/databinding/ObservableField;

    invoke-virtual {p1}, Lcom/sandboxol/center/entity/RechargeEntity;->getGolds()J

    move-result-wide v1

    invoke-static {v1, v2}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroidx/databinding/ObservableField;->set(Ljava/lang/Object;)V

    .line 5
    invoke-static {}, Lcom/sandboxol/center/entity/AccountCenter;->newInstance()Lcom/sandboxol/center/entity/AccountCenter;

    move-result-object v0

    iget-object v0, v0, Lcom/sandboxol/center/entity/AccountCenter;->gDiamondsProfit:Landroidx/databinding/ObservableField;

    invoke-virtual {p1}, Lcom/sandboxol/center/entity/RechargeEntity;->getgDiamondsProfit()J

    move-result-wide v1

    invoke-static {v1, v2}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroidx/databinding/ObservableField;->set(Ljava/lang/Object;)V

    .line 6
    invoke-static {}, Lcom/sandboxol/center/entity/AccountCenter;->newInstance()Lcom/sandboxol/center/entity/AccountCenter;

    move-result-object v0

    iget-object v0, v0, Lcom/sandboxol/center/entity/AccountCenter;->money:Landroidx/databinding/ObservableField;

    invoke-virtual {p1}, Lcom/sandboxol/center/entity/RechargeEntity;->getMoney()D

    move-result-wide v1

    invoke-static {v1, v2}, Ljava/lang/Double;->valueOf(D)Ljava/lang/Double;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroidx/databinding/ObservableField;->set(Ljava/lang/Object;)V

    .line 7
    invoke-static {}, Lcom/sandboxol/center/entity/AccountCenter;->putAccountInfo()V

    .line 8
    invoke-static {}, Lcom/sandboxol/center/entity/AccountCenter;->newInstance()Lcom/sandboxol/center/entity/AccountCenter;

    move-result-object v0

    iget-object v0, v0, Lcom/sandboxol/center/entity/AccountCenter;->hasPassword:Landroidx/databinding/ObservableField;

    invoke-virtual {v0}, Landroidx/databinding/ObservableField;->get()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Ljava/lang/Boolean;

    invoke-virtual {v0}, Ljava/lang/Boolean;->booleanValue()Z

    move-result v0

    if-nez v0, :cond_c3

    invoke-static {}, Lcom/sandboxol/center/entity/AccountCenter;->newInstance()Lcom/sandboxol/center/entity/AccountCenter;

    move-result-object v0

    iget-object v0, v0, Lcom/sandboxol/center/entity/AccountCenter;->userId:Landroidx/databinding/ObservableField;

    invoke-virtual {v0}, Landroidx/databinding/ObservableField;->get()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Ljava/lang/Long;

    invoke-virtual {v0}, Ljava/lang/Long;->longValue()J

    move-result-wide v0

    const-wide/16 v2, 0x0

    cmp-long v4, v0, v2

    if-eqz v4, :cond_c3

    .line 9
    iget-boolean v0, p0, Lcom/sandboxol/googlepay/billing/BasePayService$1;->val$isConsume:Z

    if-eqz v0, :cond_b7

    .line 10
    iget-object v0, p0, Lcom/sandboxol/googlepay/billing/BasePayService$1;->val$user:Lcom/sandboxol/greendao/entity/User;

    if-eqz v0, :cond_b0

    invoke-virtual {v0}, Lcom/sandboxol/greendao/entity/User;->getGolds()J

    move-result-wide v0

    invoke-virtual {p1}, Lcom/sandboxol/center/entity/RechargeEntity;->getGolds()J

    move-result-wide v2

    cmp-long v4, v0, v2

    if-gtz v4, :cond_b0

    iget-object v0, p0, Lcom/sandboxol/googlepay/billing/BasePayService$1;->val$user:Lcom/sandboxol/greendao/entity/User;

    invoke-virtual {v0}, Lcom/sandboxol/greendao/entity/User;->getDiamonds()J

    move-result-wide v0

    invoke-virtual {p1}, Lcom/sandboxol/center/entity/RechargeEntity;->getDiamonds()J

    move-result-wide v2

    cmp-long v4, v0, v2

    if-gtz v4, :cond_b0

    iget-object v0, p0, Lcom/sandboxol/googlepay/billing/BasePayService$1;->val$user:Lcom/sandboxol/greendao/entity/User;

    invoke-virtual {v0}, Lcom/sandboxol/greendao/entity/User;->getGDiamonds()J

    move-result-wide v0

    invoke-virtual {p1}, Lcom/sandboxol/center/entity/RechargeEntity;->getgDiamonds()J

    move-result-wide v2

    cmp-long p1, v0, v2

    if-lez p1, :cond_c3

    .line 11
    :cond_b0
    iget-object p1, p0, Lcom/sandboxol/googlepay/billing/BasePayService$1;->val$context:Landroid/content/Context;

    const/4 v0, 0x0

    invoke-static {p1, v0}, Lcom/sandboxol/center/utils/IntentUtils;->startPasswordSettingDialog(Landroid/content/Context;Z)V

    goto :goto_c3

    .line 12
    :cond_b7
    iget-object p1, p0, Lcom/sandboxol/googlepay/billing/BasePayService$1;->val$context:Landroid/content/Context;

    new-instance v0, Lcom/sandboxol/googlepay/billing/BasePayService$1$1;

    invoke-direct {v0, p0}, Lcom/sandboxol/googlepay/billing/BasePayService$1$1;-><init>(Lcom/sandboxol/googlepay/billing/BasePayService$1;)V

    const-string v1, "2"

    invoke-static {p1, v1, v0}, Lcom/sandboxol/center/router/manager/LoginManager;->paramCheck(Landroid/content/Context;Ljava/lang/String;Lcom/sandboxol/common/base/web/OnResponseListener;)V

    :cond_c3
    :goto_c3
    return-void
.end method

.method public bridge synthetic onSuccess(Ljava/lang/Object;)V
    .registers 2

    .line 1
    check-cast p1, Lcom/sandboxol/center/entity/RechargeEntity;

    invoke-virtual {p0, p1}, Lcom/sandboxol/googlepay/billing/BasePayService$1;->onSuccess(Lcom/sandboxol/center/entity/RechargeEntity;)V

    return-void
.end method