From f3bb821520fb8b6ae34ed21fe980a0b2e68d2195 Mon Sep 17 00:00:00 2001 From: hetykai Date: Mon, 22 Dec 2014 17:05:39 +0800 Subject: [PATCH] Update PullToRefreshAdapterViewBase.java MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit when i use PullToRefreshGridView , I have 10 items , every row display 3 items , screen just display 3 rows, the last items can not display anyway , I modify this , it works . 当我用PullToRefreshGridView时, 我有10个item, 每一行显示3个item, 屏幕上显示了三行刚好把屏幕占满, 无论怎么拖动最后一个item总是显示不出来, 我修改成这样就好了。 --- .../pulltorefresh/library/PullToRefreshAdapterViewBase.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/src/com/handmark/pulltorefresh/library/PullToRefreshAdapterViewBase.java b/library/src/com/handmark/pulltorefresh/library/PullToRefreshAdapterViewBase.java index cfff83716..ab21d8672 100644 --- a/library/src/com/handmark/pulltorefresh/library/PullToRefreshAdapterViewBase.java +++ b/library/src/com/handmark/pulltorefresh/library/PullToRefreshAdapterViewBase.java @@ -423,7 +423,7 @@ private boolean isLastItemVisible() { * account for it and rely on the inner condition which checks * getBottom(). */ - if (lastVisiblePosition >= lastItemPosition - 1) { + if (lastVisiblePosition >= lastItemPosition) { final int childIndex = lastVisiblePosition - mRefreshableView.getFirstVisiblePosition(); final View lastVisibleChild = mRefreshableView.getChildAt(childIndex); if (lastVisibleChild != null) {