l.smali

.class public Lcom/huawei/hms/update/e/l;
.super Lcom/huawei/hms/update/e/a;
.source "HiappWizard.java"


# direct methods
.method public constructor <init>()V
    .registers 1

    .prologue
    .line 17
    invoke-direct {p0}, Lcom/huawei/hms/update/e/a;-><init>()V

    return-void
.end method

.method private e()Z
    .registers 6

    .prologue
    const/4 v0, 0x0

    .line 130
    invoke-virtual {p0}, Lcom/huawei/hms/update/e/l;->a()Landroid/app/Activity;

    move-result-object v1

    .line 131
    if-eqz v1, :cond_d

    invoke-virtual {v1}, Landroid/app/Activity;->isFinishing()Z

    move-result v2

    if-eqz v2, :cond_e

    .line 153
    :cond_d
    :goto_d
    return v0

    .line 136
    :cond_e
    iget-object v2, p0, Lcom/huawei/hms/update/e/l;->g:Ljava/lang/String;

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

    move-result v2

    if-nez v2, :cond_d

    .line 141
    :try_start_16
    new-instance v2, Landroid/content/Intent;

    invoke-direct {v2}, Landroid/content/Intent;-><init>()V

    .line 142
    const-string v3, "com.huawei.appmarket.intent.action.AppDetail"

    invoke-virtual {v2, v3}, Landroid/content/Intent;->setAction(Ljava/lang/String;)Landroid/content/Intent;

    .line 144
    const-string v3, "APP_PACKAGENAME"

    iget-object v4, p0, Lcom/huawei/hms/update/e/l;->g:Ljava/lang/String;

    invoke-virtual {v2, v3, v4}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    .line 146
    const-string v3, "com.huawei.appmarket"

    invoke-virtual {v2, v3}, Landroid/content/Intent;->setPackage(Ljava/lang/String;)Landroid/content/Intent;

    .line 147
    invoke-virtual {p0}, Lcom/huawei/hms/update/e/l;->c()I

    move-result v3

    invoke-virtual {v1, v2, v3}, Landroid/app/Activity;->startActivityForResult(Landroid/content/Intent;I)V
    :try_end_33
    .catch Landroid/content/ActivityNotFoundException; {:try_start_16 .. :try_end_33} :catch_35

    .line 153
    const/4 v0, 0x1

    goto :goto_d

    .line 149
    :catch_35
    move-exception v1

    const-string v1, "HiappWizard"

    const-string v2, "can not open hiapp"

    invoke-static {v1, v2}, Lcom/huawei/hms/support/log/a;->d(Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_d
.end method


# virtual methods
.method public a(Lcom/huawei/hms/update/e/b;)V
    .registers 4

    .prologue
    .line 100
    const-string v0, "HiappWizard"

    const-string v1, "Enter onCancel."

    invoke-static {v0, v1}, Lcom/huawei/hms/support/log/a;->b(Ljava/lang/String;Ljava/lang/String;)V

    .line 102
    instance-of v0, p1, Lcom/huawei/hms/update/e/m;

    if-eqz v0, :cond_e

    .line 103
    invoke-virtual {p0}, Lcom/huawei/hms/update/e/l;->d()V

    .line 105
    :cond_e
    return-void
.end method

.method a(Ljava/lang/Class;)V
    .registers 7
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Ljava/lang/Class",
            "<+",
            "Lcom/huawei/hms/update/e/b;",
            ">;)V"
        }
    .end annotation

    .prologue
    .line 162
    invoke-virtual {p0}, Lcom/huawei/hms/update/e/l;->b()V

    .line 164
    :try_start_3
    invoke-virtual {p1}, Ljava/lang/Class;->newInstance()Ljava/lang/Object;

    move-result-object v1

    check-cast v1, Lcom/huawei/hms/update/e/b;

    .line 166
    iget-object v2, p0, Lcom/huawei/hms/update/e/l;->h:Ljava/lang/String;

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

    move-result v2

    if-nez v2, :cond_1e

    instance-of v2, v1, Lcom/huawei/hms/update/e/m;

    if-eqz v2, :cond_1e

    .line 167
    move-object v0, v1

    check-cast v0, Lcom/huawei/hms/update/e/m;

    move-object v2, v0

    iget-object v3, p0, Lcom/huawei/hms/update/e/l;->h:Ljava/lang/String;

    invoke-virtual {v2, v3}, Lcom/huawei/hms/update/e/m;->a(Ljava/lang/String;)V

    .line 170
    :cond_1e
    invoke-virtual {v1, p0}, Lcom/huawei/hms/update/e/b;->a(Lcom/huawei/hms/update/e/a;)V

    .line 171
    iput-object v1, p0, Lcom/huawei/hms/update/e/l;->d:Lcom/huawei/hms/update/e/b;
    :try_end_23
    .catch Ljava/lang/InstantiationException; {:try_start_3 .. :try_end_23} :catch_24
    .catch Ljava/lang/IllegalAccessException; {:try_start_3 .. :try_end_23} :catch_3e
    .catch Ljava/lang/IllegalStateException; {:try_start_3 .. :try_end_23} :catch_40

    .line 175
    :goto_23
    return-void

    .line 172
    :catch_24
    move-exception v1

    .line 173
    :goto_25
    const-string v2, "HiappWizard"

    new-instance v3, Ljava/lang/StringBuilder;

    const-string v4, "In showDialog, Failed to show the dialog."

    invoke-direct {v3, v4}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v1}, Ljava/lang/Exception;->getMessage()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v3, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    invoke-static {v2, v1}, Lcom/huawei/hms/support/log/a;->d(Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_23

    .line 172
    :catch_3e
    move-exception v1

    goto :goto_25

    :catch_40
    move-exception v1

    goto :goto_25
.end method

.method public b(Lcom/huawei/hms/update/e/b;)V
    .registers 5

    .prologue
    const/16 v2, 0x8

    .line 112
    const-string v0, "HiappWizard"

    const-string v1, "Enter onDoWork."

    invoke-static {v0, v1}, Lcom/huawei/hms/support/log/a;->b(Ljava/lang/String;Ljava/lang/String;)V

    .line 114
    instance-of v0, p1, Lcom/huawei/hms/update/e/m;

    if-eqz v0, :cond_22

    .line 115
    invoke-virtual {p1}, Lcom/huawei/hms/update/e/b;->c()V

    .line 116
    invoke-direct {p0}, Lcom/huawei/hms/update/e/l;->e()Z

    move-result v0

    if-nez v0, :cond_22

    .line 117
    const/4 v0, 0x0

    invoke-virtual {p0, v0}, Lcom/huawei/hms/update/e/l;->a(Z)Z

    move-result v0

    if-nez v0, :cond_23

    .line 118
    iget v0, p0, Lcom/huawei/hms/update/e/l;->f:I

    invoke-virtual {p0, v2, v0}, Lcom/huawei/hms/update/e/l;->b(II)V

    .line 124
    :cond_22
    :goto_22
    return-void

    .line 120
    :cond_23
    iget v0, p0, Lcom/huawei/hms/update/e/l;->f:I

    invoke-virtual {p0, v2, v0}, Lcom/huawei/hms/update/e/l;->a(II)V

    goto :goto_22
.end method

.method public c()I
    .registers 2

    .prologue
    .line 62
    const/16 v0, 0x7d5

    return v0
.end method

.method d()V
    .registers 3

    .prologue
    .line 179
    const/16 v0, 0xd

    iget v1, p0, Lcom/huawei/hms/update/e/l;->f:I

    invoke-virtual {p0, v0, v1}, Lcom/huawei/hms/update/e/l;->b(II)V

    .line 180
    return-void
.end method

.method public onBridgeActivityCreate(Landroid/app/Activity;)V
    .registers 4

    .prologue
    const/16 v1, 0x8

    .line 27
    invoke-super {p0, p1}, Lcom/huawei/hms/update/e/a;->onBridgeActivityCreate(Landroid/app/Activity;)V

    .line 29
    iget-object v0, p0, Lcom/huawei/hms/update/e/l;->c:Lcom/huawei/hms/update/e/u;

    if-nez v0, :cond_a

    .line 47
    :cond_9
    :goto_9
    return-void

    .line 33
    :cond_a
    const/4 v0, 0x5

    iput v0, p0, Lcom/huawei/hms/update/e/l;->f:I

    .line 35
    iget-object v0, p0, Lcom/huawei/hms/update/e/l;->c:Lcom/huawei/hms/update/e/u;

    invoke-virtual {v0}, Lcom/huawei/hms/update/e/u;->g()Z

    move-result v0

    if-eqz v0, :cond_23

    iget-object v0, p0, Lcom/huawei/hms/update/e/l;->h:Ljava/lang/String;

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

    move-result v0

    if-nez v0, :cond_23

    .line 36
    const-class v0, Lcom/huawei/hms/update/e/m;

    invoke-virtual {p0, v0}, Lcom/huawei/hms/update/e/l;->a(Ljava/lang/Class;)V

    goto :goto_9

    .line 38
    :cond_23
    invoke-direct {p0}, Lcom/huawei/hms/update/e/l;->e()Z

    move-result v0

    if-nez v0, :cond_9

    .line 40
    const/4 v0, 0x0

    invoke-virtual {p0, v0}, Lcom/huawei/hms/update/e/l;->a(Z)Z

    move-result v0

    if-nez v0, :cond_36

    .line 41
    iget v0, p0, Lcom/huawei/hms/update/e/l;->f:I

    invoke-virtual {p0, v1, v0}, Lcom/huawei/hms/update/e/l;->b(II)V

    goto :goto_9

    .line 43
    :cond_36
    iget v0, p0, Lcom/huawei/hms/update/e/l;->f:I

    invoke-virtual {p0, v1, v0}, Lcom/huawei/hms/update/e/l;->a(II)V

    goto :goto_9
.end method

.method public onBridgeActivityDestroy()V
    .registers 1

    .prologue
    .line 54
    invoke-super {p0}, Lcom/huawei/hms/update/e/a;->onBridgeActivityDestroy()V

    .line 55
    return-void
.end method

.method public onBridgeActivityResult(IILandroid/content/Intent;)Z
    .registers 7

    .prologue
    const/4 v0, 0x0

    .line 71
    iget-boolean v1, p0, Lcom/huawei/hms/update/e/l;->e:Z

    if-eqz v1, :cond_10

    iget-object v1, p0, Lcom/huawei/hms/update/e/l;->b:Lcom/huawei/hms/activity/a;

    if-eqz v1, :cond_10

    .line 72
    iget-object v0, p0, Lcom/huawei/hms/update/e/l;->b:Lcom/huawei/hms/activity/a;

    invoke-interface {v0, p1, p2, p3}, Lcom/huawei/hms/activity/a;->onBridgeActivityResult(IILandroid/content/Intent;)Z

    move-result v0

    .line 86
    :cond_f
    :goto_f
    return v0

    .line 75
    :cond_10
    iget v1, p0, Lcom/huawei/hms/update/e/l;->f:I

    const/4 v2, 0x5

    if-ne v1, v2, :cond_f

    invoke-virtual {p0}, Lcom/huawei/hms/update/e/l;->c()I

    move-result v1

    if-ne p1, v1, :cond_f

    .line 76
    iget-object v1, p0, Lcom/huawei/hms/update/e/l;->g:Ljava/lang/String;

    iget v2, p0, Lcom/huawei/hms/update/e/l;->i:I

    invoke-virtual {p0, v1, v2}, Lcom/huawei/hms/update/e/l;->a(Ljava/lang/String;I)Z

    move-result v1

    if-eqz v1, :cond_2c

    .line 78
    iget v1, p0, Lcom/huawei/hms/update/e/l;->f:I

    invoke-virtual {p0, v0, v1}, Lcom/huawei/hms/update/e/l;->b(II)V

    .line 83
    :goto_2a
    const/4 v0, 0x1

    goto :goto_f

    .line 81
    :cond_2c
    const/16 v0, 0x8

    iget v1, p0, Lcom/huawei/hms/update/e/l;->f:I

    invoke-virtual {p0, v0, v1}, Lcom/huawei/hms/update/e/l;->b(II)V

    goto :goto_2a
.end method

.method public onBridgeConfigurationChanged()V
    .registers 1

    .prologue
    .line 92
    invoke-super {p0}, Lcom/huawei/hms/update/e/a;->onBridgeConfigurationChanged()V

    .line 93
    return-void
.end method

.method public onKeyUp(ILandroid/view/KeyEvent;)V
    .registers 6

    .prologue
    .line 184
    iget-boolean v0, p0, Lcom/huawei/hms/update/e/l;->e:Z

    if-eqz v0, :cond_e

    iget-object v0, p0, Lcom/huawei/hms/update/e/l;->b:Lcom/huawei/hms/activity/a;

    if-eqz v0, :cond_e

    .line 185
    iget-object v0, p0, Lcom/huawei/hms/update/e/l;->b:Lcom/huawei/hms/activity/a;

    invoke-interface {v0, p1, p2}, Lcom/huawei/hms/activity/a;->onKeyUp(ILandroid/view/KeyEvent;)V

    .line 198
    :cond_d
    :goto_d
    return-void

    .line 189
    :cond_e
    const/4 v0, 0x4

    if-ne v0, p1, :cond_d

    .line 190
    const-string v0, "HiappWizard"

    const-string v1, "In onKeyUp, Call finish."

    invoke-static {v0, v1}, Lcom/huawei/hms/support/log/a;->b(Ljava/lang/String;Ljava/lang/String;)V

    .line 192
    invoke-virtual {p0}, Lcom/huawei/hms/update/e/l;->a()Landroid/app/Activity;

    move-result-object v0

    .line 193
    if-eqz v0, :cond_d

    invoke-virtual {v0}, Landroid/app/Activity;->isFinishing()Z

    move-result v1

    if-nez v1, :cond_d

    .line 194
    const/4 v1, 0x0

    const/4 v2, 0x0

    invoke-virtual {v0, v1, v2}, Landroid/app/Activity;->setResult(ILandroid/content/Intent;)V

    .line 195
    invoke-virtual {v0}, Landroid/app/Activity;->finish()V

    goto :goto_d
.end method