d.smali
.class public final Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;
.super Ljava/lang/Object;
.source "SourceFile"
# interfaces
.implements Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/b;
# instance fields
.field private a:I
.field private final b:I
.field private c:I
.field private d:Landroid/view/View;
.field private e:F
.field private f:Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/MoreSwipeRefreshLayout$a;
.field private g:Z
.field private h:Z
.field private final i:Landroid/content/Context;
.field private final j:Landroid/view/View;
# direct methods
.method public constructor <init>(Landroid/content/Context;Landroid/view/View;)V
.registers 4
const-string v0, "mContext"
invoke-static {p1, v0}, Lkotlin/f/b/o;->b(Ljava/lang/Object;Ljava/lang/String;)V
const-string v0, "mParent"
invoke-static {p2, v0}, Lkotlin/f/b/o;->b(Ljava/lang/Object;Ljava/lang/String;)V
.line 9
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
iput-object p1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->i:Landroid/content/Context;
iput-object p2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->j:Landroid/view/View;
const/16 p2, 0x50
.line 11
iput p2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->a:I
const/16 p2, 0x3c
.line 13
iput p2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->c:I
.line 39
invoke-virtual {p1}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object p1
const-string p2, "mContext.resources"
invoke-static {p1, p2}, Lkotlin/f/b/o;->a(Ljava/lang/Object;Ljava/lang/String;)V
invoke-virtual {p1}, Landroid/content/res/Resources;->getDisplayMetrics()Landroid/util/DisplayMetrics;
move-result-object p1
.line 40
iget p2, p1, Landroid/util/DisplayMetrics;->heightPixels:I
iput p2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->b:I
.line 41
iget p2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->a:I
iget v0, p1, Landroid/util/DisplayMetrics;->density:F
float-to-int v0, v0
mul-int p2, p2, v0
iput p2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->a:I
.line 42
iget p2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->c:I
iget p1, p1, Landroid/util/DisplayMetrics;->density:F
float-to-int p1, p1
mul-int p2, p2, p1
iput p2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->c:I
return-void
.end method
# virtual methods
.method public final a(F)I
.registers 6
.line 58
iget v0, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->e:F
iget v1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->c:I
int-to-float v2, v1
const/4 v3, 0x0
cmpl-float v2, v0, v2
if-gtz v2, :cond_12
add-float/2addr p1, v0
int-to-float v0, v1
cmpl-float p1, p1, v0
if-lez p1, :cond_11
goto :goto_12
:cond_11
return v3
.line 59
:cond_12
:goto_12
iget-object p1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->d:Landroid/view/View;
const-string v0, "mDefaultView"
if-nez p1, :cond_1b
invoke-static {v0}, Lkotlin/f/b/o;->a(Ljava/lang/String;)V
:cond_1b
invoke-virtual {p1}, Landroid/view/View;->getVisibility()I
move-result p1
if-eqz p1, :cond_2b
.line 60
iget-object p1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->d:Landroid/view/View;
if-nez p1, :cond_28
invoke-static {v0}, Lkotlin/f/b/o;->a(Ljava/lang/String;)V
:cond_28
invoke-virtual {p1, v3}, Landroid/view/View;->setVisibility(I)V
.line 62
:cond_2b
iget-boolean p1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->g:Z
if-nez p1, :cond_40
iget-boolean p1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->h:Z
if-nez p1, :cond_40
const/4 p1, 0x1
.line 63
iput-boolean p1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->h:Z
.line 64
iget-object p1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->f:Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/MoreSwipeRefreshLayout$a;
if-nez p1, :cond_3d
invoke-static {}, Lkotlin/f/b/o;->a()V
:cond_3d
invoke-interface {p1}, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/MoreSwipeRefreshLayout$a;->c()V
.line 66
:cond_40
iget p1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->a:I
int-to-float v0, p1
iget v1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->e:F
sub-float/2addr v0, v1
float-to-int v0, v0
int-to-float p1, p1
.line 67
iput p1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->e:F
return v0
.end method
.method public final a(I)I
.registers 7
const/4 v0, 0x0
const/4 v1, 0x0
if-lez p1, :cond_2f
.line 77
iget v2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->e:F
iget v3, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->b:I
int-to-float v4, v3
cmpg-float v4, v2, v4
if-gez v4, :cond_2e
cmpl-float v0, v2, v0
if-ltz v0, :cond_2e
int-to-float p1, p1
int-to-float v0, v3
sub-float/2addr v0, v2
mul-float p1, p1, v0
mul-int/lit8 v0, v3, 0x2
int-to-float v0, v0
div-float/2addr p1, v0
float-to-int p1, p1
int-to-float v0, p1
add-float v1, v2, v0
int-to-float v4, v3
cmpg-float v1, v1, v4
if-gez v1, :cond_27
add-float/2addr v2, v0
.line 80
iput v2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->e:F
return p1
:cond_27
int-to-float p1, v3
sub-float/2addr p1, v2
float-to-int p1, p1
int-to-float v0, v3
.line 84
iput v0, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->e:F
return p1
:cond_2e
return v1
.line 89
:cond_2f
iget-object v2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->d:Landroid/view/View;
const-string v3, "mDefaultView"
if-nez v2, :cond_38
invoke-static {v3}, Lkotlin/f/b/o;->a(Ljava/lang/String;)V
:cond_38
invoke-virtual {v2}, Landroid/view/View;->getVisibility()I
move-result v2
if-eqz v2, :cond_48
.line 90
iget-object v2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->d:Landroid/view/View;
if-nez v2, :cond_45
invoke-static {v3}, Lkotlin/f/b/o;->a(Ljava/lang/String;)V
:cond_45
invoke-virtual {v2, v1}, Landroid/view/View;->setVisibility(I)V
.line 92
:cond_48
iget v1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->e:F
int-to-float v2, p1
add-float/2addr v1, v2
iput v1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->e:F
cmpg-float v0, v1, v0
if-gez v0, :cond_54
sub-float/2addr v2, v1
float-to-int p1, v2
:cond_54
return p1
.end method
.method public final a()V
.registers 2
const/4 v0, 0x0
.line 46
iput v0, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->e:F
return-void
.end method
.method public final a(Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/MoreSwipeRefreshLayout$a;)V
.registers 3
const-string v0, "mListener"
invoke-static {p1, v0}, Lkotlin/f/b/o;->b(Ljava/lang/Object;Ljava/lang/String;)V
.line 103
iput-object p1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->f:Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/MoreSwipeRefreshLayout$a;
return-void
.end method
.method public final a(Z)V
.registers 6
.line 113
iget-boolean v0, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->h:Z
if-eq v0, p1, :cond_37
.line 114
iput-boolean p1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->h:Z
const-string v0, "mDefaultView"
const/4 v1, 0x0
if-eqz p1, :cond_1d
.line 116
iget-object v2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->d:Landroid/view/View;
if-nez v2, :cond_12
invoke-static {v0}, Lkotlin/f/b/o;->a(Ljava/lang/String;)V
:cond_12
invoke-virtual {v2, v1}, Landroid/view/View;->setVisibility(I)V
.line 117
iget-object v0, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->j:Landroid/view/View;
iget v2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->a:I
invoke-virtual {v0, v1, v2}, Landroid/view/View;->scrollBy(II)V
goto :goto_35
.line 119
:cond_1d
iget-object v2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->j:Landroid/view/View;
iget v3, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->e:F
float-to-int v3, v3
neg-int v3, v3
invoke-virtual {v2, v1, v3}, Landroid/view/View;->scrollBy(II)V
.line 120
iget-object v1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->d:Landroid/view/View;
if-nez v1, :cond_2d
invoke-static {v0}, Lkotlin/f/b/o;->a(Ljava/lang/String;)V
:cond_2d
const/16 v0, 0x8
invoke-virtual {v1, v0}, Landroid/view/View;->setVisibility(I)V
const/4 v0, 0x0
.line 1046
iput v0, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->e:F
.line 123
:goto_35
iput-boolean p1, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->h:Z
:cond_37
return-void
.end method
.method public final b()Landroid/view/View;
.registers 5
.line 50
iget-object v0, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->i:Landroid/content/Context;
invoke-static {v0}, Landroid/view/LayoutInflater;->from(Landroid/content/Context;)Landroid/view/LayoutInflater;
move-result-object v0
const v1, 0x7f0b055e
const/4 v2, 0x0
invoke-virtual {v0, v1, v2}, Landroid/view/LayoutInflater;->inflate(ILandroid/view/ViewGroup;)Landroid/view/View;
move-result-object v0
const-string v1, "view"
.line 52
invoke-static {v0, v1}, Lkotlin/f/b/o;->a(Ljava/lang/Object;Ljava/lang/String;)V
new-instance v1, Landroid/view/ViewGroup$LayoutParams;
iget v2, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->a:I
const/4 v3, -0x1
invoke-direct {v1, v3, v2}, Landroid/view/ViewGroup$LayoutParams;-><init>(II)V
invoke-virtual {v0, v1}, Landroid/view/View;->setLayoutParams(Landroid/view/ViewGroup$LayoutParams;)V
.line 53
iput-object v0, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->d:Landroid/view/View;
return-object v0
.end method
.method public final c()I
.registers 2
.line 31
iget v0, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->e:F
float-to-int v0, v0
return v0
.end method
.method public final d()Z
.registers 2
.line 27
iget-boolean v0, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->h:Z
return v0
.end method
.method public final e()V
.registers 3
.line 129
iget-object v0, p0, Lcom/imo/android/imoim/gamecenter/module/views/swiperefresh/d;->d:Landroid/view/View;
if-nez v0, :cond_9
const-string v1, "mDefaultView"
invoke-static {v1}, Lkotlin/f/b/o;->a(Ljava/lang/String;)V
:cond_9
const/4 v1, 0x4
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
return-void
.end method