EditCommentComponent$a.smali

.class public final Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a;
.super Ljava/lang/Object;
.source "SourceFile"

# interfaces
.implements Landroid/text/TextWatcher;


# annotations
.annotation system Ldalvik/annotation/EnclosingMethod;
    value = Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;->e()V
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x19
    name = null
.end annotation


# instance fields
.field final synthetic a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;


# direct methods
.method constructor <init>(Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;)V
    .registers 2
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "()V"
        }
    .end annotation

    .line 144
    iput-object p1, p0, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a;->a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;

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

    return-void
.end method


# virtual methods
.method public final afterTextChanged(Landroid/text/Editable;)V
    .registers 8

    .line 148
    iget-object v0, p0, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a;->a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;

    .line 1097
    iget-object v0, v0, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;->c:Landroid/widget/EditText;

    const/4 v1, 0x0

    if-eqz v0, :cond_c

    .line 148
    invoke-virtual {v0}, Landroid/widget/EditText;->getText()Landroid/text/Editable;

    move-result-object v0

    goto :goto_d

    :cond_c
    move-object v0, v1

    .line 149
    :goto_d
    iget-object v2, p0, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a;->a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;

    .line 1099
    iget-object v2, v2, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;->d:Landroid/widget/ImageView;

    const/4 v3, 0x1

    if-eqz v2, :cond_1e

    .line 149
    check-cast v0, Ljava/lang/CharSequence;

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

    move-result v0

    xor-int/2addr v0, v3

    invoke-virtual {v2, v0}, Landroid/widget/ImageView;->setEnabled(Z)V

    :cond_1e
    const/4 v0, 0x0

    if-eqz p1, :cond_26

    .line 150
    invoke-interface {p1}, Landroid/text/Editable;->length()I

    move-result v2

    goto :goto_27

    :cond_26
    const/4 v2, 0x0

    .line 151
    :goto_27
    iget-object v4, p0, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a;->a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;

    invoke-static {v4}, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;->a(Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;)I

    move-result v4

    if-le v2, v4, :cond_64

    .line 152
    iget-object v4, p0, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a;->a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;

    .line 2097
    iget-object v4, v4, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;->c:Landroid/widget/EditText;

    if-eqz v4, :cond_3a

    .line 152
    invoke-virtual {v4}, Landroid/widget/EditText;->getSelectionEnd()I

    move-result v4

    goto :goto_3b

    :cond_3a
    const/4 v4, 0x0

    :goto_3b
    if-gez v4, :cond_49

    if-eqz p1, :cond_57

    .line 154
    iget-object v4, p0, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a;->a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;

    invoke-static {v4}, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;->a(Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;)I

    move-result v4

    invoke-interface {p1, v4, v2}, Landroid/text/Editable;->delete(II)Landroid/text/Editable;

    goto :goto_57

    :cond_49
    if-eqz p1, :cond_57

    .line 156
    iget-object v5, p0, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a;->a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;

    invoke-static {v5}, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;->a(Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;)I

    move-result v5

    sub-int/2addr v2, v5

    sub-int v2, v4, v2

    invoke-interface {p1, v2, v4}, Landroid/text/Editable;->delete(II)Landroid/text/Editable;

    .line 158
    :cond_57
    :goto_57
    iget-object p1, p0, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a;->a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;

    .line 3097
    iget-object p1, p1, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;->c:Landroid/widget/EditText;

    if-eqz p1, :cond_64

    .line 158
    sget-object v2, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a$a;->a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a$a;

    check-cast v2, Lkotlin/f/a/a;

    invoke-static {p1, v2}, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/emoticon/b;->a(Ljava/lang/Object;Lkotlin/f/a/a;)V

    .line 163
    :cond_64
    iget-object p1, p0, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a;->a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;

    .line 4091
    iget-boolean p1, p1, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;->b:Z

    if-nez p1, :cond_8d

    .line 164
    iget-object p1, p0, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a;->a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;

    .line 4099
    iget-object p1, p1, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;->d:Landroid/widget/ImageView;

    if-eqz p1, :cond_8d

    .line 164
    iget-object v2, p0, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent$a;->a:Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;

    .line 5097
    iget-object v2, v2, Lcom/imo/android/imoim/feeds/ui/detail/components/comment/EditCommentComponent;->c:Landroid/widget/EditText;

    if-eqz v2, :cond_7a

    .line 164
    invoke-virtual {v2}, Landroid/widget/EditText;->getText()Landroid/text/Editable;

    move-result-object v1

    :cond_7a
    check-cast v1, Ljava/lang/CharSequence;

    if-eqz v1, :cond_86

    invoke-interface {v1}, Ljava/lang/CharSequence;->length()I

    move-result v1

    if-nez v1, :cond_85

    goto :goto_86

    :cond_85
    const/4 v3, 0x0

    :cond_86
    :goto_86
    if-eqz v3, :cond_8a

    const/16 v0, 0x8

    :cond_8a
    invoke-virtual {p1, v0}, Landroid/widget/ImageView;->setVisibility(I)V

    :cond_8d
    return-void
.end method

.method public final beforeTextChanged(Ljava/lang/CharSequence;III)V
    .registers 5

    return-void
.end method

.method public final onTextChanged(Ljava/lang/CharSequence;III)V
    .registers 5

    return-void
.end method