When switch fragment with SwipeRefreshLayout during refreshing, fragment freezes but actually still work

Well… After some struggling I eventually solved this problem by myself, in a tricky way… I just need to add these in onPause() : @Override public void onPause() { super.onPause(); … if (mSwipeRefreshLayout!=null) { mSwipeRefreshLayout.setRefreshing(false); mSwipeRefreshLayout.destroyDrawingCache(); mSwipeRefreshLayout.clearAnimation(); } }

Android: CollapsingToolbarLayout and SwipeRefreshLayout get stuck

Update: This issue has been resolved in the latest version of the support library (23.1.1+). If you are using an older version of the support library either upgrade or continue reading. If you’re using an older version of the support library, add an offset change listener to your AppBarLayout to enable or disable your swipe … Read more

HorizontalScrollView inside SwipeRefreshLayout

I solved it by extending SwipeRefreshLayout and overriding its onInterceptTouchEvent. Inside, I calculate if the X distance the user has wandered is bigger than the touch slop. If it does, it means the user is swiping horizontally, therefor I return false which lets the child view (the HorizontalScrollView in this case) to get the touch … Read more