0

我如何测试用户是否ListView在一直向上滚动时向上滚动?

answersListView.setOnScrollListener(new OnScrollListener() {
    @Override
    public void onScrollStateChanged(AbsListView view,int scrollState){
        // TODO Auto-generated method stub
    }

    @Override
    public void onScroll(AbsListView view,int firstVisibleItem, int visibleItemCount,
    int totalItemCount) {
        // TODO Auto-generated method stub
    }
});
4

1 回答 1

1

看看android-pulltorefresh, 特别是onTouchEvent和方法。基本上,你应该有onScrollonScrollStateChangedonTouchEvent

于 2013-08-03T13:39:24.853 回答