OSDN Git Service

Fix bug 3242393 - overscroll effect missing from lists which drag but
authorAdam Powell <adamp@google.com>
Mon, 24 Jan 2011 22:55:00 +0000 (14:55 -0800)
committerAdam Powell <adamp@google.com>
Mon, 24 Jan 2011 22:55:00 +0000 (14:55 -0800)
are always visible

Change-Id: I20d73c452c7b98f1a046e356d0c6cdbfc8e5fe7a

core/java/android/widget/AbsListView.java

index fc5c893..6d66bbc 100644 (file)
@@ -1098,7 +1098,8 @@ public abstract class AbsListView extends AdapterView<ListAdapter> implements Te
         if (childCount == 0) return true;
         if (childCount != mItemCount) return false;
 
-        return getChildAt(0).getTop() >= 0 && getChildAt(childCount - 1).getBottom() <= mBottom;
+        return getChildAt(0).getTop() >= mListPadding.top &&
+                getChildAt(childCount - 1).getBottom() <= getHeight() - mListPadding.bottom;
     }
 
     /**