.class public final Lcom/google/android/gms/internal/ads/l;
.super Ljava/lang/Object;
.source ""

# interfaces
.implements Landroid/app/Application$ActivityLifecycleCallbacks;


# annotations
.annotation build Landroid/annotation/TargetApi;
    value = 0xe
.end annotation


# instance fields
.field public A:J

.field public r:Landroid/app/Activity;

.field public s:Landroid/content/Context;

.field public final t:Ljava/lang/Object;

.field public u:Z

.field public v:Z

.field public final w:Ljava/util/List;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Ljava/util/List<",
            "Lz5/ye;",
            ">;"
        }
    .end annotation

    .annotation build Ljavax/annotation/concurrent/GuardedBy;
        value = "lock"
    .end annotation
.end field

.field public final x:Ljava/util/List;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Ljava/util/List<",
            "Lz5/df;",
            ">;"
        }
    .end annotation

    .annotation build Ljavax/annotation/concurrent/GuardedBy;
        value = "lock"
    .end annotation
.end field

.field public y:Ljava/lang/Runnable;

.field public z:Z


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

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

    new-instance v0, Ljava/lang/Object;

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

    iput-object v0, p0, Lcom/google/android/gms/internal/ads/l;->t:Ljava/lang/Object;

    const/4 v0, 0x1

    iput-boolean v0, p0, Lcom/google/android/gms/internal/ads/l;->u:Z

    const/4 v0, 0x0

    iput-boolean v0, p0, Lcom/google/android/gms/internal/ads/l;->v:Z

    new-instance v1, Ljava/util/ArrayList;

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

    iput-object v1, p0, Lcom/google/android/gms/internal/ads/l;->w:Ljava/util/List;

    new-instance v1, Ljava/util/ArrayList;

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

    iput-object v1, p0, Lcom/google/android/gms/internal/ads/l;->x:Ljava/util/List;

    iput-boolean v0, p0, Lcom/google/android/gms/internal/ads/l;->z:Z

    return-void
.end method


# virtual methods
.method public final a(Landroid/app/Activity;)V
    .registers 5

    iget-object v0, p0, Lcom/google/android/gms/internal/ads/l;->t:Ljava/lang/Object;

    monitor-enter v0

    :try_start_3
    invoke-virtual {p1}, Ljava/lang/Object;->getClass()Ljava/lang/Class;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/Class;->getName()Ljava/lang/String;

    move-result-object v1

    const-string v2, "com.google.android.gms.ads"

    invoke-virtual {v1, v2}, Ljava/lang/String;->startsWith(Ljava/lang/String;)Z

    move-result v1

    if-nez v1, :cond_15

    iput-object p1, p0, Lcom/google/android/gms/internal/ads/l;->r:Landroid/app/Activity;

    :cond_15
    monitor-exit v0

    return-void

    :catchall_17
    move-exception p1

    monitor-exit v0
    :try_end_19
    .catchall {:try_start_3 .. :try_end_19} :catchall_17

    throw p1
.end method

.method public final onActivityCreated(Landroid/app/Activity;Landroid/os/Bundle;)V
    .registers 3

    return-void
.end method

.method public final onActivityDestroyed(Landroid/app/Activity;)V
    .registers 7

    iget-object v0, p0, Lcom/google/android/gms/internal/ads/l;->t:Ljava/lang/Object;

    monitor-enter v0

    :try_start_3
    iget-object v1, p0, Lcom/google/android/gms/internal/ads/l;->r:Landroid/app/Activity;

    if-eqz v1, :cond_48

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

    move-result p1

    if-eqz p1, :cond_10

    const/4 p1, 0x0

    iput-object p1, p0, Lcom/google/android/gms/internal/ads/l;->r:Landroid/app/Activity;

    :cond_10
    iget-object p1, p0, Lcom/google/android/gms/internal/ads/l;->x:Ljava/util/List;

    invoke-interface {p1}, Ljava/util/List;->iterator()Ljava/util/Iterator;

    move-result-object p1

    :cond_16
    :goto_16
    invoke-interface {p1}, Ljava/util/Iterator;->hasNext()Z

    move-result v1

    if-eqz v1, :cond_46

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

    move-result-object v1

    check-cast v1, Lz5/df;
    :try_end_22
    .catchall {:try_start_3 .. :try_end_22} :catchall_44

    :try_start_22
    invoke-interface {v1}, Lz5/df;->zza()Z

    move-result v1

    if-eqz v1, :cond_16

    invoke-interface {p1}, Ljava/util/Iterator;->remove()V
    :try_end_2b
    .catch Ljava/lang/Exception; {:try_start_22 .. :try_end_2b} :catch_2c
    .catchall {:try_start_22 .. :try_end_2b} :catchall_44

    goto :goto_16

    :catch_2c
    move-exception v1

    :try_start_2d
    invoke-static {}, Lcom/google/android/gms/ads/internal/zzt;->zzg()Lcom/google/android/gms/internal/ads/u1;

    move-result-object v2

    const-string v3, "AppActivityTracker.ActivityListener.onActivityDestroyed"

    .line 1
    iget-object v4, v2, Lcom/google/android/gms/internal/ads/u1;->e:Landroid/content/Context;

    iget-object v2, v2, Lcom/google/android/gms/internal/ads/u1;->f:Lz5/g50;

    invoke-static {v4, v2}, Lcom/google/android/gms/internal/ads/h1;->d(Landroid/content/Context;Lz5/g50;)Lz5/f10;

    move-result-object v2

    invoke-interface {v2, v1, v3}, Lz5/f10;->a(Ljava/lang/Throwable;Ljava/lang/String;)V

    const-string v2, ""

    .line 2
    invoke-static {v2, v1}, Lz5/d50;->zzg(Ljava/lang/String;Ljava/lang/Throwable;)V

    goto :goto_16

    :catchall_44
    move-exception p1

    goto :goto_4a

    :cond_46
    monitor-exit v0

    return-void

    :cond_48
    monitor-exit v0

    return-void

    :goto_4a
    monitor-exit v0
    :try_end_4b
    .catchall {:try_start_2d .. :try_end_4b} :catchall_44

    throw p1
.end method

.method public final onActivityPaused(Landroid/app/Activity;)V
    .registers 7

    invoke-virtual {p0, p1}, Lcom/google/android/gms/internal/ads/l;->a(Landroid/app/Activity;)V

    iget-object p1, p0, Lcom/google/android/gms/internal/ads/l;->t:Ljava/lang/Object;

    monitor-enter p1

    :try_start_6
    iget-object v0, p0, Lcom/google/android/gms/internal/ads/l;->x:Ljava/util/List;

    invoke-interface {v0}, Ljava/util/List;->iterator()Ljava/util/Iterator;

    move-result-object v0

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

    move-result v1

    if-eqz v1, :cond_36

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

    move-result-object v1

    check-cast v1, Lz5/df;
    :try_end_18
    .catchall {:try_start_6 .. :try_end_18} :catchall_34

    :try_start_18
    invoke-interface {v1}, Lz5/df;->zzb()V
    :try_end_1b
    .catch Ljava/lang/Exception; {:try_start_18 .. :try_end_1b} :catch_1c
    .catchall {:try_start_18 .. :try_end_1b} :catchall_34

    goto :goto_c

    :catch_1c
    move-exception v1

    :try_start_1d
    invoke-static {}, Lcom/google/android/gms/ads/internal/zzt;->zzg()Lcom/google/android/gms/internal/ads/u1;

    move-result-object v2

    const-string v3, "AppActivityTracker.ActivityListener.onActivityPaused"

    .line 1
    iget-object v4, v2, Lcom/google/android/gms/internal/ads/u1;->e:Landroid/content/Context;

    iget-object v2, v2, Lcom/google/android/gms/internal/ads/u1;->f:Lz5/g50;

    invoke-static {v4, v2}, Lcom/google/android/gms/internal/ads/h1;->d(Landroid/content/Context;Lz5/g50;)Lz5/f10;

    move-result-object v2

    invoke-interface {v2, v1, v3}, Lz5/f10;->a(Ljava/lang/Throwable;Ljava/lang/String;)V

    const-string v2, ""

    .line 2
    invoke-static {v2, v1}, Lz5/d50;->zzg(Ljava/lang/String;Ljava/lang/Throwable;)V

    goto :goto_c

    :catchall_34
    move-exception v0

    goto :goto_52

    :cond_36
    monitor-exit p1
    :try_end_37
    .catchall {:try_start_1d .. :try_end_37} :catchall_34

    const/4 p1, 0x1

    iput-boolean p1, p0, Lcom/google/android/gms/internal/ads/l;->v:Z

    iget-object p1, p0, Lcom/google/android/gms/internal/ads/l;->y:Ljava/lang/Runnable;

    if-eqz p1, :cond_43

    sget-object v0, Lcom/google/android/gms/ads/internal/util/zzs;->zza:Lz5/i91;

    invoke-virtual {v0, p1}, Landroid/os/Handler;->removeCallbacks(Ljava/lang/Runnable;)V

    :cond_43
    sget-object p1, Lcom/google/android/gms/ads/internal/util/zzs;->zza:Lz5/i91;

    new-instance v0, Ll5/x;

    invoke-direct {v0, p0}, Ll5/x;-><init>(Lcom/google/android/gms/internal/ads/l;)V

    iput-object v0, p0, Lcom/google/android/gms/internal/ads/l;->y:Ljava/lang/Runnable;

    iget-wide v1, p0, Lcom/google/android/gms/internal/ads/l;->A:J

    invoke-virtual {p1, v0, v1, v2}, Landroid/os/Handler;->postDelayed(Ljava/lang/Runnable;J)Z

    return-void

    :goto_52
    :try_start_52
    monitor-exit p1
    :try_end_53
    .catchall {:try_start_52 .. :try_end_53} :catchall_34

    throw v0
.end method

.method public final onActivityResumed(Landroid/app/Activity;)V
    .registers 9

    invoke-virtual {p0, p1}, Lcom/google/android/gms/internal/ads/l;->a(Landroid/app/Activity;)V

    const/4 p1, 0x0

    iput-boolean p1, p0, Lcom/google/android/gms/internal/ads/l;->v:Z

    iget-boolean p1, p0, Lcom/google/android/gms/internal/ads/l;->u:Z

    const/4 v0, 0x1

    xor-int/2addr p1, v0

    iput-boolean v0, p0, Lcom/google/android/gms/internal/ads/l;->u:Z

    iget-object v1, p0, Lcom/google/android/gms/internal/ads/l;->y:Ljava/lang/Runnable;

    if-eqz v1, :cond_15

    sget-object v2, Lcom/google/android/gms/ads/internal/util/zzs;->zza:Lz5/i91;

    invoke-virtual {v2, v1}, Landroid/os/Handler;->removeCallbacks(Ljava/lang/Runnable;)V

    :cond_15
    iget-object v1, p0, Lcom/google/android/gms/internal/ads/l;->t:Ljava/lang/Object;

    monitor-enter v1

    :try_start_18
    iget-object v2, p0, Lcom/google/android/gms/internal/ads/l;->x:Ljava/util/List;

    invoke-interface {v2}, Ljava/util/List;->iterator()Ljava/util/Iterator;

    move-result-object v2

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

    move-result v3

    if-eqz v3, :cond_48

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

    move-result-object v3

    check-cast v3, Lz5/df;
    :try_end_2a
    .catchall {:try_start_18 .. :try_end_2a} :catchall_46

    :try_start_2a
    invoke-interface {v3}, Lz5/df;->zzc()V
    :try_end_2d
    .catch Ljava/lang/Exception; {:try_start_2a .. :try_end_2d} :catch_2e
    .catchall {:try_start_2a .. :try_end_2d} :catchall_46

    goto :goto_1e

    :catch_2e
    move-exception v3

    :try_start_2f
    invoke-static {}, Lcom/google/android/gms/ads/internal/zzt;->zzg()Lcom/google/android/gms/internal/ads/u1;

    move-result-object v4

    const-string v5, "AppActivityTracker.ActivityListener.onActivityResumed"

    .line 1
    iget-object v6, v4, Lcom/google/android/gms/internal/ads/u1;->e:Landroid/content/Context;

    iget-object v4, v4, Lcom/google/android/gms/internal/ads/u1;->f:Lz5/g50;

    invoke-static {v6, v4}, Lcom/google/android/gms/internal/ads/h1;->d(Landroid/content/Context;Lz5/g50;)Lz5/f10;

    move-result-object v4

    invoke-interface {v4, v3, v5}, Lz5/f10;->a(Ljava/lang/Throwable;Ljava/lang/String;)V

    const-string v4, ""

    .line 2
    invoke-static {v4, v3}, Lz5/d50;->zzg(Ljava/lang/String;Ljava/lang/Throwable;)V

    goto :goto_1e

    :catchall_46
    move-exception p1

    goto :goto_6e

    :cond_48
    if-eqz p1, :cond_67

    iget-object p1, p0, Lcom/google/android/gms/internal/ads/l;->w:Ljava/util/List;

    invoke-interface {p1}, Ljava/util/List;->iterator()Ljava/util/Iterator;

    move-result-object p1

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

    move-result v2

    if-eqz v2, :cond_6c

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

    move-result-object v2

    check-cast v2, Lz5/ye;
    :try_end_5c
    .catchall {:try_start_2f .. :try_end_5c} :catchall_46

    :try_start_5c
    invoke-interface {v2, v0}, Lz5/ye;->zza(Z)V
    :try_end_5f
    .catch Ljava/lang/Exception; {:try_start_5c .. :try_end_5f} :catch_60
    .catchall {:try_start_5c .. :try_end_5f} :catchall_46

    goto :goto_50

    :catch_60
    move-exception v2

    :try_start_61
    const-string v3, ""

    invoke-static {v3, v2}, Lz5/d50;->zzg(Ljava/lang/String;Ljava/lang/Throwable;)V

    goto :goto_50

    :cond_67
    const-string p1, "App is still foreground."

    invoke-static {p1}, Lz5/d50;->zzd(Ljava/lang/String;)V

    :cond_6c
    monitor-exit v1

    return-void

    :goto_6e
    monitor-exit v1
    :try_end_6f
    .catchall {:try_start_61 .. :try_end_6f} :catchall_46

    throw p1
.end method

.method public final onActivitySaveInstanceState(Landroid/app/Activity;Landroid/os/Bundle;)V
    .registers 3

    return-void
.end method

.method public final onActivityStarted(Landroid/app/Activity;)V
    .registers 2

    invoke-virtual {p0, p1}, Lcom/google/android/gms/internal/ads/l;->a(Landroid/app/Activity;)V

    return-void
.end method

.method public final onActivityStopped(Landroid/app/Activity;)V
    .registers 2

    return-void
.end method
