2013年2月5日 星期二

Pull Down to Refresh UI Design

   The action of pull down and refresh is normal feature in mobile app. but the official SDK isn't support it. so we find some  open source  :


i use the Android-PullToRefresh. because it support :
  • ListView
  • ExpandableListView
  • GridView
  • WebView
  • ScrollView
  • HorizontalScrollView
  • ViewPager

we just replace my GridView into PullToRefreshGridView, and setOnRefreshListener().

public static interface OnRefreshListener<V extends View>{
    public void onRefresh(final PullToRefreshBase<V> refreshView);
}

Remember, you should call onRefreshComplete() let the UI stop the animation.

沒有留言:

張貼留言