I have develop an application that have one list view and i used Pull to refresh for refresh list data while pull down so i implemented in my code perfectly but i get one issue when i am scroll up list scroll down but when i am scroll down its not scroll done because its consider pull to refresh and refresh data but i want to make it when display list index 0 then it work pull to refresh
so please help me about this
my code is
listNotification = (ListView) rootView.findViewById(R.id.listNotification);
listNotification.setCacheColorHint(0);
swipeLayout = (SwipeRefreshLayout) rootView.findViewById(R.id.swipe_container);
swipeLayout.setOnRefreshListener(this);
swipeLayout.setColorScheme(android.R.color.holo_blue_bright, android.R.color.holo_green_light, android.R.color.holo_orange_light, android.R.color.holo_red_light);
if (Global.notifications == null) {
swipeLayout.setRefreshing(true);
new GetNotificationList().execute();
}
LoadNotificationToListView();
on refresh
@Override
public void onRefresh() {
new GetNotificationList().execute();
}