ChatAttachAlert$BasePhotoProvider.smali

.class Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;
.super Lim/tpelyyftgw/ui/PhotoViewer$EmptyPhotoViewerProvider;
.source "ChatAttachAlert.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lim/tpelyyftgw/ui/components/ChatAttachAlert;
.end annotation

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


# instance fields
.field final synthetic this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;


# direct methods
.method static constructor <clinit>()V
    .registers 1

    return-void
.end method

.method private constructor <init>(Lim/tpelyyftgw/ui/components/ChatAttachAlert;)V
    .registers 2

    .line 276
    iput-object p1, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-direct {p0}, Lim/tpelyyftgw/ui/PhotoViewer$EmptyPhotoViewerProvider;-><init>()V

    return-void
.end method

.method synthetic constructor <init>(Lim/tpelyyftgw/ui/components/ChatAttachAlert;Lim/tpelyyftgw/ui/components/ChatAttachAlert$1;)V
    .registers 3
    .param p1, "x0"    # Lim/tpelyyftgw/ui/components/ChatAttachAlert;
    .param p2, "x1"    # Lim/tpelyyftgw/ui/components/ChatAttachAlert$1;

    .line 276
    invoke-direct {p0, p1}, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;-><init>(Lim/tpelyyftgw/ui/components/ChatAttachAlert;)V

    return-void
.end method


# virtual methods
.method public getPhotoIndex(I)I
    .registers 5
    .param p1, "index"    # I

    .line 353
    iget-object v0, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v0, p1}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$000(Lim/tpelyyftgw/ui/components/ChatAttachAlert;I)Lim/tpelyyftgw/messenger/MediaController$PhotoEntry;

    move-result-object v0

    .line 354
    .local v0, "photoEntry":Lim/tpelyyftgw/messenger/MediaController$PhotoEntry;
    if-nez v0, :cond_a

    .line 355
    const/4 v1, -0x1

    return v1

    .line 357
    :cond_a
    invoke-static {}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$400()Ljava/util/ArrayList;

    move-result-object v1

    iget v2, v0, Lim/tpelyyftgw/messenger/MediaController$PhotoEntry;->imageId:I

    invoke-static {v2}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v2

    invoke-virtual {v1, v2}, Ljava/util/ArrayList;->indexOf(Ljava/lang/Object;)I

    move-result v1

    return v1
.end method

.method public getSelectedCount()I
    .registers 2

    .line 338
    invoke-static {}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$100()Ljava/util/HashMap;

    move-result-object v0

    invoke-virtual {v0}, Ljava/util/HashMap;->size()I

    move-result v0

    return v0
.end method

.method public getSelectedPhotos()Ljava/util/HashMap;
    .registers 2
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "()",
            "Ljava/util/HashMap<",
            "Ljava/lang/Object;",
            "Ljava/lang/Object;",
            ">;"
        }
    .end annotation

    .line 348
    invoke-static {}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$100()Ljava/util/HashMap;

    move-result-object v0

    return-object v0
.end method

.method public getSelectedPhotosOrder()Ljava/util/ArrayList;
    .registers 2
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "()",
            "Ljava/util/ArrayList<",
            "Ljava/lang/Object;",
            ">;"
        }
    .end annotation

    .line 343
    invoke-static {}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$400()Ljava/util/ArrayList;

    move-result-object v0

    return-object v0
.end method

.method public isPhotoChecked(I)Z
    .registers 5
    .param p1, "index"    # I

    .line 279
    iget-object v0, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v0, p1}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$000(Lim/tpelyyftgw/ui/components/ChatAttachAlert;I)Lim/tpelyyftgw/messenger/MediaController$PhotoEntry;

    move-result-object v0

    .line 280
    .local v0, "photoEntry":Lim/tpelyyftgw/messenger/MediaController$PhotoEntry;
    if-eqz v0, :cond_1a

    invoke-static {}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$100()Ljava/util/HashMap;

    move-result-object v1

    iget v2, v0, Lim/tpelyyftgw/messenger/MediaController$PhotoEntry;->imageId:I

    invoke-static {v2}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v2

    invoke-virtual {v1, v2}, Ljava/util/HashMap;->containsKey(Ljava/lang/Object;)Z

    move-result v1

    if-eqz v1, :cond_1a

    const/4 v1, 0x1

    goto :goto_1b

    :cond_1a
    const/4 v1, 0x0

    :goto_1b
    return v1
.end method

.method public setPhotoChecked(ILim/tpelyyftgw/messenger/VideoEditedInfo;)I
    .registers 13
    .param p1, "index"    # I
    .param p2, "videoEditedInfo"    # Lim/tpelyyftgw/messenger/VideoEditedInfo;

    .line 285
    iget-object v0, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v0}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$200(Lim/tpelyyftgw/ui/components/ChatAttachAlert;)I

    move-result v0

    const/4 v1, -0x1

    if-ltz v0, :cond_20

    invoke-static {}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$100()Ljava/util/HashMap;

    move-result-object v0

    invoke-virtual {v0}, Ljava/util/HashMap;->size()I

    move-result v0

    iget-object v2, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v2}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$200(Lim/tpelyyftgw/ui/components/ChatAttachAlert;)I

    move-result v2

    if-lt v0, v2, :cond_20

    invoke-virtual {p0, p1}, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->isPhotoChecked(I)Z

    move-result v0

    if-nez v0, :cond_20

    .line 286
    return v1

    .line 288
    :cond_20
    iget-object v0, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v0, p1}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$000(Lim/tpelyyftgw/ui/components/ChatAttachAlert;I)Lim/tpelyyftgw/messenger/MediaController$PhotoEntry;

    move-result-object v0

    .line 289
    .local v0, "photoEntry":Lim/tpelyyftgw/messenger/MediaController$PhotoEntry;
    if-nez v0, :cond_29

    .line 290
    return v1

    .line 292
    :cond_29
    const/4 v2, 0x1

    .line 294
    .local v2, "add":Z
    iget-object v3, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v3, v0, v1}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$300(Lim/tpelyyftgw/ui/components/ChatAttachAlert;Lim/tpelyyftgw/messenger/MediaController$PhotoEntry;I)I

    move-result v3

    move v4, v3

    .local v4, "num":I
    if-ne v3, v1, :cond_42

    .line 295
    invoke-static {}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$400()Ljava/util/ArrayList;

    move-result-object v3

    iget v5, v0, Lim/tpelyyftgw/messenger/MediaController$PhotoEntry;->imageId:I

    invoke-static {v5}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v5

    invoke-virtual {v3, v5}, Ljava/util/ArrayList;->indexOf(Ljava/lang/Object;)I

    move-result v4

    goto :goto_46

    .line 297
    :cond_42
    const/4 v2, 0x0

    .line 298
    const/4 v3, 0x0

    iput-object v3, v0, Lim/tpelyyftgw/messenger/MediaController$PhotoEntry;->editedInfo:Lim/tpelyyftgw/messenger/VideoEditedInfo;

    .line 300
    :goto_46
    iput-object p2, v0, Lim/tpelyyftgw/messenger/MediaController$PhotoEntry;->editedInfo:Lim/tpelyyftgw/messenger/VideoEditedInfo;

    .line 302
    iget-object v3, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v3}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$500(Lim/tpelyyftgw/ui/components/ChatAttachAlert;)Lim/tpelyyftgw/ui/components/RecyclerListView;

    move-result-object v3

    invoke-virtual {v3}, Lim/tpelyyftgw/ui/components/RecyclerListView;->getChildCount()I

    move-result v3

    .line 303
    .local v3, "count":I
    const/4 v5, 0x0

    .local v5, "a":I
    :goto_53
    const/4 v6, 0x0

    if-ge v5, v3, :cond_93

    .line 304
    iget-object v7, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v7}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$500(Lim/tpelyyftgw/ui/components/ChatAttachAlert;)Lim/tpelyyftgw/ui/components/RecyclerListView;

    move-result-object v7

    invoke-virtual {v7, v5}, Lim/tpelyyftgw/ui/components/RecyclerListView;->getChildAt(I)Landroid/view/View;

    move-result-object v7

    .line 305
    .local v7, "view":Landroid/view/View;
    instance-of v8, v7, Lim/tpelyyftgw/ui/cells/PhotoAttachPhotoCell;

    if-eqz v8, :cond_90

    .line 306
    invoke-virtual {v7}, Landroid/view/View;->getTag()Ljava/lang/Object;

    move-result-object v8

    check-cast v8, Ljava/lang/Integer;

    invoke-virtual {v8}, Ljava/lang/Integer;->intValue()I

    move-result v8

    .line 307
    .local v8, "tag":I
    if-ne v8, p1, :cond_90

    .line 308
    iget-object v9, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v9}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$600(Lim/tpelyyftgw/ui/components/ChatAttachAlert;)Lim/tpelyyftgw/ui/actionbar/BaseFragment;

    move-result-object v9

    instance-of v9, v9, Lim/tpelyyftgw/ui/ChatActivity;

    if-eqz v9, :cond_89

    iget-object v9, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v9}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$700(Lim/tpelyyftgw/ui/components/ChatAttachAlert;)Z

    move-result v9

    if-eqz v9, :cond_89

    .line 309
    move-object v9, v7

    check-cast v9, Lim/tpelyyftgw/ui/cells/PhotoAttachPhotoCell;

    invoke-virtual {v9, v4, v2, v6}, Lim/tpelyyftgw/ui/cells/PhotoAttachPhotoCell;->setChecked(IZZ)V

    goto :goto_93

    .line 311
    :cond_89
    move-object v9, v7

    check-cast v9, Lim/tpelyyftgw/ui/cells/PhotoAttachPhotoCell;

    invoke-virtual {v9, v1, v2, v6}, Lim/tpelyyftgw/ui/cells/PhotoAttachPhotoCell;->setChecked(IZZ)V

    .line 313
    goto :goto_93

    .line 303
    .end local v7    # "view":Landroid/view/View;
    .end local v8    # "tag":I
    :cond_90
    add-int/lit8 v5, v5, 0x1

    goto :goto_53

    .line 317
    .end local v5    # "a":I
    :cond_93
    :goto_93
    iget-object v5, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v5}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$800(Lim/tpelyyftgw/ui/components/ChatAttachAlert;)Lim/tpelyyftgw/ui/components/RecyclerListView;

    move-result-object v5

    invoke-virtual {v5}, Lim/tpelyyftgw/ui/components/RecyclerListView;->getChildCount()I

    move-result v3

    .line 318
    const/4 v5, 0x0

    .restart local v5    # "a":I
    :goto_9e
    if-ge v5, v3, :cond_dd

    .line 319
    iget-object v7, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v7}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$800(Lim/tpelyyftgw/ui/components/ChatAttachAlert;)Lim/tpelyyftgw/ui/components/RecyclerListView;

    move-result-object v7

    invoke-virtual {v7, v5}, Lim/tpelyyftgw/ui/components/RecyclerListView;->getChildAt(I)Landroid/view/View;

    move-result-object v7

    .line 320
    .restart local v7    # "view":Landroid/view/View;
    instance-of v8, v7, Lim/tpelyyftgw/ui/cells/PhotoAttachPhotoCell;

    if-eqz v8, :cond_da

    .line 321
    invoke-virtual {v7}, Landroid/view/View;->getTag()Ljava/lang/Object;

    move-result-object v8

    check-cast v8, Ljava/lang/Integer;

    invoke-virtual {v8}, Ljava/lang/Integer;->intValue()I

    move-result v8

    .line 322
    .restart local v8    # "tag":I
    if-ne v8, p1, :cond_da

    .line 323
    iget-object v9, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v9}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$600(Lim/tpelyyftgw/ui/components/ChatAttachAlert;)Lim/tpelyyftgw/ui/actionbar/BaseFragment;

    move-result-object v9

    instance-of v9, v9, Lim/tpelyyftgw/ui/ChatActivity;

    if-eqz v9, :cond_d3

    iget-object v9, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    invoke-static {v9}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->access$700(Lim/tpelyyftgw/ui/components/ChatAttachAlert;)Z

    move-result v9

    if-eqz v9, :cond_d3

    .line 324
    move-object v1, v7

    check-cast v1, Lim/tpelyyftgw/ui/cells/PhotoAttachPhotoCell;

    invoke-virtual {v1, v4, v2, v6}, Lim/tpelyyftgw/ui/cells/PhotoAttachPhotoCell;->setChecked(IZZ)V

    goto :goto_dd

    .line 326
    :cond_d3
    move-object v9, v7

    check-cast v9, Lim/tpelyyftgw/ui/cells/PhotoAttachPhotoCell;

    invoke-virtual {v9, v1, v2, v6}, Lim/tpelyyftgw/ui/cells/PhotoAttachPhotoCell;->setChecked(IZZ)V

    .line 328
    goto :goto_dd

    .line 318
    .end local v7    # "view":Landroid/view/View;
    .end local v8    # "tag":I
    :cond_da
    add-int/lit8 v5, v5, 0x1

    goto :goto_9e

    .line 332
    .end local v5    # "a":I
    :cond_dd
    :goto_dd
    iget-object v1, p0, Lim/tpelyyftgw/ui/components/ChatAttachAlert$BasePhotoProvider;->this$0:Lim/tpelyyftgw/ui/components/ChatAttachAlert;

    if-eqz v2, :cond_e3

    const/4 v5, 0x1

    goto :goto_e4

    :cond_e3
    const/4 v5, 0x2

    :goto_e4
    invoke-virtual {v1, v5}, Lim/tpelyyftgw/ui/components/ChatAttachAlert;->updatePhotosButton(I)V

    .line 333
    return v4
.end method