.class public Lcom/moji/mjweather/weather/view/HomePageFrameLayout; .super Landroid/widget/FrameLayout; .source "HomePageFrameLayout.java" # interfaces .implements Landroid/support/v4/view/NestedScrollingChild; .implements Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper$ITopView; # annotations .annotation system Ldalvik/annotation/MemberClasses; value = { Lcom/moji/mjweather/weather/view/HomePageFrameLayout$ScrollerFinalListener; } .end annotation # instance fields .field private a:Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper; .annotation system Ldalvik/annotation/Signature; value = { "Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper<", "Lcom/moji/mjweather/weather/view/HomePageFrameLayout;", ">;" } .end annotation .end field .field private b:Landroid/view/VelocityTracker; .field private c:Z .field private d:I .field private e:I .field private f:I .field private g:Landroid/widget/Scroller; .field private h:I .field private i:I .field private j:I .field private k:I .field private l:Lcom/moji/mjweather/weather/view/IndexListView; .field private m:Lcom/moji/mjweather/weather/WeatherPageView; .field private final n:[I .field private o:Landroid/view/ViewGroup; .field private p:I .field private q:Landroid/widget/AbsListView$OnScrollListener; .field private r:I .field private s:Lcom/moji/mjweather/weather/view/HomePageFrameLayout$ScrollerFinalListener; .field private t:Z .field private u:Z .field private v:Landroid/widget/EdgeEffect; .field private w:I .field private x:Z .field private y:Ljava/lang/reflect/Method; # direct methods .method public constructor (Landroid/content/Context;)V .locals 2 .line 73 invoke-direct {p0, p1}, Landroid/widget/FrameLayout;->(Landroid/content/Context;)V const/4 v0, -0x1 .line 43 iput v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I const/4 v0, 0x2 .line 58 new-array v0, v0, [I iput-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->n:[I const/4 v0, 0x0 .line 62 iput v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->r:I const/4 v1, 0x1 .line 65 iput-boolean v1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->u:Z .line 68 iput-boolean v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->x:Z .line 74 invoke-direct {p0, p1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a(Landroid/content/Context;)V return-void .end method .method public constructor (Landroid/content/Context;Landroid/util/AttributeSet;)V .locals 1 .line 78 invoke-direct {p0, p1, p2}, Landroid/widget/FrameLayout;->(Landroid/content/Context;Landroid/util/AttributeSet;)V const/4 p2, -0x1 .line 43 iput p2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I const/4 p2, 0x2 .line 58 new-array p2, p2, [I iput-object p2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->n:[I const/4 p2, 0x0 .line 62 iput p2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->r:I const/4 v0, 0x1 .line 65 iput-boolean v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->u:Z .line 68 iput-boolean p2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->x:Z .line 79 invoke-direct {p0, p1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a(Landroid/content/Context;)V return-void .end method .method public constructor (Landroid/content/Context;Landroid/util/AttributeSet;I)V .locals 0 .line 83 invoke-direct {p0, p1, p2, p3}, Landroid/widget/FrameLayout;->(Landroid/content/Context;Landroid/util/AttributeSet;I)V const/4 p2, -0x1 .line 43 iput p2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I const/4 p2, 0x2 .line 58 new-array p2, p2, [I iput-object p2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->n:[I const/4 p2, 0x0 .line 62 iput p2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->r:I const/4 p3, 0x1 .line 65 iput-boolean p3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->u:Z .line 68 iput-boolean p2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->x:Z .line 84 invoke-direct {p0, p1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a(Landroid/content/Context;)V return-void .end method .method private a()V .locals 1 .line 514 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; if-nez v0, :cond_0 .line 515 invoke-static {}, Landroid/view/VelocityTracker;->obtain()Landroid/view/VelocityTracker; move-result-object v0 iput-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; :cond_0 return-void .end method .method private a(Landroid/content/Context;)V .locals 3 .line 88 new-instance v0, Landroid/widget/Scroller; invoke-direct {v0, p1}, Landroid/widget/Scroller;->(Landroid/content/Context;)V iput-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->g:Landroid/widget/Scroller; .line 89 new-instance v0, Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper; invoke-direct {v0, p0}, Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper;->(Landroid/view/View;)V iput-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a:Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper; const/4 v0, 0x1 .line 90 invoke-virtual {p0, v0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->setNestedScrollingEnabled(Z)V .line 91 invoke-static {p1}, Landroid/view/ViewConfiguration;->get(Landroid/content/Context;)Landroid/view/ViewConfiguration; move-result-object v0 .line 92 invoke-static {}, Lcom/moji/tool/DeviceTool;->b()I move-result v1 int-to-float v1, v1 const v2, 0x3d3da12f mul-float v1, v1, v2 float-to-int v1, v1 iput v1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->d:I .line 93 invoke-virtual {v0}, Landroid/view/ViewConfiguration;->getScaledMinimumFlingVelocity()I move-result v1 iput v1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->j:I .line 94 invoke-virtual {v0}, Landroid/view/ViewConfiguration;->getScaledMaximumFlingVelocity()I move-result v0 iput v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->k:I .line 96 invoke-static {}, Lcom/moji/tool/DeviceTool;->c()I move-result v0 invoke-static {}, Lcom/moji/tool/DeviceTool;->e()I move-result v1 sub-int/2addr v0, v1 invoke-static {}, Lcom/moji/tool/DeviceTool;->j()I move-result v1 sub-int/2addr v0, v1 div-int/lit8 v0, v0, 0x2 iput v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->w:I .line 97 sget v0, Landroid/os/Build$VERSION;->SDK_INT:I const/16 v1, 0x10 if-lt v0, v1, :cond_0 .line 98 new-instance v0, Landroid/widget/EdgeEffect; invoke-direct {v0, p1}, Landroid/widget/EdgeEffect;->(Landroid/content/Context;)V iput-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->v:Landroid/widget/EdgeEffect; const/4 p1, 0x0 .line 99 invoke-virtual {p0, p1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->setWillNotDraw(Z)V :cond_0 return-void .end method .method private a(Landroid/view/MotionEvent;)V .locals 3 .line 396 invoke-virtual {p1}, Landroid/view/MotionEvent;->getAction()I move-result v0 const v1, 0xff00 and-int/2addr v0, v1 shr-int/lit8 v0, v0, 0x8 .line 398 invoke-virtual {p1, v0}, Landroid/view/MotionEvent;->getPointerId(I)I move-result v1 .line 399 iget v2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I if-ne v1, v2, :cond_1 if-nez v0, :cond_0 const/4 v0, 0x1 goto :goto_0 :cond_0 const/4 v0, 0x0 .line 401 :goto_0 invoke-virtual {p1, v0}, Landroid/view/MotionEvent;->getY(I)F move-result v1 float-to-int v1, v1 iput v1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->h:I .line 402 invoke-virtual {p1, v0}, Landroid/view/MotionEvent;->getPointerId(I)I move-result p1 iput p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I .line 403 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; if-eqz p1, :cond_1 .line 404 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; invoke-virtual {p1}, Landroid/view/VelocityTracker;->clear()V :cond_1 return-void .end method .method private a(II)Z .locals 4 .line 527 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getChildCount()I move-result v0 const/4 v1, 0x0 if-lez v0, :cond_1 .line 528 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getScrollY()I move-result v0 .line 529 invoke-virtual {p0, v1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getChildAt(I)Landroid/view/View; move-result-object v2 .line 530 invoke-virtual {v2}, Landroid/view/View;->getTop()I move-result v3 sub-int/2addr v3, v0 if-lt p2, v3, :cond_0 .line 531 invoke-virtual {v2}, Landroid/view/View;->getBottom()I move-result v3 sub-int/2addr v3, v0 if-ge p2, v3, :cond_0 .line 532 invoke-virtual {v2}, Landroid/view/View;->getLeft()I move-result p2 if-lt p1, p2, :cond_0 .line 533 invoke-virtual {v2}, Landroid/view/View;->getRight()I move-result p2 if-ge p1, p2, :cond_0 const/4 v1, 0x1 :cond_0 return v1 :cond_1 return v1 .end method .method private b()V .locals 1 .line 520 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; if-eqz v0, :cond_0 .line 521 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; invoke-virtual {v0}, Landroid/view/VelocityTracker;->recycle()V const/4 v0, 0x0 .line 522 iput-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; :cond_0 return-void .end method .method private b(II)V .locals 7 .line 586 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; if-nez v0, :cond_0 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e()Z move-result v0 if-nez v0, :cond_0 return-void .line 590 :cond_0 :try_start_0 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->y:Ljava/lang/reflect/Method; const/4 v1, 0x0 const/4 v2, 0x2 const/4 v3, 0x1 if-nez v0, :cond_1 .line 591 const-class v0, Landroid/widget/AbsListView; const-string v4, "trackMotionScroll" new-array v5, v2, [Ljava/lang/Class; sget-object v6, Ljava/lang/Integer;->TYPE:Ljava/lang/Class; aput-object v6, v5, v1 sget-object v6, Ljava/lang/Integer;->TYPE:Ljava/lang/Class; aput-object v6, v5, v3 invoke-virtual {v0, v4, v5}, Ljava/lang/Class;->getDeclaredMethod(Ljava/lang/String;[Ljava/lang/Class;)Ljava/lang/reflect/Method; move-result-object v0 iput-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->y:Ljava/lang/reflect/Method; .line 592 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->y:Ljava/lang/reflect/Method; if-eqz v0, :cond_1 .line 593 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->y:Ljava/lang/reflect/Method; invoke-virtual {v0, v3}, Ljava/lang/reflect/Method;->setAccessible(Z)V .line 596 :cond_1 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->y:Ljava/lang/reflect/Method; if-eqz v0, :cond_2 .line 597 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->y:Ljava/lang/reflect/Method; iget-object v4, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; new-array v2, v2, [Ljava/lang/Object; invoke-static {p1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer; move-result-object p1 aput-object p1, v2, v1 invoke-static {p2}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer; move-result-object p1 aput-object p1, v2, v3 invoke-virtual {v0, v4, v2}, Ljava/lang/reflect/Method;->invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object; :try_end_0 .catch Ljava/lang/NoSuchMethodException; {:try_start_0 .. :try_end_0} :catch_2 .catch Ljava/lang/IllegalAccessException; {:try_start_0 .. :try_end_0} :catch_1 .catch Ljava/lang/reflect/InvocationTargetException; {:try_start_0 .. :try_end_0} :catch_0 goto :goto_0 :catch_0 move-exception p1 const-string p2, "HomePageFrameLayout" .line 604 invoke-static {p2, p1}, Lcom/moji/tool/log/MJLogger;->a(Ljava/lang/String;Ljava/lang/Throwable;)V goto :goto_0 :catch_1 move-exception p1 const-string p2, "HomePageFrameLayout" .line 602 invoke-static {p2, p1}, Lcom/moji/tool/log/MJLogger;->a(Ljava/lang/String;Ljava/lang/Throwable;)V goto :goto_0 :catch_2 move-exception p1 const-string p2, "HomePageFrameLayout" .line 600 invoke-static {p2, p1}, Lcom/moji/tool/log/MJLogger;->a(Ljava/lang/String;Ljava/lang/Throwable;)V :cond_2 :goto_0 return-void .end method .method private b(Z)V .locals 1 .line 377 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getParent()Landroid/view/ViewParent; move-result-object v0 if-eqz v0, :cond_0 .line 379 invoke-interface {v0, p1}, Landroid/view/ViewParent;->requestDisallowInterceptTouchEvent(Z)V :cond_0 return-void .end method .method private c()V .locals 1 .line 539 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; if-nez v0, :cond_0 .line 540 invoke-static {}, Landroid/view/VelocityTracker;->obtain()Landroid/view/VelocityTracker; move-result-object v0 iput-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; goto :goto_0 .line 542 :cond_0 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; invoke-virtual {v0}, Landroid/view/VelocityTracker;->clear()V :goto_0 return-void .end method .method private d()V .locals 2 const/4 v0, 0x0 .line 547 iput-boolean v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c:Z .line 548 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b()V .line 549 sget v0, Landroid/os/Build$VERSION;->SDK_INT:I const/16 v1, 0x10 if-lt v0, v1, :cond_0 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->v:Landroid/widget/EdgeEffect; if-eqz v0, :cond_0 .line 550 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->v:Landroid/widget/EdgeEffect; invoke-virtual {v0}, Landroid/widget/EdgeEffect;->onRelease()V :cond_0 return-void .end method .method private d(I)Z .locals 3 .line 462 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; const/4 v1, 0x0 if-nez v0, :cond_0 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e()Z move-result v0 if-nez v0, :cond_0 return v1 :cond_0 const/4 v0, 0x1 if-ltz p1, :cond_1 .line 466 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {p1}, Lcom/moji/mjweather/weather/view/IndexListView;->getLastVisiblePosition()I move-result p1 iget-object v2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {v2}, Lcom/moji/mjweather/weather/view/IndexListView;->getAdapter()Landroid/widget/ListAdapter; move-result-object v2 invoke-interface {v2}, Landroid/widget/ListAdapter;->getCount()I move-result v2 sub-int/2addr v2, v0 if-ne p1, v2, :cond_2 .line 467 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; iget-object v2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {v2}, Lcom/moji/mjweather/weather/view/IndexListView;->getChildCount()I move-result v2 sub-int/2addr v2, v0 invoke-virtual {p1, v2}, Lcom/moji/mjweather/weather/view/IndexListView;->getChildAt(I)Landroid/view/View; move-result-object p1 if-eqz p1, :cond_2 .line 468 invoke-virtual {p1}, Landroid/view/View;->getTop()I move-result p1 if-gtz p1, :cond_2 return v0 .line 473 :cond_1 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {p1}, Lcom/moji/mjweather/weather/view/IndexListView;->getFirstVisiblePosition()I move-result p1 if-nez p1, :cond_2 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {p1}, Lcom/moji/mjweather/weather/view/IndexListView;->getChildCount()I move-result p1 if-lez p1, :cond_2 .line 474 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {p1, v1}, Lcom/moji/mjweather/weather/view/IndexListView;->getChildAt(I)Landroid/view/View; move-result-object p1 if-eqz p1, :cond_2 .line 475 invoke-virtual {p1}, Landroid/view/View;->getTop()I move-result p1 iget-object v2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {v2}, Lcom/moji/mjweather/weather/view/IndexListView;->getPaddingTop()I move-result v2 sub-int/2addr p1, v2 if-nez p1, :cond_2 return v0 :cond_2 return v1 .end method .method private static e(I)F .locals 0 if-lez p0, :cond_0 const/high16 p0, -0x3b060000 # -2000.0f goto :goto_0 :cond_0 const/high16 p0, 0x44fa0000 # 2000.0f :goto_0 return p0 .end method .method private e()Z .locals 3 const/4 v0, 0x0 const/4 v1, 0x0 .line 609 :goto_0 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getChildCount()I move-result v2 if-ge v1, v2, :cond_1 .line 610 invoke-virtual {p0, v1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getChildAt(I)Landroid/view/View; move-result-object v2 instance-of v2, v2, Landroid/widget/ListView; if-eqz v2, :cond_0 .line 611 invoke-virtual {p0, v1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getChildAt(I)Landroid/view/View; move-result-object v0 check-cast v0, Lcom/moji/mjweather/weather/view/IndexListView; iput-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; const/4 v0, 0x1 return v0 :cond_0 add-int/lit8 v1, v1, 0x1 goto :goto_0 :cond_1 return v0 .end method .method private f()Z .locals 2 .line 619 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getParent()Landroid/view/ViewParent; move-result-object v0 if-eqz v0, :cond_0 .line 620 instance-of v1, v0, Lcom/moji/mjweather/weather/WeatherPageView; if-eqz v1, :cond_0 .line 621 check-cast v0, Lcom/moji/mjweather/weather/WeatherPageView; iput-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->m:Lcom/moji/mjweather/weather/WeatherPageView; const/4 v0, 0x1 return v0 :cond_0 const/4 v0, 0x0 return v0 .end method .method private getMaxDy()I .locals 2 .line 576 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {v0}, Lcom/moji/mjweather/weather/view/IndexListView;->getLastVisiblePosition()I move-result v0 iget-object v1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {v1}, Lcom/moji/mjweather/weather/view/IndexListView;->getAdapter()Landroid/widget/ListAdapter; move-result-object v1 invoke-interface {v1}, Landroid/widget/ListAdapter;->getCount()I move-result v1 add-int/lit8 v1, v1, -0x1 if-ne v0, v1, :cond_0 .line 577 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; iget-object v1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {v1}, Lcom/moji/mjweather/weather/view/IndexListView;->getChildCount()I move-result v1 add-int/lit8 v1, v1, -0x1 invoke-virtual {v0, v1}, Lcom/moji/mjweather/weather/view/IndexListView;->getChildAt(I)Landroid/view/View; move-result-object v0 if-eqz v0, :cond_0 .line 579 invoke-virtual {v0}, Landroid/view/View;->getTop()I move-result v0 return v0 :cond_0 const v0, 0x7fffffff return v0 .end method # virtual methods .method public a(IF)I .locals 8 .line 634 invoke-static {p1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e(I)F move-result v0 int-to-double v1, p1 const-wide/high16 v3, -0x4000000000000000L # -2.0 .line 635 invoke-static {v1, v2}, Ljava/lang/Double;->isNaN(D)Z mul-double v1, v1, v3 float-to-double v3, v0 invoke-static {v3, v4}, Ljava/lang/Double;->isNaN(D)Z div-double/2addr v1, v3 invoke-static {v1, v2}, Ljava/lang/Math;->sqrt(D)D move-result-wide v0 const-wide v2, 0x408f400000000000L # 1000.0 mul-double v0, v0, v2 float-to-double v2, p2 invoke-static {v2, v3}, Ljava/lang/Double;->isNaN(D)Z div-double/2addr v0, v2 double-to-int p2, v0 const/4 v0, 0x1 .line 636 iput-boolean v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->t:Z .line 637 iget-object v2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->g:Landroid/widget/Scroller; const/4 v3, 0x0 const/4 v4, 0x0 const/4 v5, 0x0 move v6, p1 move v7, p2 invoke-virtual/range {v2 .. v7}, Landroid/widget/Scroller;->startScroll(IIIII)V const/4 p1, 0x0 .line 638 iput p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->p:I .line 639 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->invalidate()V return p2 .end method .method a(I)V .locals 1 const/4 v0, 0x0 .line 410 invoke-virtual {p0, p1, v0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a(IZ)V return-void .end method .method a(IZ)V .locals 1 .line 414 iget v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->r:I if-ne p1, v0, :cond_0 if-eqz p2, :cond_2 .line 415 :cond_0 iget-object p2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->q:Landroid/widget/AbsListView$OnScrollListener; if-eqz p2, :cond_2 .line 416 iput p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->r:I .line 417 iget-object p2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; if-nez p2, :cond_1 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e()Z move-result p2 if-nez p2, :cond_1 return-void .line 420 :cond_1 iget-object p2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->q:Landroid/widget/AbsListView$OnScrollListener; iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-interface {p2, v0, p1}, Landroid/widget/AbsListView$OnScrollListener;->onScrollStateChanged(Landroid/widget/AbsListView;I)V :cond_2 return-void .end method .method public a(Z)V .locals 0 .line 671 invoke-super {p0, p1}, Landroid/widget/FrameLayout;->requestDisallowInterceptTouchEvent(Z)V return-void .end method .method public b(I)V .locals 10 const/4 v0, 0x1 .line 429 iput-boolean v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->t:Z .line 431 iget-object v1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->g:Landroid/widget/Scroller; const/4 v2, 0x0 const/4 v4, 0x0 const/4 v6, 0x0 const v7, 0x7fffffff const/high16 v8, -0x80000000 const v9, 0x7fffffff const/4 v3, 0x0 move v5, p1 invoke-virtual/range {v1 .. v9}, Landroid/widget/Scroller;->fling(IIIIIIII)V const/4 p1, 0x0 .line 432 iput p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->p:I .line 433 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->s:Lcom/moji/mjweather/weather/view/HomePageFrameLayout$ScrollerFinalListener; if-eqz p1, :cond_0 .line 434 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->s:Lcom/moji/mjweather/weather/view/HomePageFrameLayout$ScrollerFinalListener; iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->g:Landroid/widget/Scroller; invoke-virtual {v0}, Landroid/widget/Scroller;->getFinalX()I move-result v0 iget-object v1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->g:Landroid/widget/Scroller; invoke-virtual {v1}, Landroid/widget/Scroller;->getFinalY()I move-result v1 invoke-interface {p1, v0, v1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout$ScrollerFinalListener;->a(II)V .line 436 :cond_0 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->invalidate()V return-void .end method .method public c(I)V .locals 2 .line 555 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; if-nez v0, :cond_0 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e()Z move-result v0 if-nez v0, :cond_0 return-void :cond_0 if-lez p1, :cond_1 .line 560 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getMaxDy()I move-result v0 invoke-static {p1, v0}, Ljava/lang/Math;->min(II)I move-result p1 .line 563 :cond_1 sget v0, Landroid/os/Build$VERSION;->SDK_INT:I const/16 v1, 0x13 if-lt v0, v1, :cond_2 .line 565 :try_start_0 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {v0, p1}, Lcom/moji/mjweather/weather/view/IndexListView;->scrollListBy(I)V :try_end_0 .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0 goto :goto_0 :catch_0 move-exception p1 const-string v0, "HomePageFrameLayout" .line 567 invoke-static {v0, p1}, Lcom/moji/tool/log/MJLogger;->a(Ljava/lang/String;Ljava/lang/Throwable;)V goto :goto_0 :cond_2 neg-int p1, p1 .line 571 invoke-direct {p0, p1, p1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b(II)V :goto_0 return-void .end method .method public computeScroll()V .locals 2 .line 441 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->g:Landroid/widget/Scroller; invoke-virtual {v0}, Landroid/widget/Scroller;->computeScrollOffset()Z move-result v0 if-eqz v0, :cond_1 const/4 v0, 0x2 .line 442 invoke-virtual {p0, v0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->startNestedScroll(I)Z .line 444 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->g:Landroid/widget/Scroller; invoke-virtual {v0}, Landroid/widget/Scroller;->getCurrY()I move-result v0 .line 445 iget v1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->p:I sub-int v1, v0, v1 .line 447 invoke-virtual {p0, v1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c(I)V .line 448 iput v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->p:I .line 449 invoke-direct {p0, v1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->d(I)Z move-result v0 if-eqz v0, :cond_0 .line 450 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->g:Landroid/widget/Scroller; invoke-virtual {v0}, Landroid/widget/Scroller;->abortAnimation()V .line 452 :cond_0 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->invalidate()V goto :goto_0 .line 453 :cond_1 iget-boolean v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->t:Z if-eqz v0, :cond_2 const/4 v0, 0x0 .line 454 iput-boolean v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->t:Z .line 455 iput-boolean v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->x:Z .line 456 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->stopNestedScroll()V const/4 v1, 0x1 .line 457 invoke-virtual {p0, v0, v1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a(IZ)V :cond_2 :goto_0 return-void .end method .method public dispatchNestedFling(FFZ)Z .locals 1 .line 152 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a:Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper; invoke-virtual {v0, p1, p2, p3}, Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper;->dispatchNestedFling(FFZ)Z move-result p1 return p1 .end method .method public dispatchNestedPreFling(FF)Z .locals 1 .line 157 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a:Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper; invoke-virtual {v0, p1, p2}, Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper;->dispatchNestedPreFling(FF)Z move-result p1 return p1 .end method .method public dispatchNestedPreScroll(II[I[I)Z .locals 1 .line 147 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a:Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper; invoke-virtual {v0, p1, p2, p3, p4}, Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper;->dispatchNestedPreScroll(II[I[I)Z move-result p1 return p1 .end method .method public dispatchNestedScroll(IIII[I)Z .locals 6 .line 141 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a:Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper; move v1, p1 move v2, p2 move v3, p3 move v4, p4 move-object v5, p5 invoke-virtual/range {v0 .. v5}, Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper;->dispatchNestedScroll(IIII[I)Z move-result p1 return p1 .end method .method public getIsForAbsorb()Z .locals 1 .line 658 iget-boolean v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->x:Z return v0 .end method .method public getTargetView()Landroid/view/View; .locals 1 .line 507 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; if-nez v0, :cond_0 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e()Z move-result v0 if-nez v0, :cond_0 const/4 v0, 0x0 return-object v0 .line 510 :cond_0 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; return-object v0 .end method .method public getTopView()Landroid/view/ViewParent; .locals 3 .line 485 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->o:Landroid/view/ViewGroup; if-eqz v0, :cond_0 .line 486 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->o:Landroid/view/ViewGroup; return-object v0 .line 488 :cond_0 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; if-nez v0, :cond_1 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e()Z move-result v0 if-nez v0, :cond_1 const/4 v0, 0x0 return-object v0 .line 491 :cond_1 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {v0}, Lcom/moji/mjweather/weather/view/IndexListView;->getFirstVisiblePosition()I move-result v0 if-nez v0, :cond_3 .line 492 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; const/4 v1, 0x0 invoke-virtual {v0, v1}, Lcom/moji/mjweather/weather/view/IndexListView;->getChildAt(I)Landroid/view/View; move-result-object v0 if-eqz v0, :cond_3 .line 493 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {v0, v1}, Lcom/moji/mjweather/weather/view/IndexListView;->getChildAt(I)Landroid/view/View; move-result-object v0 check-cast v0, Landroid/view/ViewGroup; .line 494 :goto_0 invoke-virtual {v0}, Landroid/view/ViewGroup;->getChildCount()I move-result v2 if-ge v1, v2, :cond_3 .line 495 invoke-virtual {v0, v1}, Landroid/view/ViewGroup;->getChildAt(I)Landroid/view/View; move-result-object v2 instance-of v2, v2, Lcom/moji/mjweather/weather/view/HomePageRelativeLayout; if-eqz v2, :cond_2 .line 496 invoke-virtual {v0, v1}, Landroid/view/ViewGroup;->getChildAt(I)Landroid/view/View; move-result-object v0 check-cast v0, Landroid/view/ViewGroup; iput-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->o:Landroid/view/ViewGroup; goto :goto_1 :cond_2 add-int/lit8 v1, v1, 0x1 goto :goto_0 .line 502 :cond_3 :goto_1 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->o:Landroid/view/ViewGroup; return-object v0 .end method .method public hasNestedScrollingParent()Z .locals 1 .line 135 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a:Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper; invoke-virtual {v0}, Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper;->hasNestedScrollingParent()Z move-result v0 return v0 .end method .method public isNestedScrollingEnabled()Z .locals 1 .line 120 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a:Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper; invoke-virtual {v0}, Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper;->isNestedScrollingEnabled()Z move-result v0 return v0 .end method .method protected onDraw(Landroid/graphics/Canvas;)V .locals 3 .line 385 invoke-super {p0, p1}, Landroid/widget/FrameLayout;->onDraw(Landroid/graphics/Canvas;)V .line 387 sget v0, Landroid/os/Build$VERSION;->SDK_INT:I const/16 v1, 0x10 if-lt v0, v1, :cond_0 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->v:Landroid/widget/EdgeEffect; if-eqz v0, :cond_0 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->v:Landroid/widget/EdgeEffect; invoke-virtual {v0}, Landroid/widget/EdgeEffect;->isFinished()Z move-result v0 if-nez v0, :cond_0 .line 388 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->v:Landroid/widget/EdgeEffect; invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getWidth()I move-result v1 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getHeight()I move-result v2 invoke-virtual {v0, v1, v2}, Landroid/widget/EdgeEffect;->setSize(II)V .line 389 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->v:Landroid/widget/EdgeEffect; invoke-virtual {v0, p1}, Landroid/widget/EdgeEffect;->draw(Landroid/graphics/Canvas;)Z move-result p1 if-eqz p1, :cond_0 .line 390 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->postInvalidateOnAnimation()V :cond_0 return-void .end method .method public onInterceptTouchEvent(Landroid/view/MotionEvent;)Z .locals 6 .line 162 invoke-virtual {p1}, Landroid/view/MotionEvent;->getAction()I move-result v0 const/4 v1, 0x2 const/4 v2, 0x1 if-ne v0, v1, :cond_0 .line 163 iget-boolean v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c:Z if-eqz v3, :cond_0 return v2 :cond_0 and-int/lit16 v0, v0, 0xff const/4 v3, -0x1 const/4 v4, 0x0 packed-switch v0, :pswitch_data_0 goto/16 :goto_0 .line 169 :pswitch_0 iget v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I if-ne v0, v3, :cond_1 goto/16 :goto_0 .line 175 :cond_1 invoke-virtual {p1, v0}, Landroid/view/MotionEvent;->findPointerIndex(I)I move-result v0 if-ne v0, v3, :cond_2 goto/16 :goto_0 .line 179 :cond_2 invoke-virtual {p1, v0}, Landroid/view/MotionEvent;->getY(I)F move-result v1 float-to-int v1, v1 .line 180 invoke-virtual {p1, v0}, Landroid/view/MotionEvent;->getX(I)F move-result v0 float-to-int v0, v0 .line 181 iget v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->h:I sub-int v3, v1, v3 invoke-static {v3}, Ljava/lang/Math;->abs(I)I move-result v3 .line 182 iget v5, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->i:I sub-int/2addr v0, v5 invoke-static {v0}, Ljava/lang/Math;->abs(I)I move-result v0 .line 183 iget v5, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->d:I if-le v0, v5, :cond_3 if-le v0, v3, :cond_3 .line 184 invoke-direct {p0, v4}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b(Z)V goto :goto_0 .line 187 :cond_3 iget v5, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->d:I if-le v3, v5, :cond_5 if-le v3, v0, :cond_5 .line 188 iput-boolean v2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c:Z .line 189 iput v1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->h:I .line 190 invoke-direct {p0, v2}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b(Z)V .line 191 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a()V .line 192 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; invoke-virtual {v0, p1}, Landroid/view/VelocityTracker;->addMovement(Landroid/view/MotionEvent;)V goto :goto_0 .line 230 :pswitch_1 iput-boolean v4, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c:Z .line 231 iput v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I .line 232 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b()V .line 233 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->stopNestedScroll()V .line 234 invoke-direct {p0, v4}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b(Z)V goto :goto_0 .line 199 :pswitch_2 invoke-virtual {p1}, Landroid/view/MotionEvent;->getY()F move-result v0 float-to-int v0, v0 .line 200 invoke-virtual {p1}, Landroid/view/MotionEvent;->getX()F move-result v3 float-to-int v3, v3 invoke-direct {p0, v3, v0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a(II)Z move-result v3 if-nez v3, :cond_4 .line 201 iput-boolean v4, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c:Z .line 202 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b()V goto :goto_0 .line 210 :cond_4 iput v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->h:I .line 211 invoke-virtual {p1}, Landroid/view/MotionEvent;->getX()F move-result v0 float-to-int v0, v0 iput v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->i:I .line 212 invoke-virtual {p1, v4}, Landroid/view/MotionEvent;->getPointerId(I)I move-result v0 iput v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I .line 214 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c()V .line 215 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; invoke-virtual {v0, p1}, Landroid/view/VelocityTracker;->addMovement(Landroid/view/MotionEvent;)V .line 221 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->g:Landroid/widget/Scroller; invoke-virtual {p1}, Landroid/widget/Scroller;->isFinished()Z move-result p1 xor-int/2addr p1, v2 iput-boolean p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c:Z .line 222 invoke-virtual {p0, v1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->startNestedScroll(I)Z .line 223 invoke-direct {p0, v2}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b(Z)V .line 242 :cond_5 :goto_0 iget-boolean p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c:Z if-eqz p1, :cond_7 .line 243 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->m:Lcom/moji/mjweather/weather/WeatherPageView; if-nez p1, :cond_6 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->f()Z move-result p1 if-nez p1, :cond_6 return v2 .line 246 :cond_6 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->m:Lcom/moji/mjweather/weather/WeatherPageView; invoke-virtual {p1}, Lcom/moji/mjweather/weather/WeatherPageView;->m()Z move-result p1 xor-int/2addr p1, v2 return p1 :cond_7 return v4 nop :pswitch_data_0 .packed-switch 0x0 :pswitch_2 :pswitch_1 :pswitch_0 :pswitch_1 .end packed-switch .end method .method public onTouchEvent(Landroid/view/MotionEvent;)Z .locals 8 .line 257 iget-boolean v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->u:Z const/4 v1, 0x1 if-nez v0, :cond_0 return v1 .line 260 :cond_0 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a()V .line 262 invoke-static {p1}, Landroid/view/MotionEvent;->obtain(Landroid/view/MotionEvent;)Landroid/view/MotionEvent; move-result-object v0 .line 264 invoke-virtual {p1}, Landroid/view/MotionEvent;->getActionMasked()I move-result v2 const/4 v3, 0x0 if-nez v2, :cond_1 .line 267 iput v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->f:I :cond_1 const/4 v4, 0x0 .line 269 iget v5, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->f:I int-to-float v5, v5 invoke-virtual {v0, v4, v5}, Landroid/view/MotionEvent;->offsetLocation(FF)V const/4 v4, 0x2 const/4 v5, -0x1 packed-switch v2, :pswitch_data_0 :pswitch_0 goto/16 :goto_3 .line 364 :pswitch_1 invoke-direct {p0, p1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a(Landroid/view/MotionEvent;)V .line 365 iget v2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I invoke-virtual {p1, v2}, Landroid/view/MotionEvent;->findPointerIndex(I)I move-result v2 invoke-virtual {p1, v2}, Landroid/view/MotionEvent;->getY(I)F move-result p1 float-to-int p1, p1 iput p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->h:I goto/16 :goto_3 .line 358 :pswitch_2 invoke-virtual {p1}, Landroid/view/MotionEvent;->getActionIndex()I move-result v2 .line 359 invoke-virtual {p1, v2}, Landroid/view/MotionEvent;->getY(I)F move-result v3 float-to-int v3, v3 iput v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->h:I .line 360 invoke-virtual {p1, v2}, Landroid/view/MotionEvent;->getPointerId(I)I move-result p1 iput p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I goto/16 :goto_3 .line 352 :pswitch_3 iget-boolean p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c:Z if-eqz p1, :cond_b invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getChildCount()I move-result p1 if-lez p1, :cond_b .line 353 iput v5, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I .line 354 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->d()V goto/16 :goto_3 .line 285 :pswitch_4 iget v2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I invoke-virtual {p1, v2}, Landroid/view/MotionEvent;->findPointerIndex(I)I move-result v2 if-ne v2, v5, :cond_2 goto/16 :goto_3 .line 290 :cond_2 invoke-virtual {p1, v2}, Landroid/view/MotionEvent;->getY(I)F move-result v4 float-to-int v4, v4 .line 291 iget v5, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->h:I sub-int/2addr v5, v4 .line 293 iget-boolean v6, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c:Z if-nez v6, :cond_5 invoke-static {v5}, Ljava/lang/Math;->abs(I)I move-result v6 iget v7, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->d:I if-le v6, v7, :cond_5 .line 294 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getParent()Landroid/view/ViewParent; move-result-object v6 if-eqz v6, :cond_3 .line 296 invoke-interface {v6, v1}, Landroid/view/ViewParent;->requestDisallowInterceptTouchEvent(Z)V .line 298 :cond_3 iput-boolean v1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c:Z if-lez v5, :cond_4 .line 300 iget v6, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->d:I sub-int/2addr v5, v6 goto :goto_0 .line 302 :cond_4 iget v6, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->d:I add-int/2addr v5, v6 .line 305 :cond_5 :goto_0 iget-boolean v6, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c:Z if-eqz v6, :cond_b .line 306 iput v4, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->h:I .line 307 iget-object v4, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->n:[I const/4 v6, 0x0 invoke-virtual {p0, v3, v5, v4, v6}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->dispatchNestedPreScroll(II[I[I)Z move-result v3 if-eqz v3, :cond_6 .line 308 iget-object v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->n:[I aget v3, v3, v1 sub-int/2addr v5, v3 .line 310 :cond_6 invoke-virtual {p0, v1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a(I)V .line 311 invoke-virtual {p0, v5}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c(I)V .line 314 sget v3, Landroid/os/Build$VERSION;->SDK_INT:I const/16 v4, 0x10 if-lt v3, v4, :cond_b iget-object v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->v:Landroid/widget/EdgeEffect; if-eqz v3, :cond_b iget-object v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; if-eqz v3, :cond_b iget-object v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {v3}, Lcom/moji/mjweather/weather/view/IndexListView;->b()Z move-result v3 if-eqz v3, :cond_b .line 315 iget-object v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->l:Lcom/moji/mjweather/weather/view/IndexListView; invoke-virtual {v3}, Lcom/moji/mjweather/weather/view/IndexListView;->getLastScrollY()I move-result v3 add-int/2addr v3, v5 if-gez v3, :cond_b .line 317 sget v3, Landroid/os/Build$VERSION;->SDK_INT:I const/16 v4, 0x15 if-lt v3, v4, :cond_7 .line 318 iget-object v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->v:Landroid/widget/EdgeEffect; int-to-float v4, v5 iget v5, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->w:I int-to-float v5, v5 div-float/2addr v4, v5 invoke-virtual {p1, v2}, Landroid/view/MotionEvent;->getX(I)F move-result p1 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->getWidth()I move-result v2 int-to-float v2, v2 div-float/2addr p1, v2 invoke-virtual {v3, v4, p1}, Landroid/widget/EdgeEffect;->onPull(FF)V goto :goto_1 .line 320 :cond_7 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->v:Landroid/widget/EdgeEffect; int-to-float v2, v5 iget v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->w:I int-to-float v3, v3 div-float/2addr v2, v3 invoke-virtual {p1, v2}, Landroid/widget/EdgeEffect;->onPull(F)V .line 322 :goto_1 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->v:Landroid/widget/EdgeEffect; invoke-virtual {p1}, Landroid/widget/EdgeEffect;->isFinished()Z move-result p1 if-nez p1, :cond_b .line 323 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->postInvalidateOnAnimation()V goto :goto_3 .line 331 :pswitch_5 iget-boolean p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->c:Z if-eqz p1, :cond_9 .line 332 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; const/16 v2, 0x3e8 .line 333 iget v6, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->k:I int-to-float v6, v6 invoke-virtual {p1, v2, v6}, Landroid/view/VelocityTracker;->computeCurrentVelocity(IF)V .line 334 iget v2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I invoke-virtual {p1, v2}, Landroid/view/VelocityTracker;->getYVelocity(I)F move-result p1 float-to-int p1, p1 .line 336 invoke-static {p1}, Ljava/lang/Math;->abs(I)I move-result v2 iget v6, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->j:I if-le v2, v6, :cond_8 .line 337 invoke-virtual {p0, v4}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a(I)V neg-int p1, p1 .line 338 invoke-virtual {p0, p1}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b(I)V goto :goto_2 .line 340 :cond_8 invoke-virtual {p0, v3}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a(I)V .line 343 :goto_2 iput v5, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I .line 344 invoke-direct {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->d()V .line 347 :cond_9 iget-boolean p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->t:Z if-nez p1, :cond_b .line 348 invoke-virtual {p0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->stopNestedScroll()V goto :goto_3 .line 273 :pswitch_6 iget-object v2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->g:Landroid/widget/Scroller; invoke-virtual {v2}, Landroid/widget/Scroller;->isFinished()Z move-result v2 if-nez v2, :cond_a .line 274 iget-object v2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->g:Landroid/widget/Scroller; invoke-virtual {v2}, Landroid/widget/Scroller;->abortAnimation()V .line 275 iput-boolean v3, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->t:Z .line 279 :cond_a invoke-virtual {p1}, Landroid/view/MotionEvent;->getY()F move-result v2 float-to-int v2, v2 iput v2, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->h:I .line 280 invoke-virtual {p1, v3}, Landroid/view/MotionEvent;->getPointerId(I)I move-result p1 iput p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->e:I .line 281 invoke-virtual {p0, v4}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->startNestedScroll(I)Z .line 369 :cond_b :goto_3 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; if-eqz p1, :cond_c .line 370 iget-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->b:Landroid/view/VelocityTracker; invoke-virtual {p1, v0}, Landroid/view/VelocityTracker;->addMovement(Landroid/view/MotionEvent;)V .line 372 :cond_c invoke-virtual {v0}, Landroid/view/MotionEvent;->recycle()V return v1 nop :pswitch_data_0 .packed-switch 0x0 :pswitch_6 :pswitch_5 :pswitch_4 :pswitch_3 :pswitch_0 :pswitch_2 :pswitch_1 .end packed-switch .end method .method public requestDisallowInterceptTouchEvent(Z)V .locals 3 const-string v0, "HomePageFrameLayout" .line 667 new-instance v1, Ljava/lang/StringBuilder; invoke-direct {v1}, Ljava/lang/StringBuilder;->()V const-string v2, "ignore requestDisallowInterceptTouchEvent:" invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder; invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Z)Ljava/lang/StringBuilder; invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String; move-result-object p1 invoke-static {v0, p1}, Lcom/moji/tool/log/MJLogger;->c(Ljava/lang/String;Ljava/lang/String;)V return-void .end method .method public setCanScrroll(Z)V .locals 0 .line 252 iput-boolean p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->u:Z return-void .end method .method public setFinalY(I)V .locals 1 const/high16 v0, 0x3f800000 # 1.0f .line 629 invoke-virtual {p0, p1, v0}, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a(IF)I return-void .end method .method public setIsForAbsorb(Z)V .locals 0 .line 662 iput-boolean p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->x:Z return-void .end method .method public setNestedScrollingEnabled(Z)V .locals 1 .line 115 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a:Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper; invoke-virtual {v0, p1}, Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper;->setNestedScrollingEnabled(Z)V return-void .end method .method public setOnScrollListener(Landroid/widget/AbsListView$OnScrollListener;)V .locals 0 .line 108 iput-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->q:Landroid/widget/AbsListView$OnScrollListener; return-void .end method .method public setScrollerFinalListener(Lcom/moji/mjweather/weather/view/HomePageFrameLayout$ScrollerFinalListener;)V .locals 0 .line 104 iput-object p1, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->s:Lcom/moji/mjweather/weather/view/HomePageFrameLayout$ScrollerFinalListener; return-void .end method .method public startNestedScroll(I)Z .locals 1 .line 125 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a:Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper; invoke-virtual {v0, p1}, Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper;->startNestedScroll(I)Z move-result p1 return p1 .end method .method public stopNestedScroll()V .locals 1 .line 130 iget-object v0, p0, Lcom/moji/mjweather/weather/view/HomePageFrameLayout;->a:Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper; invoke-virtual {v0}, Lcom/moji/mjweather/weather/view/HomePageNestedScrollingChildHelper;->stopNestedScroll()V return-void .end method