ce.smali

.class public Lcom/loc/ce;
.super Ljava/lang/Object;

# interfaces
.implements Lcom/amap/api/location/d;


# annotations
.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Lcom/loc/ce$a;,
        Lcom/loc/ce$b;,
        Lcom/loc/ce$c;
    }
.end annotation


# instance fields
.field private A:Z

.field private B:Landroid/content/ServiceConnection;

.field a:Lcom/amap/api/location/AMapLocationClientOption;

.field public b:Lcom/loc/ce$c;

.field c:Lcom/loc/cn;

.field d:Ljava/util/ArrayList;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Ljava/util/ArrayList",
            "<",
            "Lcom/amap/api/location/b;",
            ">;"
        }
    .end annotation
.end field

.field e:Lcom/loc/a;

.field f:Z

.field public g:Z

.field public h:Z

.field i:Lcom/loc/co;

.field j:Landroid/os/Messenger;

.field k:Landroid/os/Messenger;

.field l:Landroid/content/Intent;

.field m:I

.field n:Lcom/loc/ce$b;

.field o:Z

.field p:Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;

.field q:Ljava/lang/Object;

.field r:Lcom/loc/cg;

.field s:Lcom/loc/cl;

.field t:Ljava/lang/String;

.field u:Z

.field v:Lcom/loc/ce$a;

.field w:Ljava/lang/String;

.field private x:Landroid/content/Context;

.field private y:Z

.field private z:Z


# direct methods
.method public constructor <init>(Landroid/content/Context;Landroid/content/Intent;)V
    .registers 7

    const/4 v3, 0x1

    const/4 v2, 0x0

    const/4 v1, 0x0

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

    new-instance v0, Lcom/amap/api/location/AMapLocationClientOption;

    invoke-direct {v0}, Lcom/amap/api/location/AMapLocationClientOption;-><init>()V

    iput-object v0, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    iput-object v1, p0, Lcom/loc/ce;->c:Lcom/loc/cn;

    iput-boolean v2, p0, Lcom/loc/ce;->y:Z

    iput-boolean v2, p0, Lcom/loc/ce;->z:Z

    new-instance v0, Ljava/util/ArrayList;

    invoke-direct {v0}, Ljava/util/ArrayList;-><init>()V

    iput-object v0, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    iput-boolean v2, p0, Lcom/loc/ce;->f:Z

    iput-boolean v3, p0, Lcom/loc/ce;->g:Z

    iput-boolean v3, p0, Lcom/loc/ce;->h:Z

    iput-object v1, p0, Lcom/loc/ce;->j:Landroid/os/Messenger;

    iput-object v1, p0, Lcom/loc/ce;->k:Landroid/os/Messenger;

    iput-object v1, p0, Lcom/loc/ce;->l:Landroid/content/Intent;

    iput v2, p0, Lcom/loc/ce;->m:I

    iput-boolean v3, p0, Lcom/loc/ce;->A:Z

    iput-object v1, p0, Lcom/loc/ce;->n:Lcom/loc/ce$b;

    iput-boolean v2, p0, Lcom/loc/ce;->o:Z

    sget-object v0, Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;->c:Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;

    iput-object v0, p0, Lcom/loc/ce;->p:Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;

    new-instance v0, Ljava/lang/Object;

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

    iput-object v0, p0, Lcom/loc/ce;->q:Ljava/lang/Object;

    iput-object v1, p0, Lcom/loc/ce;->r:Lcom/loc/cg;

    iput-object v1, p0, Lcom/loc/ce;->s:Lcom/loc/cl;

    iput-object v1, p0, Lcom/loc/ce;->t:Ljava/lang/String;

    new-instance v0, Lcom/loc/ce$1;

    invoke-direct {v0, p0}, Lcom/loc/ce$1;-><init>(Lcom/loc/ce;)V

    iput-object v0, p0, Lcom/loc/ce;->B:Landroid/content/ServiceConnection;

    iput-boolean v2, p0, Lcom/loc/ce;->u:Z

    iput-object v1, p0, Lcom/loc/ce;->v:Lcom/loc/ce$a;

    iput-object v1, p0, Lcom/loc/ce;->w:Ljava/lang/String;

    iput-object p1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    iput-object p2, p0, Lcom/loc/ce;->l:Landroid/content/Intent;

    invoke-static {}, Lcom/loc/ca;->c()Z

    move-result v0

    if-eqz v0, :cond_5f

    :try_start_56
    invoke-static {}, Lcom/loc/ca;->b()Lcom/loc/cy;

    move-result-object v0

    iget-object v1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-static {v1, v0}, Lcom/loc/ch;->a(Landroid/content/Context;Lcom/loc/cy;)V
    :try_end_5f
    .catch Ljava/lang/Throwable; {:try_start_56 .. :try_end_5f} :catch_e7

    :cond_5f
    :goto_5f
    :try_start_5f
    invoke-static {}, Landroid/os/Looper;->myLooper()Landroid/os/Looper;

    move-result-object v0

    if-nez v0, :cond_b3

    new-instance v0, Lcom/loc/ce$c;

    iget-object v1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-virtual {v1}, Landroid/content/Context;->getMainLooper()Landroid/os/Looper;

    move-result-object v1

    invoke-direct {v0, p0, v1}, Lcom/loc/ce$c;-><init>(Lcom/loc/ce;Landroid/os/Looper;)V

    iput-object v0, p0, Lcom/loc/ce;->b:Lcom/loc/ce$c;
    :try_end_72
    .catch Ljava/lang/Throwable; {:try_start_5f .. :try_end_72} :catch_bb

    :goto_72
    :try_start_72
    new-instance v0, Lcom/loc/co;

    iget-object v1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-direct {v0, v1}, Lcom/loc/co;-><init>(Landroid/content/Context;)V

    iput-object v0, p0, Lcom/loc/ce;->i:Lcom/loc/co;
    :try_end_7b
    .catch Ljava/lang/Throwable; {:try_start_72 .. :try_end_7b} :catch_c6

    :goto_7b
    :try_start_7b
    new-instance v0, Lcom/loc/ce$b;

    const-string/jumbo v1, "amapLocManagerThread"

    invoke-direct {v0, v1, p0}, Lcom/loc/ce$b;-><init>(Ljava/lang/String;Lcom/loc/ce;)V

    iput-object v0, p0, Lcom/loc/ce;->n:Lcom/loc/ce$b;

    iget-object v0, p0, Lcom/loc/ce;->n:Lcom/loc/ce$b;

    const/4 v1, 0x5

    invoke-virtual {v0, v1}, Lcom/loc/ce$b;->setPriority(I)V

    iget-object v0, p0, Lcom/loc/ce;->n:Lcom/loc/ce$b;

    invoke-virtual {v0}, Lcom/loc/ce$b;->start()V

    iget-object v0, p0, Lcom/loc/ce;->n:Lcom/loc/ce$b;

    invoke-virtual {v0}, Lcom/loc/ce$b;->getLooper()Landroid/os/Looper;

    move-result-object v0

    invoke-direct {p0, v0}, Lcom/loc/ce;->a(Landroid/os/Looper;)Lcom/loc/ce$a;

    move-result-object v0

    iput-object v0, p0, Lcom/loc/ce;->v:Lcom/loc/ce$a;
    :try_end_9c
    .catch Ljava/lang/Throwable; {:try_start_7b .. :try_end_9c} :catch_d1

    :goto_9c
    :try_start_9c
    new-instance v0, Lcom/loc/cn;

    iget-object v1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    iget-object v2, p0, Lcom/loc/ce;->b:Lcom/loc/ce$c;

    invoke-direct {v0, v1, v2}, Lcom/loc/cn;-><init>(Landroid/content/Context;Landroid/os/Handler;)V

    iput-object v0, p0, Lcom/loc/ce;->c:Lcom/loc/cn;
    :try_end_a7
    .catch Ljava/lang/Throwable; {:try_start_9c .. :try_end_a7} :catch_dc

    :goto_a7
    iget-object v0, p0, Lcom/loc/ce;->r:Lcom/loc/cg;

    if-nez v0, :cond_b2

    new-instance v0, Lcom/loc/cg;

    invoke-direct {v0}, Lcom/loc/cg;-><init>()V

    iput-object v0, p0, Lcom/loc/ce;->r:Lcom/loc/cg;

    :cond_b2
    return-void

    :cond_b3
    :try_start_b3
    new-instance v0, Lcom/loc/ce$c;

    invoke-direct {v0, p0}, Lcom/loc/ce$c;-><init>(Lcom/loc/ce;)V

    iput-object v0, p0, Lcom/loc/ce;->b:Lcom/loc/ce$c;
    :try_end_ba
    .catch Ljava/lang/Throwable; {:try_start_b3 .. :try_end_ba} :catch_bb

    goto :goto_72

    :catch_bb
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "init 1"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_72

    :catch_c6
    move-exception v0

    :try_start_c7
    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "init 2"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_d0
    .catch Ljava/lang/Throwable; {:try_start_c7 .. :try_end_d0} :catch_d1

    goto :goto_7b

    :catch_d1
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "init 5"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_9c

    :catch_dc
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "init 3"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_a7

    :catch_e7
    move-exception v0

    goto/16 :goto_5f
.end method

.method private a(Lcom/loc/ax;)Lcom/autonavi/aps/amapapi/model/AMapLocationServer;
    .registers 5

    iget-object v0, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v0}, Lcom/amap/api/location/AMapLocationClientOption;->isLocationCacheEnable()Z

    move-result v0

    if-eqz v0, :cond_17

    :try_start_8
    invoke-virtual {p1}, Lcom/loc/ax;->i()Lcom/autonavi/aps/amapapi/model/AMapLocationServer;
    :try_end_b
    .catch Ljava/lang/Throwable; {:try_start_8 .. :try_end_b} :catch_d

    move-result-object v0

    :goto_c
    return-object v0

    :catch_d
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "doFirstCacheLoc"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    :cond_17
    const/4 v0, 0x0

    goto :goto_c
.end method

.method private a(Landroid/os/Looper;)Lcom/loc/ce$a;
    .registers 4

    iget-object v1, p0, Lcom/loc/ce;->q:Ljava/lang/Object;

    monitor-enter v1

    :try_start_3
    new-instance v0, Lcom/loc/ce$a;

    invoke-direct {v0, p0, p1}, Lcom/loc/ce$a;-><init>(Lcom/loc/ce;Landroid/os/Looper;)V

    iput-object v0, p0, Lcom/loc/ce;->v:Lcom/loc/ce$a;

    iget-object v0, p0, Lcom/loc/ce;->v:Lcom/loc/ce$a;

    monitor-exit v1
    :try_end_d
    .catchall {:try_start_3 .. :try_end_d} :catchall_e

    return-object v0

    :catchall_e
    move-exception v0

    monitor-exit v1

    throw v0
.end method

.method private a(ILandroid/os/Bundle;)V
    .registers 6

    if-nez p2, :cond_7

    :try_start_2
    new-instance p2, Landroid/os/Bundle;

    invoke-direct {p2}, Landroid/os/Bundle;-><init>()V

    :cond_7
    iget-object v0, p0, Lcom/loc/ce;->t:Ljava/lang/String;

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

    move-result v0

    if-eqz v0, :cond_17

    iget-object v0, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-static {v0}, Lcom/loc/ca;->c(Landroid/content/Context;)Ljava/lang/String;

    move-result-object v0

    iput-object v0, p0, Lcom/loc/ce;->t:Ljava/lang/String;

    :cond_17
    const-string/jumbo v0, "c"

    iget-object v1, p0, Lcom/loc/ce;->t:Ljava/lang/String;

    invoke-virtual {p2, v0, v1}, Landroid/os/Bundle;->putString(Ljava/lang/String;Ljava/lang/String;)V

    invoke-static {}, Landroid/os/Message;->obtain()Landroid/os/Message;

    move-result-object v0

    iput p1, v0, Landroid/os/Message;->what:I

    invoke-virtual {v0, p2}, Landroid/os/Message;->setData(Landroid/os/Bundle;)V

    iget-object v1, p0, Lcom/loc/ce;->k:Landroid/os/Messenger;

    iput-object v1, v0, Landroid/os/Message;->replyTo:Landroid/os/Messenger;

    iget-object v1, p0, Lcom/loc/ce;->j:Landroid/os/Messenger;

    if-eqz v1, :cond_35

    iget-object v1, p0, Lcom/loc/ce;->j:Landroid/os/Messenger;

    invoke-virtual {v1, v0}, Landroid/os/Messenger;->send(Landroid/os/Message;)V
    :try_end_35
    .catch Ljava/lang/Throwable; {:try_start_2 .. :try_end_35} :catch_36

    :cond_35
    :goto_35
    return-void

    :catch_36
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "sendLocMessage"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_35
.end method

.method private a(ILjava/lang/Object;J)V
    .registers 8

    iget-object v1, p0, Lcom/loc/ce;->q:Ljava/lang/Object;

    monitor-enter v1

    :try_start_3
    iget-object v0, p0, Lcom/loc/ce;->v:Lcom/loc/ce$a;

    if-eqz v0, :cond_14

    invoke-static {}, Landroid/os/Message;->obtain()Landroid/os/Message;

    move-result-object v0

    iput p1, v0, Landroid/os/Message;->what:I

    iput-object p2, v0, Landroid/os/Message;->obj:Ljava/lang/Object;

    iget-object v2, p0, Lcom/loc/ce;->v:Lcom/loc/ce$a;

    invoke-virtual {v2, v0, p3, p4}, Lcom/loc/ce$a;->sendMessageDelayed(Landroid/os/Message;J)Z

    :cond_14
    monitor-exit v1
    :try_end_15
    .catchall {:try_start_3 .. :try_end_15} :catchall_16

    return-void

    :catchall_16
    move-exception v0

    monitor-exit v1

    throw v0
.end method

.method private a(Lcom/amap/api/location/AMapLocation;Ljava/lang/Throwable;)V
    .registers 7

    :try_start_0
    invoke-static {}, Lcom/loc/ca;->c()Z

    move-result v0

    if-eqz v0, :cond_2e

    if-nez p1, :cond_2e

    if-eqz p2, :cond_17

    iget-object v0, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    const-string/jumbo v1, "loc"

    invoke-virtual {p2}, Ljava/lang/Throwable;->getMessage()Ljava/lang/String;

    move-result-object v2

    invoke-static {v0, v1, v2}, Lcom/loc/ch;->a(Landroid/content/Context;Ljava/lang/String;Ljava/lang/String;)V

    :cond_16
    :goto_16
    return-void

    :cond_17
    iget-object v0, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    const-string/jumbo v1, "loc"

    const-string/jumbo v2, "amaplocation is null"

    invoke-static {v0, v1, v2}, Lcom/loc/ch;->a(Landroid/content/Context;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_22
    .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_22} :catch_23

    goto :goto_16

    :catch_23
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "handlerLocation part3"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_16

    :cond_2e
    if-nez p1, :cond_43

    :try_start_30
    new-instance p1, Lcom/amap/api/location/AMapLocation;

    const-string/jumbo v0, ""

    invoke-direct {p1, v0}, Lcom/amap/api/location/AMapLocation;-><init>(Ljava/lang/String;)V

    const/16 v0, 0x8

    invoke-virtual {p1, v0}, Lcom/amap/api/location/AMapLocation;->setErrorCode(I)V

    const-string/jumbo v0, "amapLocation is null"

    invoke-virtual {p1, v0}, Lcom/amap/api/location/AMapLocation;->setLocationDetail(Ljava/lang/String;)V

    :cond_43
    const-string/jumbo v0, "gps"

    invoke-virtual {p1}, Lcom/amap/api/location/AMapLocation;->getProvider()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v0

    if-nez v0, :cond_56

    const-string/jumbo v0, "lbs"

    invoke-virtual {p1, v0}, Lcom/amap/api/location/AMapLocation;->setProvider(Ljava/lang/String;)V
    :try_end_56
    .catch Ljava/lang/Throwable; {:try_start_30 .. :try_end_56} :catch_23

    :cond_56
    :try_start_56
    iget-boolean v0, p0, Lcom/loc/ce;->z:Z

    if-eqz v0, :cond_d5

    const/16 v0, 0x3ff

    const-wide/16 v2, 0x0

    invoke-direct {p0, v0, p1, v2, v3}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V

    iget-object v0, p0, Lcom/loc/ce;->w:Ljava/lang/String;

    iget-object v1, p0, Lcom/loc/ce;->i:Lcom/loc/co;

    invoke-virtual {v1, p1, v0}, Lcom/loc/co;->a(Lcom/amap/api/location/AMapLocation;Ljava/lang/String;)Z

    move-result v0

    if-eqz v0, :cond_73

    const/16 v0, 0x3f6

    const/4 v1, 0x0

    const-wide/16 v2, 0x0

    invoke-direct {p0, v0, v1, v2, v3}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V

    :cond_73
    iget-object v0, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-static {v0, p1}, Lcom/loc/cg;->a(Landroid/content/Context;Lcom/amap/api/location/AMapLocation;)V

    iget-object v0, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-static {v0, p1}, Lcom/loc/cg;->b(Landroid/content/Context;Lcom/amap/api/location/AMapLocation;)V
    :try_end_7d
    .catch Ljava/lang/Throwable; {:try_start_56 .. :try_end_7d} :catch_cb

    :try_start_7d
    const-string/jumbo v0, "gps"

    invoke-virtual {p1}, Lcom/amap/api/location/AMapLocation;->getProvider()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v0

    if-nez v0, :cond_92

    iget-object v0, p0, Lcom/loc/ce;->c:Lcom/loc/cn;

    invoke-virtual {v0}, Lcom/loc/cn;->c()Z

    move-result v0

    if-nez v0, :cond_d5

    :cond_92
    invoke-virtual {p1}, Lcom/amap/api/location/AMapLocation;->getAltitude()D

    move-result-wide v0

    invoke-static {v0, v1}, Lcom/loc/cj;->b(D)D

    move-result-wide v0

    invoke-virtual {p1, v0, v1}, Lcom/amap/api/location/AMapLocation;->setAltitude(D)V

    invoke-virtual {p1}, Lcom/amap/api/location/AMapLocation;->getBearing()F

    move-result v0

    invoke-static {v0}, Lcom/loc/cj;->a(F)F

    move-result v0

    invoke-virtual {p1, v0}, Lcom/amap/api/location/AMapLocation;->setBearing(F)V

    invoke-virtual {p1}, Lcom/amap/api/location/AMapLocation;->getSpeed()F

    move-result v0

    invoke-static {v0}, Lcom/loc/cj;->a(F)F

    move-result v0

    invoke-virtual {p1, v0}, Lcom/amap/api/location/AMapLocation;->setSpeed(F)V

    iget-object v0, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    invoke-virtual {v0}, Ljava/util/ArrayList;->iterator()Ljava/util/Iterator;

    move-result-object v1

    :goto_b9
    invoke-interface {v1}, Ljava/util/Iterator;->hasNext()Z

    move-result v0

    if-eqz v0, :cond_d5

    invoke-interface {v1}, Ljava/util/Iterator;->next()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/amap/api/location/b;
    :try_end_c5
    .catch Ljava/lang/Throwable; {:try_start_7d .. :try_end_c5} :catch_f1

    :try_start_c5
    invoke-interface {v0, p1}, Lcom/amap/api/location/b;->onLocationChanged(Lcom/amap/api/location/AMapLocation;)V
    :try_end_c8
    .catch Ljava/lang/Throwable; {:try_start_c5 .. :try_end_c8} :catch_c9

    goto :goto_b9

    :catch_c9
    move-exception v0

    goto :goto_b9

    :catch_cb
    move-exception v0

    :try_start_cc
    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "handlerLocation part2"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    :cond_d5
    :goto_d5
    iget-boolean v0, p0, Lcom/loc/ce;->o:Z

    if-eqz v0, :cond_df

    invoke-static {}, Lcom/loc/ca;->c()Z

    move-result v0

    if-eqz v0, :cond_16

    :cond_df
    iget-object v0, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-static {v0}, Lcom/loc/ch;->b(Landroid/content/Context;)V

    iget-object v0, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v0}, Lcom/amap/api/location/AMapLocationClientOption;->isOnceLocation()Z

    move-result v0

    if-eqz v0, :cond_16

    invoke-direct {p0}, Lcom/loc/ce;->j()V
    :try_end_ef
    .catch Ljava/lang/Throwable; {:try_start_cc .. :try_end_ef} :catch_23

    goto/16 :goto_16

    :catch_f1
    move-exception v0

    goto :goto_d5
.end method

.method static synthetic a(Lcom/loc/ce;)V
    .registers 6

    const/4 v0, 0x1

    const/4 v1, 0x0

    :try_start_2
    iget-object v2, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    const-string/jumbo v3, "android.permission.SYSTEM_ALERT_WINDOW"

    invoke-virtual {v2, v3}, Landroid/content/Context;->checkCallingOrSelfPermission(Ljava/lang/String;)I

    move-result v2

    if-nez v2, :cond_60

    move v1, v0

    :goto_e
    if-eqz v1, :cond_6c

    new-instance v1, Landroid/app/AlertDialog$Builder;

    iget-object v2, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-direct {v1, v2}, Landroid/app/AlertDialog$Builder;-><init>(Landroid/content/Context;)V

    invoke-static {}, Lcom/loc/bz;->g()Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v2}, Landroid/app/AlertDialog$Builder;->setMessage(Ljava/lang/CharSequence;)Landroid/app/AlertDialog$Builder;

    const-string/jumbo v2, ""

    invoke-static {}, Lcom/loc/bz;->h()Ljava/lang/String;

    move-result-object v3

    invoke-virtual {v2, v3}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v2

    if-nez v2, :cond_3d

    invoke-static {}, Lcom/loc/bz;->h()Ljava/lang/String;

    move-result-object v2

    if-eqz v2, :cond_3d

    invoke-static {}, Lcom/loc/bz;->h()Ljava/lang/String;

    move-result-object v2

    new-instance v3, Lcom/loc/ce$2;

    invoke-direct {v3, p0}, Lcom/loc/ce$2;-><init>(Lcom/loc/ce;)V

    invoke-virtual {v1, v2, v3}, Landroid/app/AlertDialog$Builder;->setPositiveButton(Ljava/lang/CharSequence;Landroid/content/DialogInterface$OnClickListener;)Landroid/app/AlertDialog$Builder;

    :cond_3d
    invoke-static {}, Lcom/loc/bz;->i()Ljava/lang/String;

    move-result-object v2

    new-instance v3, Lcom/loc/ce$3;

    invoke-direct {v3, p0}, Lcom/loc/ce$3;-><init>(Lcom/loc/ce;)V

    invoke-virtual {v1, v2, v3}, Landroid/app/AlertDialog$Builder;->setNegativeButton(Ljava/lang/CharSequence;Landroid/content/DialogInterface$OnClickListener;)Landroid/app/AlertDialog$Builder;

    invoke-virtual {v1}, Landroid/app/AlertDialog$Builder;->create()Landroid/app/AlertDialog;

    move-result-object v1

    if-eqz v0, :cond_58

    invoke-virtual {v1}, Landroid/app/AlertDialog;->getWindow()Landroid/view/Window;

    move-result-object v0

    const/16 v2, 0x7d3

    invoke-virtual {v0, v2}, Landroid/view/Window;->setType(I)V

    :cond_58
    const/4 v0, 0x0

    invoke-virtual {v1, v0}, Landroid/app/AlertDialog;->setCanceledOnTouchOutside(Z)V

    invoke-virtual {v1}, Landroid/app/AlertDialog;->show()V

    :goto_5f
    return-void

    :cond_60
    iget-object v2, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    instance-of v2, v2, Landroid/app/Activity;

    if-eqz v2, :cond_6a

    move v4, v1

    move v1, v0

    move v0, v4

    goto :goto_e

    :cond_6a
    move v0, v1

    goto :goto_e

    :cond_6c
    invoke-direct {p0}, Lcom/loc/ce;->h()V
    :try_end_6f
    .catch Ljava/lang/Throwable; {:try_start_2 .. :try_end_6f} :catch_70

    goto :goto_5f

    :catch_70
    move-exception v0

    invoke-direct {p0}, Lcom/loc/ce;->h()V

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "showDialog"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_5f
.end method

.method static synthetic a(Lcom/loc/ce;Landroid/os/Bundle;)V
    .registers 7

    const/4 v1, 0x0

    if-eqz p1, :cond_53

    :try_start_3
    const-class v0, Lcom/amap/api/location/AMapLocation;

    invoke-virtual {v0}, Ljava/lang/Class;->getClassLoader()Ljava/lang/ClassLoader;

    move-result-object v0

    invoke-virtual {p1, v0}, Landroid/os/Bundle;->setClassLoader(Ljava/lang/ClassLoader;)V

    const-string/jumbo v0, "loc"

    invoke-virtual {p1, v0}, Landroid/os/Bundle;->getParcelable(Ljava/lang/String;)Landroid/os/Parcelable;

    move-result-object v0

    check-cast v0, Lcom/amap/api/location/AMapLocation;

    if-eqz v0, :cond_51

    invoke-virtual {v0}, Lcom/amap/api/location/AMapLocation;->clone()Lcom/amap/api/location/AMapLocation;

    move-result-object v0

    :goto_1b
    const-string/jumbo v2, "nb"

    const/4 v3, 0x0

    invoke-virtual {p1, v2, v3}, Landroid/os/Bundle;->getString(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v2

    iput-object v2, p0, Lcom/loc/ce;->w:Ljava/lang/String;

    if-eqz v0, :cond_3f

    invoke-virtual {v0}, Lcom/amap/api/location/AMapLocation;->getErrorCode()I

    move-result v2

    if-nez v2, :cond_3f

    invoke-virtual {v0}, Lcom/amap/api/location/AMapLocation;->getAdCode()Ljava/lang/String;

    move-result-object v2

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

    move-result v2

    if-nez v2, :cond_3f

    iget-object v2, p0, Lcom/loc/ce;->c:Lcom/loc/cn;

    if-eqz v2, :cond_3f

    iget-object v2, p0, Lcom/loc/ce;->c:Lcom/loc/cn;

    iput-object v0, v2, Lcom/loc/cn;->n:Lcom/amap/api/location/AMapLocation;
    :try_end_3f
    .catch Ljava/lang/Throwable; {:try_start_3 .. :try_end_3f} :catch_43

    :cond_3f
    :goto_3f
    invoke-direct {p0, v0, v1}, Lcom/loc/ce;->a(Lcom/amap/api/location/AMapLocation;Ljava/lang/Throwable;)V

    return-void

    :catch_43
    move-exception v0

    const-string/jumbo v2, "AMapLocationManager"

    const-string/jumbo v3, "doLbsLocationSuccess"

    invoke-static {v0, v2, v3}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    move-object v4, v0

    move-object v0, v1

    move-object v1, v4

    goto :goto_3f

    :cond_51
    move-object v0, v1

    goto :goto_1b

    :cond_53
    move-object v0, v1

    goto :goto_3f
.end method

.method static synthetic a(Lcom/loc/ce;Landroid/os/Message;)V
    .registers 6

    :try_start_0
    iget-object v0, p1, Landroid/os/Message;->obj:Ljava/lang/Object;

    check-cast v0, Lcom/amap/api/location/AMapLocation;

    iget-boolean v1, p0, Lcom/loc/ce;->h:Z

    if-eqz v1, :cond_24

    iget-object v1, p0, Lcom/loc/ce;->j:Landroid/os/Messenger;

    if-eqz v1, :cond_24

    new-instance v1, Landroid/os/Bundle;

    invoke-direct {v1}, Landroid/os/Bundle;-><init>()V

    const-string/jumbo v2, "optBundle"

    iget-object v3, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-static {v3}, Lcom/loc/ca;->b(Lcom/amap/api/location/AMapLocationClientOption;)Landroid/os/Bundle;

    move-result-object v3

    invoke-virtual {v1, v2, v3}, Landroid/os/Bundle;->putBundle(Ljava/lang/String;Landroid/os/Bundle;)V

    const/4 v2, 0x0

    invoke-direct {p0, v2, v1}, Lcom/loc/ce;->a(ILandroid/os/Bundle;)V

    const/4 v1, 0x0

    iput-boolean v1, p0, Lcom/loc/ce;->h:Z

    :cond_24
    const/4 v1, 0x0

    invoke-direct {p0, v0, v1}, Lcom/loc/ce;->a(Lcom/amap/api/location/AMapLocation;Ljava/lang/Throwable;)V

    iget-boolean v0, p0, Lcom/loc/ce;->A:Z

    if-eqz v0, :cond_31

    const/4 v0, 0x7

    const/4 v1, 0x0

    invoke-direct {p0, v0, v1}, Lcom/loc/ce;->a(ILandroid/os/Bundle;)V
    :try_end_31
    .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_31} :catch_32

    :cond_31
    :goto_31
    return-void

    :catch_32
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "doGpsLocationSuccess"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_31
.end method

.method static synthetic a(Lcom/loc/ce;Lcom/amap/api/location/AMapLocation;)V
    .registers 4

    if-nez p1, :cond_3

    :goto_2
    return-void

    :cond_3
    const/4 v0, 0x0

    :try_start_4
    sget-object v1, Lcom/loc/co;->b:Lcom/loc/br;

    if-nez v1, :cond_18

    iget-object v1, p0, Lcom/loc/ce;->i:Lcom/loc/co;

    if-eqz v1, :cond_12

    iget-object v0, p0, Lcom/loc/ce;->i:Lcom/loc/co;

    invoke-virtual {v0}, Lcom/loc/co;->b()Lcom/amap/api/location/AMapLocation;

    move-result-object v0

    :cond_12
    :goto_12
    invoke-static {v0, p1}, Lcom/loc/cg;->b(Lcom/amap/api/location/AMapLocation;Lcom/amap/api/location/AMapLocation;)V

    goto :goto_2

    :catch_16
    move-exception v0

    goto :goto_2

    :cond_18
    sget-object v0, Lcom/loc/co;->b:Lcom/loc/br;

    invoke-virtual {v0}, Lcom/loc/br;->a()Lcom/amap/api/location/AMapLocation;
    :try_end_1d
    .catch Ljava/lang/Throwable; {:try_start_4 .. :try_end_1d} :catch_16

    move-result-object v0

    goto :goto_12
.end method

.method static synthetic a(Lcom/loc/ce;Lcom/amap/api/location/b;)V
    .registers 4

    if-nez p1, :cond_b

    new-instance v0, Ljava/lang/IllegalArgumentException;

    const-string/jumbo v1, "listener\u53c2\u6570\u4e0d\u80fd\u4e3anull"

    invoke-direct {v0, v1}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V

    throw v0

    :cond_b
    iget-object v0, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    if-nez v0, :cond_16

    new-instance v0, Ljava/util/ArrayList;

    invoke-direct {v0}, Ljava/util/ArrayList;-><init>()V

    iput-object v0, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    :cond_16
    iget-object v0, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    invoke-virtual {v0, p1}, Ljava/util/ArrayList;->contains(Ljava/lang/Object;)Z

    move-result v0

    if-nez v0, :cond_23

    iget-object v0, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    invoke-virtual {v0, p1}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z

    :cond_23
    return-void
.end method

.method static synthetic a(Lcom/loc/ce;Z)Z
    .registers 2

    iput-boolean p1, p0, Lcom/loc/ce;->y:Z

    return p1
.end method

.method private b(Lcom/loc/ax;)Lcom/autonavi/aps/amapapi/model/AMapLocationServer;
    .registers 10

    const/4 v4, 0x0

    const/4 v1, 0x0

    const/4 v3, 0x1

    :try_start_3
    new-instance v5, Lcom/loc/cf;

    invoke-direct {v5}, Lcom/loc/cf;-><init>()V

    invoke-static {}, Lcom/loc/cj;->b()J

    move-result-wide v6

    invoke-virtual {v5, v6, v7}, Lcom/loc/cf;->a(J)V
    :try_end_f
    .catch Ljava/lang/Throwable; {:try_start_3 .. :try_end_f} :catch_b6
    .catchall {:try_start_3 .. :try_end_f} :catchall_d5

    :try_start_f
    invoke-static {}, Lcom/amap/api/location/AMapLocationClientOption;->getAPIKEY()Ljava/lang/String;

    move-result-object v0

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

    move-result v2

    if-nez v2, :cond_1c

    invoke-static {v0}, Lcom/loc/cr;->a(Ljava/lang/String;)V
    :try_end_1c
    .catch Ljava/lang/Throwable; {:try_start_f .. :try_end_1c} :catch_aa
    .catchall {:try_start_f .. :try_end_1c} :catchall_d5

    :cond_1c
    :goto_1c
    :try_start_1c
    invoke-static {}, Lcom/amap/api/location/e;->b()Ljava/lang/String;

    move-result-object v0

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

    move-result v2

    if-nez v2, :cond_29

    invoke-static {v0}, Lcom/loc/ct;->a(Ljava/lang/String;)V
    :try_end_29
    .catch Ljava/lang/Throwable; {:try_start_1c .. :try_end_29} :catch_c9
    .catchall {:try_start_1c .. :try_end_29} :catchall_d5

    :cond_29
    :goto_29
    :try_start_29
    iget-object v0, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-virtual {p1, v0}, Lcom/loc/ax;->a(Landroid/content/Context;)V

    iget-object v0, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {p1, v0}, Lcom/loc/ax;->a(Lcom/amap/api/location/AMapLocationClientOption;)V

    iget-object v0, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-virtual {p1}, Lcom/loc/ax;->h()V
    :try_end_38
    .catch Ljava/lang/Throwable; {:try_start_29 .. :try_end_38} :catch_dc
    .catchall {:try_start_29 .. :try_end_38} :catchall_d5

    :goto_38
    :try_start_38
    invoke-direct {p0, p1}, Lcom/loc/ce;->a(Lcom/loc/ax;)Lcom/autonavi/aps/amapapi/model/AMapLocationServer;
    :try_end_3b
    .catch Ljava/lang/Throwable; {:try_start_38 .. :try_end_3b} :catch_b6
    .catchall {:try_start_38 .. :try_end_3b} :catchall_d5

    move-result-object v2

    if-nez v2, :cond_12b

    const/4 v0, 0x0

    :try_start_3f
    invoke-virtual {p1, v0}, Lcom/loc/ax;->a(Z)Lcom/autonavi/aps/amapapi/model/AMapLocationServer;
    :try_end_42
    .catch Ljava/lang/Throwable; {:try_start_3f .. :try_end_42} :catch_e8
    .catchall {:try_start_3f .. :try_end_42} :catchall_d5

    move-result-object v2

    :goto_43
    :try_start_43
    invoke-static {}, Lcom/loc/cj;->b()J

    move-result-wide v6

    invoke-virtual {v5, v6, v7}, Lcom/loc/cf;->b(J)V

    invoke-virtual {v5, v2}, Lcom/loc/cf;->a(Lcom/autonavi/aps/amapapi/model/AMapLocationServer;)V

    if-eqz v2, :cond_128

    invoke-virtual {v2}, Lcom/autonavi/aps/amapapi/model/AMapLocationServer;->k()Ljava/lang/String;
    :try_end_52
    .catch Ljava/lang/Throwable; {:try_start_43 .. :try_end_52} :catch_f4
    .catchall {:try_start_43 .. :try_end_52} :catchall_d5

    move-result-object v0

    :goto_53
    :try_start_53
    iget-object v4, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v4}, Lcom/amap/api/location/AMapLocationClientOption;->isLocationCacheEnable()Z

    move-result v4

    if-eqz v4, :cond_100

    iget-object v4, p0, Lcom/loc/ce;->i:Lcom/loc/co;

    if-eqz v4, :cond_100

    iget-object v4, p0, Lcom/loc/ce;->i:Lcom/loc/co;

    invoke-static {}, Lcom/amap/api/location/e;->a()J

    move-result-wide v6

    invoke-virtual {v4, v2, v0, v6, v7}, Lcom/loc/co;->a(Lcom/amap/api/location/AMapLocation;Ljava/lang/String;J)Lcom/amap/api/location/AMapLocation;
    :try_end_68
    .catch Ljava/lang/Throwable; {:try_start_53 .. :try_end_68} :catch_f6
    .catchall {:try_start_53 .. :try_end_68} :catchall_d5

    move-result-object v0

    :goto_69
    :try_start_69
    new-instance v4, Landroid/os/Bundle;

    invoke-direct {v4}, Landroid/os/Bundle;-><init>()V

    if-eqz v2, :cond_80

    const-string/jumbo v6, "loc"

    invoke-virtual {v4, v6, v0}, Landroid/os/Bundle;->putParcelable(Ljava/lang/String;Landroid/os/Parcelable;)V

    const-string/jumbo v0, "nb"

    invoke-virtual {v2}, Lcom/autonavi/aps/amapapi/model/AMapLocationServer;->k()Ljava/lang/String;

    move-result-object v6

    invoke-virtual {v4, v0, v6}, Landroid/os/Bundle;->putString(Ljava/lang/String;Ljava/lang/String;)V

    :cond_80
    invoke-static {}, Landroid/os/Message;->obtain()Landroid/os/Message;

    move-result-object v0

    invoke-virtual {v0, v4}, Landroid/os/Message;->setData(Landroid/os/Bundle;)V

    const/4 v4, 0x1

    iput v4, v0, Landroid/os/Message;->what:I

    iget-object v4, p0, Lcom/loc/ce;->b:Lcom/loc/ce$c;

    invoke-virtual {v4, v0}, Lcom/loc/ce$c;->sendMessage(Landroid/os/Message;)Z
    :try_end_8f
    .catch Ljava/lang/Throwable; {:try_start_69 .. :try_end_8f} :catch_103
    .catchall {:try_start_69 .. :try_end_8f} :catchall_d5

    :goto_8f
    :try_start_8f
    iget-object v0, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-static {v0, v5}, Lcom/loc/cg;->a(Landroid/content/Context;Lcom/loc/cf;)V
    :try_end_94
    .catch Ljava/lang/Throwable; {:try_start_8f .. :try_end_94} :catch_f4
    .catchall {:try_start_8f .. :try_end_94} :catchall_d5

    if-eqz v3, :cond_a4

    const/4 v0, 0x1

    :try_start_97
    invoke-virtual {p1, v0}, Lcom/loc/ax;->a(Z)Lcom/autonavi/aps/amapapi/model/AMapLocationServer;
    :try_end_9a
    .catch Ljava/lang/Throwable; {:try_start_97 .. :try_end_9a} :catch_10e
    .catchall {:try_start_97 .. :try_end_9a} :catchall_d5

    move-result-object v1

    :goto_9b
    :try_start_9b
    invoke-virtual {v1}, Lcom/autonavi/aps/amapapi/model/AMapLocationServer;->getErrorCode()I
    :try_end_9e
    .catch Ljava/lang/Throwable; {:try_start_9b .. :try_end_9e} :catch_f4
    .catchall {:try_start_9b .. :try_end_9e} :catchall_d5

    move-result v0

    if-nez v0, :cond_a4

    :try_start_a1
    invoke-virtual {p1, v1}, Lcom/loc/ax;->a(Lcom/autonavi/aps/amapapi/model/AMapLocationServer;)V
    :try_end_a4
    .catch Ljava/lang/Throwable; {:try_start_a1 .. :try_end_a4} :catch_119
    .catchall {:try_start_a1 .. :try_end_a4} :catchall_d5

    :cond_a4
    :goto_a4
    if-eqz p1, :cond_a9

    :try_start_a6
    invoke-virtual {p1}, Lcom/loc/ax;->e()V
    :try_end_a9
    .catch Ljava/lang/Throwable; {:try_start_a6 .. :try_end_a9} :catch_124

    :cond_a9
    :goto_a9
    return-object v2

    :catch_aa
    move-exception v0

    :try_start_ab
    const-string/jumbo v2, "AMapLocationManager"

    const-string/jumbo v6, "apsLocation setAuthKey"

    invoke-static {v0, v2, v6}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_b4
    .catch Ljava/lang/Throwable; {:try_start_ab .. :try_end_b4} :catch_b6
    .catchall {:try_start_ab .. :try_end_b4} :catchall_d5

    goto/16 :goto_1c

    :catch_b6
    move-exception v0

    move-object v2, v1

    :goto_b8
    :try_start_b8
    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v3, "apsLocation"

    invoke-static {v0, v1, v3}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_c1
    .catchall {:try_start_b8 .. :try_end_c1} :catchall_d5

    if-eqz p1, :cond_a9

    :try_start_c3
    invoke-virtual {p1}, Lcom/loc/ax;->e()V
    :try_end_c6
    .catch Ljava/lang/Throwable; {:try_start_c3 .. :try_end_c6} :catch_c7

    goto :goto_a9

    :catch_c7
    move-exception v0

    goto :goto_a9

    :catch_c9
    move-exception v0

    :try_start_ca
    const-string/jumbo v2, "AMapLocationManager"

    const-string/jumbo v6, "apsLocation setUmidToken"

    invoke-static {v0, v2, v6}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_d3
    .catch Ljava/lang/Throwable; {:try_start_ca .. :try_end_d3} :catch_b6
    .catchall {:try_start_ca .. :try_end_d3} :catchall_d5

    goto/16 :goto_29

    :catchall_d5
    move-exception v0

    if-eqz p1, :cond_db

    :try_start_d8
    invoke-virtual {p1}, Lcom/loc/ax;->e()V
    :try_end_db
    .catch Ljava/lang/Throwable; {:try_start_d8 .. :try_end_db} :catch_126

    :cond_db
    :goto_db
    throw v0

    :catch_dc
    move-exception v0

    :try_start_dd
    const-string/jumbo v2, "AMapLocationManager"

    const-string/jumbo v6, "initApsBase"

    invoke-static {v0, v2, v6}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_e6
    .catch Ljava/lang/Throwable; {:try_start_dd .. :try_end_e6} :catch_b6
    .catchall {:try_start_dd .. :try_end_e6} :catchall_d5

    goto/16 :goto_38

    :catch_e8
    move-exception v0

    :try_start_e9
    const-string/jumbo v4, "AMapLocationManager"

    const-string/jumbo v6, "apsLocation:doFirstNetLocate"

    invoke-static {v0, v4, v6}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto/16 :goto_43

    :catch_f4
    move-exception v0

    goto :goto_b8

    :catch_f6
    move-exception v0

    const-string/jumbo v4, "AMapLocationManager"

    const-string/jumbo v6, "fixLastLocation"

    invoke-static {v0, v4, v6}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    :cond_100
    move-object v0, v2

    goto/16 :goto_69

    :catch_103
    move-exception v0

    const-string/jumbo v4, "AMapLocationManager"

    const-string/jumbo v6, "apsLocation:callback"

    invoke-static {v0, v4, v6}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_8f

    :catch_10e
    move-exception v0

    const-string/jumbo v3, "AMapLocationManager"

    const-string/jumbo v4, "apsLocation:doFirstNetLocate 2"

    invoke-static {v0, v3, v4}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_9b

    :catch_119
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v3, "apsLocation:doFirstAddCache"

    invoke-static {v0, v1, v3}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_123
    .catch Ljava/lang/Throwable; {:try_start_e9 .. :try_end_123} :catch_f4
    .catchall {:try_start_e9 .. :try_end_123} :catchall_d5

    goto :goto_a4

    :catch_124
    move-exception v0

    goto :goto_a9

    :catch_126
    move-exception v1

    goto :goto_db

    :cond_128
    move-object v0, v1

    goto/16 :goto_53

    :cond_12b
    move v3, v4

    goto/16 :goto_43
.end method

.method static synthetic b(Lcom/loc/ce;)V
    .registers 1

    invoke-direct {p0}, Lcom/loc/ce;->h()V

    return-void
.end method

.method static synthetic b(Lcom/loc/ce;Landroid/os/Bundle;)V
    .registers 3

    const/16 v0, 0xa

    invoke-direct {p0, v0, p1}, Lcom/loc/ce;->a(ILandroid/os/Bundle;)V

    return-void
.end method

.method static synthetic b(Lcom/loc/ce;Lcom/amap/api/location/b;)V
    .registers 3

    iget-object v0, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    invoke-virtual {v0}, Ljava/util/ArrayList;->isEmpty()Z

    move-result v0

    if-nez v0, :cond_15

    iget-object v0, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    invoke-virtual {v0, p1}, Ljava/util/ArrayList;->contains(Ljava/lang/Object;)Z

    move-result v0

    if-eqz v0, :cond_15

    iget-object v0, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    invoke-virtual {v0, p1}, Ljava/util/ArrayList;->remove(Ljava/lang/Object;)Z

    :cond_15
    iget-object v0, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    invoke-virtual {v0}, Ljava/util/ArrayList;->isEmpty()Z

    move-result v0

    if-eqz v0, :cond_20

    invoke-direct {p0}, Lcom/loc/ce;->j()V

    :cond_20
    return-void
.end method

.method static synthetic b(Lcom/loc/ce;Z)Z
    .registers 2

    iput-boolean p1, p0, Lcom/loc/ce;->A:Z

    return p1
.end method

.method static synthetic c(Lcom/loc/ce;)V
    .registers 1

    invoke-direct {p0}, Lcom/loc/ce;->i()V

    return-void
.end method

.method static synthetic d(Lcom/loc/ce;)V
    .registers 1

    invoke-direct {p0}, Lcom/loc/ce;->j()V

    return-void
.end method

.method static synthetic e(Lcom/loc/ce;)V
    .registers 5

    const/16 v0, 0x3f8

    const/4 v1, 0x0

    const-wide/16 v2, 0x3e8

    invoke-direct {p0, v0, v1, v2, v3}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V

    return-void
.end method

.method private f()V
    .registers 4

    iget-object v1, p0, Lcom/loc/ce;->q:Ljava/lang/Object;

    monitor-enter v1

    :try_start_3
    iget-object v0, p0, Lcom/loc/ce;->v:Lcom/loc/ce$a;

    if-eqz v0, :cond_e

    iget-object v0, p0, Lcom/loc/ce;->v:Lcom/loc/ce$a;

    const/16 v2, 0x3f8

    invoke-virtual {v0, v2}, Lcom/loc/ce$a;->removeMessages(I)V

    :cond_e
    monitor-exit v1
    :try_end_f
    .catchall {:try_start_3 .. :try_end_f} :catchall_10

    return-void

    :catchall_10
    move-exception v0

    monitor-exit v1

    throw v0
.end method

.method static synthetic f(Lcom/loc/ce;)V
    .registers 6

    :try_start_0
    iget-boolean v0, p0, Lcom/loc/ce;->g:Z

    if-eqz v0, :cond_53

    const/4 v0, 0x0

    iput-boolean v0, p0, Lcom/loc/ce;->g:Z

    new-instance v0, Lcom/loc/ax;

    invoke-direct {v0}, Lcom/loc/ax;-><init>()V

    invoke-direct {p0, v0}, Lcom/loc/ce;->b(Lcom/loc/ax;)Lcom/autonavi/aps/amapapi/model/AMapLocationServer;

    move-result-object v1

    invoke-direct {p0}, Lcom/loc/ce;->g()Z

    move-result v0

    if-eqz v0, :cond_47

    new-instance v2, Landroid/os/Bundle;

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

    const-string/jumbo v0, "0"

    if-eqz v1, :cond_31

    invoke-virtual {v1}, Lcom/autonavi/aps/amapapi/model/AMapLocationServer;->getLocationType()I

    move-result v3

    const/4 v4, 0x2

    if-eq v3, v4, :cond_2e

    invoke-virtual {v1}, Lcom/autonavi/aps/amapapi/model/AMapLocationServer;->getLocationType()I

    move-result v1

    const/4 v3, 0x4

    if-ne v1, v3, :cond_31

    :cond_2e
    const-string/jumbo v0, "1"

    :cond_31
    const-string/jumbo v1, "optBundle"

    iget-object v3, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-static {v3}, Lcom/loc/ca;->b(Lcom/amap/api/location/AMapLocationClientOption;)Landroid/os/Bundle;

    move-result-object v3

    invoke-virtual {v2, v1, v3}, Landroid/os/Bundle;->putBundle(Ljava/lang/String;Landroid/os/Bundle;)V

    const-string/jumbo v1, "isCacheLoc"

    invoke-virtual {v2, v1, v0}, Landroid/os/Bundle;->putString(Ljava/lang/String;Ljava/lang/String;)V

    const/4 v0, 0x0

    invoke-direct {p0, v0, v2}, Lcom/loc/ce;->a(ILandroid/os/Bundle;)V
    :try_end_47
    .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_47} :catch_8b
    .catchall {:try_start_0 .. :try_end_47} :catchall_a3

    :cond_47
    :goto_47
    :try_start_47
    iget-object v0, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v0}, Lcom/amap/api/location/AMapLocationClientOption;->isOnceLocation()Z

    move-result v0

    if-nez v0, :cond_52

    invoke-direct {p0}, Lcom/loc/ce;->k()V
    :try_end_52
    .catch Ljava/lang/Throwable; {:try_start_47 .. :try_end_52} :catch_b2

    :cond_52
    :goto_52
    return-void

    :cond_53
    :try_start_53
    invoke-direct {p0}, Lcom/loc/ce;->g()Z

    move-result v0

    if-eqz v0, :cond_47

    new-instance v0, Landroid/os/Bundle;

    invoke-direct {v0}, Landroid/os/Bundle;-><init>()V

    const-string/jumbo v1, "optBundle"

    iget-object v2, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-static {v2}, Lcom/loc/ca;->b(Lcom/amap/api/location/AMapLocationClientOption;)Landroid/os/Bundle;

    move-result-object v2

    invoke-virtual {v0, v1, v2}, Landroid/os/Bundle;->putBundle(Ljava/lang/String;Landroid/os/Bundle;)V

    const-string/jumbo v1, "d"

    invoke-static {}, Lcom/amap/api/location/e;->b()Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v0, v1, v2}, Landroid/os/Bundle;->putString(Ljava/lang/String;Ljava/lang/String;)V

    const-string/jumbo v1, "e"

    invoke-static {}, Lcom/amap/api/location/e;->a()J

    move-result-wide v2

    invoke-virtual {v0, v1, v2, v3}, Landroid/os/Bundle;->putLong(Ljava/lang/String;J)V

    iget-object v1, p0, Lcom/loc/ce;->c:Lcom/loc/cn;

    invoke-virtual {v1}, Lcom/loc/cn;->c()Z

    move-result v1

    if-nez v1, :cond_47

    const/4 v1, 0x1

    invoke-direct {p0, v1, v0}, Lcom/loc/ce;->a(ILandroid/os/Bundle;)V
    :try_end_8a
    .catch Ljava/lang/Throwable; {:try_start_53 .. :try_end_8a} :catch_8b
    .catchall {:try_start_53 .. :try_end_8a} :catchall_a3

    goto :goto_47

    :catch_8b
    move-exception v0

    :try_start_8c
    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "doLBSLocation"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_95
    .catchall {:try_start_8c .. :try_end_95} :catchall_a3

    :try_start_95
    iget-object v0, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v0}, Lcom/amap/api/location/AMapLocationClientOption;->isOnceLocation()Z

    move-result v0

    if-nez v0, :cond_52

    invoke-direct {p0}, Lcom/loc/ce;->k()V
    :try_end_a0
    .catch Ljava/lang/Throwable; {:try_start_95 .. :try_end_a0} :catch_a1

    goto :goto_52

    :catch_a1
    move-exception v0

    goto :goto_52

    :catchall_a3
    move-exception v0

    :try_start_a4
    iget-object v1, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v1}, Lcom/amap/api/location/AMapLocationClientOption;->isOnceLocation()Z

    move-result v1

    if-nez v1, :cond_af

    invoke-direct {p0}, Lcom/loc/ce;->k()V
    :try_end_af
    .catch Ljava/lang/Throwable; {:try_start_a4 .. :try_end_af} :catch_b0

    :cond_af
    :goto_af
    throw v0

    :catch_b0
    move-exception v1

    goto :goto_af

    :catch_b2
    move-exception v0

    goto :goto_52
.end method

.method static synthetic g(Lcom/loc/ce;)V
    .registers 4

    iget-object v0, p0, Lcom/loc/ce;->c:Lcom/loc/cn;

    iget-object v1, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    iput-object v1, v0, Lcom/loc/cn;->c:Lcom/amap/api/location/AMapLocationClientOption;

    iget-object v1, v0, Lcom/loc/cn;->c:Lcom/amap/api/location/AMapLocationClientOption;

    if-nez v1, :cond_11

    new-instance v1, Lcom/amap/api/location/AMapLocationClientOption;

    invoke-direct {v1}, Lcom/amap/api/location/AMapLocationClientOption;-><init>()V

    iput-object v1, v0, Lcom/loc/cn;->c:Lcom/amap/api/location/AMapLocationClientOption;

    :cond_11
    iget-object v1, v0, Lcom/loc/cn;->c:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v1}, Lcom/amap/api/location/AMapLocationClientOption;->getLocationMode()Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;

    move-result-object v1

    sget-object v2, Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;->b:Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;

    if-eq v1, v2, :cond_26

    iget-object v1, v0, Lcom/loc/cn;->a:Landroid/os/Handler;

    if-eqz v1, :cond_26

    iget-object v0, v0, Lcom/loc/cn;->a:Landroid/os/Handler;

    const/16 v1, 0x8

    invoke-virtual {v0, v1}, Landroid/os/Handler;->removeMessages(I)V

    :cond_26
    iget-boolean v0, p0, Lcom/loc/ce;->z:Z

    if-eqz v0, :cond_3e

    iget-object v0, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v0}, Lcom/amap/api/location/AMapLocationClientOption;->getLocationMode()Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;

    move-result-object v0

    iget-object v1, p0, Lcom/loc/ce;->p:Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;

    invoke-virtual {v0, v1}, Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;->equals(Ljava/lang/Object;)Z

    move-result v0

    if-nez v0, :cond_3e

    invoke-direct {p0}, Lcom/loc/ce;->j()V

    invoke-direct {p0}, Lcom/loc/ce;->i()V

    :cond_3e
    iget-object v0, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v0}, Lcom/amap/api/location/AMapLocationClientOption;->getLocationMode()Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;

    move-result-object v0

    iput-object v0, p0, Lcom/loc/ce;->p:Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;

    iget-object v0, p0, Lcom/loc/ce;->r:Lcom/loc/cg;

    if-eqz v0, :cond_63

    iget-object v0, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v0}, Lcom/amap/api/location/AMapLocationClientOption;->isOnceLocation()Z

    move-result v0

    if-eqz v0, :cond_64

    iget-object v0, p0, Lcom/loc/ce;->r:Lcom/loc/cg;

    iget-object v1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    const/4 v2, 0x0

    invoke-virtual {v0, v1, v2}, Lcom/loc/cg;->a(Landroid/content/Context;I)V

    :goto_5a
    iget-object v0, p0, Lcom/loc/ce;->r:Lcom/loc/cg;

    iget-object v1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    iget-object v2, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v0, v1, v2}, Lcom/loc/cg;->a(Landroid/content/Context;Lcom/amap/api/location/AMapLocationClientOption;)V

    :cond_63
    return-void

    :cond_64
    iget-object v0, p0, Lcom/loc/ce;->r:Lcom/loc/cg;

    iget-object v1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    const/4 v2, 0x1

    invoke-virtual {v0, v1, v2}, Lcom/loc/cg;->a(Landroid/content/Context;I)V

    goto :goto_5a
.end method

.method private g()Z
    .registers 7

    const/4 v0, 0x1

    const/4 v1, 0x0

    move v2, v1

    :cond_3
    :try_start_3
    iget-object v3, p0, Lcom/loc/ce;->j:Landroid/os/Messenger;

    if-nez v3, :cond_12

    const-wide/16 v4, 0x64

    invoke-static {v4, v5}, Ljava/lang/Thread;->sleep(J)V

    add-int/lit8 v2, v2, 0x1

    const/16 v3, 0x32

    if-lt v2, v3, :cond_3

    :cond_12
    iget-object v2, p0, Lcom/loc/ce;->j:Landroid/os/Messenger;

    if-nez v2, :cond_44

    invoke-static {}, Landroid/os/Message;->obtain()Landroid/os/Message;

    move-result-object v0

    new-instance v2, Landroid/os/Bundle;

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

    new-instance v3, Lcom/amap/api/location/AMapLocation;

    const-string/jumbo v4, ""

    invoke-direct {v3, v4}, Lcom/amap/api/location/AMapLocation;-><init>(Ljava/lang/String;)V

    const/16 v4, 0xa

    invoke-virtual {v3, v4}, Lcom/amap/api/location/AMapLocation;->setErrorCode(I)V

    const-string/jumbo v4, "\u8bf7\u68c0\u67e5\u914d\u7f6e\u6587\u4ef6\u662f\u5426\u914d\u7f6e\u670d\u52a1\uff0c\u5e76\u4e14manifest\u4e2dservice\u6807\u7b7e\u662f\u5426\u914d\u7f6e\u5728application\u6807\u7b7e\u5185"

    invoke-virtual {v3, v4}, Lcom/amap/api/location/AMapLocation;->setLocationDetail(Ljava/lang/String;)V

    const-string/jumbo v4, "loc"

    invoke-virtual {v2, v4, v3}, Landroid/os/Bundle;->putParcelable(Ljava/lang/String;Landroid/os/Parcelable;)V

    invoke-virtual {v0, v2}, Landroid/os/Message;->setData(Landroid/os/Bundle;)V

    const/4 v2, 0x1

    iput v2, v0, Landroid/os/Message;->what:I

    iget-object v2, p0, Lcom/loc/ce;->b:Lcom/loc/ce$c;

    invoke-virtual {v2, v0}, Lcom/loc/ce$c;->sendMessage(Landroid/os/Message;)Z
    :try_end_43
    .catch Ljava/lang/Throwable; {:try_start_3 .. :try_end_43} :catch_4d

    move v0, v1

    :cond_44
    :goto_44
    if-nez v0, :cond_4c

    const/4 v1, 0x0

    const/16 v2, 0x835

    invoke-static {v1, v2}, Lcom/loc/cg;->a(Ljava/lang/String;I)V

    :cond_4c
    return v0

    :catch_4d
    move-exception v0

    const-string/jumbo v2, "AMapLocationManager"

    const-string/jumbo v3, "checkAPSManager"

    invoke-static {v0, v2, v3}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    move v0, v1

    goto :goto_44
.end method

.method private h()V
    .registers 5

    :try_start_0
    new-instance v0, Landroid/content/Intent;

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

    new-instance v1, Landroid/content/ComponentName;

    const-string/jumbo v2, "com.autonavi.minimap"

    invoke-static {}, Lcom/loc/bz;->l()Ljava/lang/String;

    move-result-object v3

    invoke-direct {v1, v2, v3}, Landroid/content/ComponentName;-><init>(Ljava/lang/String;Ljava/lang/String;)V

    invoke-virtual {v0, v1}, Landroid/content/Intent;->setComponent(Landroid/content/ComponentName;)Landroid/content/Intent;

    const/high16 v1, 0x10000000

    invoke-virtual {v0, v1}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;

    invoke-static {}, Lcom/loc/bz;->j()Ljava/lang/String;

    move-result-object v1

    invoke-static {v1}, Landroid/net/Uri;->parse(Ljava/lang/String;)Landroid/net/Uri;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroid/content/Intent;->setData(Landroid/net/Uri;)Landroid/content/Intent;

    iget-object v1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-virtual {v1, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
    :try_end_29
    .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_29} :catch_2a

    :goto_29
    return-void

    :catch_2a
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "callAMap part1"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    :try_start_34
    new-instance v0, Landroid/content/Intent;

    const-string/jumbo v1, "android.intent.action.VIEW"

    invoke-static {}, Lcom/loc/bz;->k()Ljava/lang/String;

    move-result-object v2

    invoke-static {v2}, Landroid/net/Uri;->parse(Ljava/lang/String;)Landroid/net/Uri;

    move-result-object v2

    invoke-direct {v0, v1, v2}, Landroid/content/Intent;-><init>(Ljava/lang/String;Landroid/net/Uri;)V

    const/high16 v1, 0x10000000

    invoke-virtual {v0, v1}, Landroid/content/Intent;->setFlags(I)Landroid/content/Intent;

    iget-object v1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-virtual {v1, v0}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V
    :try_end_4e
    .catch Ljava/lang/Throwable; {:try_start_34 .. :try_end_4e} :catch_4f

    goto :goto_29

    :catch_4f
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "callAMap part2"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_29
.end method

.method static synthetic h(Lcom/loc/ce;)V
    .registers 5

    :try_start_0
    iget-object v0, p0, Lcom/loc/ce;->j:Landroid/os/Messenger;

    if-eqz v0, :cond_1d

    const/4 v0, 0x0

    iput v0, p0, Lcom/loc/ce;->m:I

    new-instance v0, Landroid/os/Bundle;

    invoke-direct {v0}, Landroid/os/Bundle;-><init>()V

    const-string/jumbo v1, "optBundle"

    iget-object v2, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-static {v2}, Lcom/loc/ca;->b(Lcom/amap/api/location/AMapLocationClientOption;)Landroid/os/Bundle;

    move-result-object v2

    invoke-virtual {v0, v1, v2}, Landroid/os/Bundle;->putBundle(Ljava/lang/String;Landroid/os/Bundle;)V

    const/4 v1, 0x2

    invoke-direct {p0, v1, v0}, Lcom/loc/ce;->a(ILandroid/os/Bundle;)V

    :cond_1c
    :goto_1c
    return-void

    :cond_1d
    iget v0, p0, Lcom/loc/ce;->m:I

    add-int/lit8 v0, v0, 0x1

    iput v0, p0, Lcom/loc/ce;->m:I

    iget v0, p0, Lcom/loc/ce;->m:I

    const/16 v1, 0xa

    if-ge v0, v1, :cond_1c

    const/16 v0, 0x3f0

    const/4 v1, 0x0

    const-wide/16 v2, 0x32

    invoke-direct {p0, v0, v1, v2, v3}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V
    :try_end_31
    .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_31} :catch_32

    goto :goto_1c

    :catch_32
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "startAssistantLocationImpl"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_1c
.end method

.method private i()V
    .registers 8

    const/16 v6, 0x3f8

    const/16 v5, 0x3f7

    const-wide/16 v0, 0x0

    const/4 v4, 0x0

    iget-object v2, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    if-nez v2, :cond_12

    new-instance v2, Lcom/amap/api/location/AMapLocationClientOption;

    invoke-direct {v2}, Lcom/amap/api/location/AMapLocationClientOption;-><init>()V

    iput-object v2, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    :cond_12
    iget-boolean v2, p0, Lcom/loc/ce;->z:Z

    if-eqz v2, :cond_17

    :goto_16
    return-void

    :cond_17
    const/4 v2, 0x1

    iput-boolean v2, p0, Lcom/loc/ce;->z:Z

    sget-object v2, Lcom/loc/ce$4;->a:[I

    iget-object v3, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v3}, Lcom/amap/api/location/AMapLocationClientOption;->getLocationMode()Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;

    move-result-object v3

    invoke-virtual {v3}, Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;->ordinal()I

    move-result v3

    aget v2, v2, v3

    packed-switch v2, :pswitch_data_56

    goto :goto_16

    :pswitch_2c
    const/16 v2, 0x3f9

    invoke-direct {p0, v2, v4, v0, v1}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V

    invoke-direct {p0, v6, v4, v0, v1}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V

    goto :goto_16

    :pswitch_35
    invoke-direct {p0}, Lcom/loc/ce;->f()V

    invoke-direct {p0, v5, v4, v0, v1}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V

    goto :goto_16

    :pswitch_3c
    invoke-direct {p0, v5, v4, v0, v1}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V

    iget-object v2, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v2}, Lcom/amap/api/location/AMapLocationClientOption;->isGpsFirst()Z

    move-result v2

    if-eqz v2, :cond_51

    iget-object v2, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v2}, Lcom/amap/api/location/AMapLocationClientOption;->isOnceLocation()Z

    move-result v2

    if-eqz v2, :cond_51

    const-wide/16 v0, 0x7530

    :cond_51
    invoke-direct {p0, v6, v4, v0, v1}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V

    goto :goto_16

    nop

    :pswitch_data_56
    .packed-switch 0x1
        :pswitch_2c
        :pswitch_35
        :pswitch_3c
    .end packed-switch
.end method

.method static synthetic i(Lcom/loc/ce;)V
    .registers 4

    :try_start_0
    new-instance v0, Landroid/os/Bundle;

    invoke-direct {v0}, Landroid/os/Bundle;-><init>()V

    const-string/jumbo v1, "optBundle"

    iget-object v2, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-static {v2}, Lcom/loc/ca;->b(Lcom/amap/api/location/AMapLocationClientOption;)Landroid/os/Bundle;

    move-result-object v2

    invoke-virtual {v0, v1, v2}, Landroid/os/Bundle;->putBundle(Ljava/lang/String;Landroid/os/Bundle;)V

    const/4 v1, 0x3

    invoke-direct {p0, v1, v0}, Lcom/loc/ce;->a(ILandroid/os/Bundle;)V
    :try_end_15
    .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_15} :catch_16

    :goto_15
    return-void

    :catch_16
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "stopAssistantLocationImpl"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_15
.end method

.method private j()V
    .registers 4

    :try_start_0
    iget-object v0, p0, Lcom/loc/ce;->c:Lcom/loc/cn;

    if-eqz v0, :cond_9

    iget-object v0, p0, Lcom/loc/ce;->c:Lcom/loc/cn;

    invoke-virtual {v0}, Lcom/loc/cn;->a()V

    :cond_9
    invoke-direct {p0}, Lcom/loc/ce;->f()V

    const/4 v0, 0x0

    iput-boolean v0, p0, Lcom/loc/ce;->z:Z

    const/4 v0, 0x0

    iput v0, p0, Lcom/loc/ce;->m:I
    :try_end_12
    .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_12} :catch_13

    :goto_12
    return-void

    :catch_13
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "stopLocation"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_12
.end method

.method private k()V
    .registers 7

    const-wide/16 v0, 0x3e8

    iget-object v2, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v2}, Lcom/amap/api/location/AMapLocationClientOption;->getLocationMode()Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;

    move-result-object v2

    sget-object v3, Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;->b:Lcom/amap/api/location/AMapLocationClientOption$AMapLocationMode;

    if-eq v2, v3, :cond_1c

    const/16 v2, 0x3f8

    const/4 v3, 0x0

    iget-object v4, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v4}, Lcom/amap/api/location/AMapLocationClientOption;->getInterval()J

    move-result-wide v4

    cmp-long v4, v4, v0

    if-gez v4, :cond_1d

    :goto_19
    invoke-direct {p0, v2, v3, v0, v1}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V

    :cond_1c
    return-void

    :cond_1d
    iget-object v0, p0, Lcom/loc/ce;->a:Lcom/amap/api/location/AMapLocationClientOption;

    invoke-virtual {v0}, Lcom/amap/api/location/AMapLocationClientOption;->getInterval()J

    move-result-wide v0

    goto :goto_19
.end method


# virtual methods
.method public a()V
    .registers 5

    const/16 v0, 0x3eb

    const/4 v1, 0x0

    const-wide/16 v2, 0x0

    :try_start_5
    invoke-direct {p0, v0, v1, v2, v3}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V
    :try_end_8
    .catch Ljava/lang/Throwable; {:try_start_5 .. :try_end_8} :catch_9

    :goto_8
    return-void

    :catch_9
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "startLocation"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_8
.end method

.method final a(Landroid/content/Intent;)V
    .registers 5

    :try_start_0
    iget-object v0, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    iget-object v1, p0, Lcom/loc/ce;->B:Landroid/content/ServiceConnection;

    const/4 v2, 0x1

    invoke-virtual {v0, p1, v1, v2}, Landroid/content/Context;->bindService(Landroid/content/Intent;Landroid/content/ServiceConnection;I)Z
    :try_end_8
    .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_8} :catch_9

    :goto_8
    return-void

    :catch_9
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "startServiceImpl"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_8
.end method

.method public a(Lcom/amap/api/location/AMapLocationClientOption;)V
    .registers 6

    const/16 v0, 0x3fa

    :try_start_2
    invoke-virtual {p1}, Lcom/amap/api/location/AMapLocationClientOption;->clone()Lcom/amap/api/location/AMapLocationClientOption;

    move-result-object v1

    const-wide/16 v2, 0x0

    invoke-direct {p0, v0, v1, v2, v3}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V
    :try_end_b
    .catch Ljava/lang/Throwable; {:try_start_2 .. :try_end_b} :catch_c

    :goto_b
    return-void

    :catch_c
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "setLocationOption"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_b
.end method

.method public a(Lcom/amap/api/location/b;)V
    .registers 6

    const/16 v0, 0x3ea

    const-wide/16 v2, 0x0

    :try_start_4
    invoke-direct {p0, v0, p1, v2, v3}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V
    :try_end_7
    .catch Ljava/lang/Throwable; {:try_start_4 .. :try_end_7} :catch_8

    :goto_7
    return-void

    :catch_8
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "setLocationListener"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_7
.end method

.method public b()V
    .registers 5

    const/16 v0, 0x3ec

    const/4 v1, 0x0

    const-wide/16 v2, 0x0

    :try_start_5
    invoke-direct {p0, v0, v1, v2, v3}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V
    :try_end_8
    .catch Ljava/lang/Throwable; {:try_start_5 .. :try_end_8} :catch_9

    :goto_8
    return-void

    :catch_9
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "stopLocation"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_8
.end method

.method public b(Lcom/amap/api/location/b;)V
    .registers 6

    const/16 v0, 0x3ed

    const-wide/16 v2, 0x0

    :try_start_4
    invoke-direct {p0, v0, p1, v2, v3}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V
    :try_end_7
    .catch Ljava/lang/Throwable; {:try_start_4 .. :try_end_7} :catch_8

    :goto_7
    return-void

    :catch_8
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "unRegisterLocationListener"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_7
.end method

.method public c()V
    .registers 5

    const/16 v0, 0x3f3

    const/4 v1, 0x0

    const-wide/16 v2, 0x0

    :try_start_5
    invoke-direct {p0, v0, v1, v2, v3}, Lcom/loc/ce;->a(ILjava/lang/Object;J)V

    const/4 v0, 0x1

    iput-boolean v0, p0, Lcom/loc/ce;->o:Z
    :try_end_b
    .catch Ljava/lang/Throwable; {:try_start_5 .. :try_end_b} :catch_c

    :goto_b
    return-void

    :catch_c
    move-exception v0

    const-string/jumbo v1, "AMapLocationManager"

    const-string/jumbo v2, "onDestroy"

    invoke-static {v0, v1, v2}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_b
.end method

.method final d()V
    .registers 6

    const/4 v2, 0x1

    const/4 v1, 0x0

    const/4 v4, 0x0

    const/16 v0, 0xc

    invoke-direct {p0, v0, v4}, Lcom/loc/ce;->a(ILandroid/os/Bundle;)V

    iput-boolean v2, p0, Lcom/loc/ce;->g:Z

    iput-boolean v2, p0, Lcom/loc/ce;->h:Z

    iput-boolean v1, p0, Lcom/loc/ce;->y:Z

    invoke-direct {p0}, Lcom/loc/ce;->j()V

    iget-object v0, p0, Lcom/loc/ce;->r:Lcom/loc/cg;

    if-eqz v0, :cond_1c

    iget-object v0, p0, Lcom/loc/ce;->r:Lcom/loc/cg;

    iget-object v1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-virtual {v0, v1}, Lcom/loc/cg;->b(Landroid/content/Context;)V

    :cond_1c
    iget-object v0, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-static {v0}, Lcom/loc/cg;->a(Landroid/content/Context;)V

    iget-object v0, p0, Lcom/loc/ce;->e:Lcom/loc/a;

    if-eqz v0, :cond_2a

    iget-object v0, p0, Lcom/loc/ce;->e:Lcom/loc/a;

    invoke-virtual {v0}, Lcom/loc/a;->a()V

    :cond_2a
    iget-object v0, p0, Lcom/loc/ce;->s:Lcom/loc/cl;

    if-eqz v0, :cond_85

    iget-object v0, p0, Lcom/loc/ce;->s:Lcom/loc/cl;

    invoke-virtual {v0}, Lcom/loc/cl;->b()Landroid/os/Handler;

    move-result-object v0

    const/16 v1, 0xb

    invoke-virtual {v0, v1}, Landroid/os/Handler;->sendEmptyMessage(I)Z

    :cond_39
    :goto_39
    iget-object v0, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    if-eqz v0, :cond_44

    iget-object v0, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    invoke-virtual {v0}, Ljava/util/ArrayList;->clear()V

    iput-object v4, p0, Lcom/loc/ce;->d:Ljava/util/ArrayList;

    :cond_44
    iput-object v4, p0, Lcom/loc/ce;->B:Landroid/content/ServiceConnection;

    iget-object v1, p0, Lcom/loc/ce;->q:Ljava/lang/Object;

    monitor-enter v1

    :try_start_49
    iget-object v0, p0, Lcom/loc/ce;->v:Lcom/loc/ce$a;

    if-eqz v0, :cond_53

    iget-object v0, p0, Lcom/loc/ce;->v:Lcom/loc/ce$a;

    const/4 v2, 0x0

    invoke-virtual {v0, v2}, Lcom/loc/ce$a;->removeCallbacksAndMessages(Ljava/lang/Object;)V

    :cond_53
    const/4 v0, 0x0

    iput-object v0, p0, Lcom/loc/ce;->v:Lcom/loc/ce$a;

    monitor-exit v1
    :try_end_57
    .catchall {:try_start_49 .. :try_end_57} :catchall_91

    iget-object v0, p0, Lcom/loc/ce;->n:Lcom/loc/ce$b;

    if-eqz v0, :cond_6e

    sget v0, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v1, 0x12

    if-lt v0, v1, :cond_9b

    :try_start_61
    iget-object v0, p0, Lcom/loc/ce;->n:Lcom/loc/ce$b;

    const-class v1, Landroid/os/HandlerThread;

    const-string/jumbo v2, "quitSafely"

    const/4 v3, 0x0

    new-array v3, v3, [Ljava/lang/Object;

    invoke-static {v0, v1, v2, v3}, Lcom/loc/cd;->a(Ljava/lang/Object;Ljava/lang/Class;Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/Object;
    :try_end_6e
    .catch Ljava/lang/Throwable; {:try_start_61 .. :try_end_6e} :catch_94

    :cond_6e
    :goto_6e
    iput-object v4, p0, Lcom/loc/ce;->n:Lcom/loc/ce$b;

    iget-object v0, p0, Lcom/loc/ce;->b:Lcom/loc/ce$c;

    if-eqz v0, :cond_79

    iget-object v0, p0, Lcom/loc/ce;->b:Lcom/loc/ce$c;

    invoke-virtual {v0, v4}, Lcom/loc/ce$c;->removeCallbacksAndMessages(Ljava/lang/Object;)V

    :cond_79
    iget-object v0, p0, Lcom/loc/ce;->i:Lcom/loc/co;

    if-eqz v0, :cond_84

    iget-object v0, p0, Lcom/loc/ce;->i:Lcom/loc/co;

    invoke-virtual {v0}, Lcom/loc/co;->c()V

    iput-object v4, p0, Lcom/loc/ce;->i:Lcom/loc/co;

    :cond_84
    return-void

    :cond_85
    iget-object v0, p0, Lcom/loc/ce;->B:Landroid/content/ServiceConnection;

    if-eqz v0, :cond_39

    iget-object v0, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    iget-object v1, p0, Lcom/loc/ce;->B:Landroid/content/ServiceConnection;

    invoke-virtual {v0, v1}, Landroid/content/Context;->unbindService(Landroid/content/ServiceConnection;)V

    goto :goto_39

    :catchall_91
    move-exception v0

    monitor-exit v1

    throw v0

    :catch_94
    move-exception v0

    iget-object v0, p0, Lcom/loc/ce;->n:Lcom/loc/ce$b;

    invoke-virtual {v0}, Lcom/loc/ce$b;->quit()Z

    goto :goto_6e

    :cond_9b
    iget-object v0, p0, Lcom/loc/ce;->n:Lcom/loc/ce$b;

    invoke-virtual {v0}, Lcom/loc/ce$b;->quit()Z

    goto :goto_6e
.end method

.method final e()Landroid/content/Intent;
    .registers 5

    iget-object v0, p0, Lcom/loc/ce;->l:Landroid/content/Intent;

    if-nez v0, :cond_f

    new-instance v0, Landroid/content/Intent;

    iget-object v1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    const-class v2, Lcom/amap/api/location/APSService;

    invoke-direct {v0, v1, v2}, Landroid/content/Intent;-><init>(Landroid/content/Context;Ljava/lang/Class;)V

    iput-object v0, p0, Lcom/loc/ce;->l:Landroid/content/Intent;

    :cond_f
    const-string/jumbo v0, ""

    :try_start_12
    invoke-static {}, Lcom/amap/api/location/AMapLocationClientOption;->getAPIKEY()Ljava/lang/String;

    move-result-object v1

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

    move-result v1

    if-nez v1, :cond_45

    invoke-static {}, Lcom/amap/api/location/AMapLocationClientOption;->getAPIKEY()Ljava/lang/String;
    :try_end_1f
    .catch Ljava/lang/Throwable; {:try_start_12 .. :try_end_1f} :catch_4c

    move-result-object v0

    :goto_20
    iget-object v1, p0, Lcom/loc/ce;->l:Landroid/content/Intent;

    const-string/jumbo v2, "a"

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

    iget-object v0, p0, Lcom/loc/ce;->l:Landroid/content/Intent;

    const-string/jumbo v1, "b"

    iget-object v2, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-static {v2}, Lcom/loc/cq;->c(Landroid/content/Context;)Ljava/lang/String;

    move-result-object v2

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

    iget-object v0, p0, Lcom/loc/ce;->l:Landroid/content/Intent;

    const-string/jumbo v1, "d"

    invoke-static {}, Lcom/amap/api/location/e;->b()Ljava/lang/String;

    move-result-object v2

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

    iget-object v0, p0, Lcom/loc/ce;->l:Landroid/content/Intent;

    return-object v0

    :cond_45
    :try_start_45
    iget-object v1, p0, Lcom/loc/ce;->x:Landroid/content/Context;

    invoke-static {v1}, Lcom/loc/cq;->f(Landroid/content/Context;)Ljava/lang/String;
    :try_end_4a
    .catch Ljava/lang/Throwable; {:try_start_45 .. :try_end_4a} :catch_4c

    move-result-object v0

    goto :goto_20

    :catch_4c
    move-exception v1

    const-string/jumbo v2, "AMapLocationManager"

    const-string/jumbo v3, "startServiceImpl p2"

    invoke-static {v1, v2, v3}, Lcom/loc/ca;->a(Ljava/lang/Throwable;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_20
.end method