GameBoostedView$a.smali

.class Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;
.super Landroid/widget/BaseAdapter;
.source "GameBoostedView.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/cleanmaster/gameboost/ui/GameBoostedView;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x2
    name = "a"
.end annotation


# instance fields
.field a:Ljava/util/List;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Ljava/util/List",
            "<",
            "Lcom/cleanmaster/gameboost/modle/AbsGameModel;",
            ">;"
        }
    .end annotation
.end field

.field final synthetic b:Lcom/cleanmaster/gameboost/ui/GameBoostedView;


# direct methods
.method private constructor <init>(Lcom/cleanmaster/gameboost/ui/GameBoostedView;)V
    .registers 2

    .prologue
    .line 110
    iput-object p1, p0, Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;->b:Lcom/cleanmaster/gameboost/ui/GameBoostedView;

    invoke-direct {p0}, Landroid/widget/BaseAdapter;-><init>()V

    return-void
.end method

.method synthetic constructor <init>(Lcom/cleanmaster/gameboost/ui/GameBoostedView;Lcom/cleanmaster/gameboost/ui/i;)V
    .registers 3

    .prologue
    .line 110
    invoke-direct {p0, p1}, Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;-><init>(Lcom/cleanmaster/gameboost/ui/GameBoostedView;)V

    return-void
.end method


# virtual methods
.method public a(Ljava/util/List;)V
    .registers 2
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Ljava/util/List",
            "<",
            "Lcom/cleanmaster/gameboost/modle/AbsGameModel;",
            ">;)V"
        }
    .end annotation

    .prologue
    .line 114
    iput-object p1, p0, Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;->a:Ljava/util/List;

    .line 115
    invoke-virtual {p0}, Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;->notifyDataSetChanged()V

    .line 116
    return-void
.end method

.method public getCount()I
    .registers 2

    .prologue
    .line 120
    iget-object v0, p0, Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;->a:Ljava/util/List;

    if-nez v0, :cond_6

    const/4 v0, 0x0

    :goto_5
    return v0

    :cond_6
    iget-object v0, p0, Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;->a:Ljava/util/List;

    invoke-interface {v0}, Ljava/util/List;->size()I

    move-result v0

    goto :goto_5
.end method

.method public getItem(I)Ljava/lang/Object;
    .registers 3

    .prologue
    .line 125
    iget-object v0, p0, Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;->a:Ljava/util/List;

    invoke-interface {v0, p1}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object v0

    return-object v0
.end method

.method public getItemId(I)J
    .registers 4

    .prologue
    .line 130
    int-to-long v0, p1

    return-wide v0
.end method

.method public getView(ILandroid/view/View;Landroid/view/ViewGroup;)Landroid/view/View;
    .registers 8

    .prologue
    const/4 v3, 0x0

    .line 135
    iget-object v0, p0, Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;->a:Ljava/util/List;

    invoke-interface {v0, p1}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/cleanmaster/gameboost/modle/AbsGameModel;

    .line 136
    instance-of v1, v0, Lcom/cleanmaster/gameboost/modle/b;

    if-eqz v1, :cond_4c

    .line 137
    if-nez p2, :cond_1f

    .line 138
    iget-object v1, p0, Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;->b:Lcom/cleanmaster/gameboost/ui/GameBoostedView;

    invoke-virtual {v1}, Lcom/cleanmaster/gameboost/ui/GameBoostedView;->getContext()Landroid/content/Context;

    move-result-object v1

    invoke-static {v1}, Landroid/view/LayoutInflater;->from(Landroid/content/Context;)Landroid/view/LayoutInflater;

    move-result-object v1

    sget v2, Lcom/cleanmaster/gameboost/R$layout;->item_game_boosting:I

    invoke-virtual {v1, v2, p3, v3}, Landroid/view/LayoutInflater;->inflate(ILandroid/view/ViewGroup;Z)Landroid/view/View;

    move-result-object p2

    :cond_1f
    move-object v1, v0

    .line 140
    check-cast v1, Lcom/cleanmaster/gameboost/modle/g;

    iget-object v2, p0, Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;->b:Lcom/cleanmaster/gameboost/ui/GameBoostedView;

    invoke-virtual {v2}, Lcom/cleanmaster/gameboost/ui/GameBoostedView;->getContext()Landroid/content/Context;

    move-result-object v2

    invoke-virtual {v1, v2}, Lcom/cleanmaster/gameboost/modle/g;->a(Landroid/content/Context;)Landroid/graphics/drawable/Drawable;

    move-result-object v2

    .line 141
    if-eqz v2, :cond_45

    .line 142
    sget v1, Lcom/cleanmaster/gameboost/R$id;->iv_icon:I

    invoke-virtual {p2, v1}, Landroid/view/View;->findViewById(I)Landroid/view/View;

    move-result-object v1

    check-cast v1, Landroid/widget/ImageView;

    .line 143
    invoke-virtual {v1, v2}, Landroid/widget/ImageView;->setImageDrawable(Landroid/graphics/drawable/Drawable;)V

    .line 144
    check-cast v0, Lcom/cleanmaster/gameboost/modle/b;

    iget-boolean v0, v0, Lcom/cleanmaster/gameboost/modle/b;->c:Z

    if-eqz v0, :cond_46

    .line 145
    const v0, 0x3f333333    # 0.7f

    invoke-virtual {v1, v0}, Landroid/widget/ImageView;->setAlpha(F)V

    .line 157
    :cond_45
    :goto_45
    return-object p2

    .line 147
    :cond_46
    const/high16 v0, 0x3f800000    # 1.0f

    invoke-virtual {v1, v0}, Landroid/widget/ImageView;->setAlpha(F)V

    goto :goto_45

    .line 150
    :cond_4c
    instance-of v0, v0, Lcom/cleanmaster/gameboost/modle/h;

    if-eqz v0, :cond_63

    .line 151
    if-nez p2, :cond_45

    .line 152
    iget-object v0, p0, Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;->b:Lcom/cleanmaster/gameboost/ui/GameBoostedView;

    invoke-virtual {v0}, Lcom/cleanmaster/gameboost/ui/GameBoostedView;->getContext()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Landroid/view/LayoutInflater;->from(Landroid/content/Context;)Landroid/view/LayoutInflater;

    move-result-object v0

    sget v1, Lcom/cleanmaster/gameboost/R$layout;->item_game_boosting_more:I

    invoke-virtual {v0, v1, p3, v3}, Landroid/view/LayoutInflater;->inflate(ILandroid/view/ViewGroup;Z)Landroid/view/View;

    move-result-object p2

    goto :goto_45

    .line 155
    :cond_63
    new-instance p2, Landroid/view/View;

    iget-object v0, p0, Lcom/cleanmaster/gameboost/ui/GameBoostedView$a;->b:Lcom/cleanmaster/gameboost/ui/GameBoostedView;

    invoke-virtual {v0}, Lcom/cleanmaster/gameboost/ui/GameBoostedView;->getContext()Landroid/content/Context;

    move-result-object v0

    invoke-direct {p2, v0}, Landroid/view/View;-><init>(Landroid/content/Context;)V

    goto :goto_45
.end method