diff --git a/MJRefresh/Base/MJRefreshHeader.m b/MJRefresh/Base/MJRefreshHeader.m index 070cea6c..f9d5c8f0 100644 --- a/MJRefresh/Base/MJRefreshHeader.m +++ b/MJRefresh/Base/MJRefreshHeader.m @@ -124,17 +124,15 @@ - (void)setState:(MJRefreshState)state } }]; } else if (state == MJRefreshStateRefreshing) { - dispatch_async(dispatch_get_main_queue(), ^{ - [UIView animateWithDuration:MJRefreshFastAnimationDuration animations:^{ - CGFloat top = self.scrollViewOriginalInset.top + self.mj_h; - // 增加滚动区域top - self.scrollView.mj_insetT = top; - // 设置滚动位置 - [self.scrollView setContentOffset:CGPointMake(0, -top) animated:NO]; - } completion:^(BOOL finished) { - [self executeRefreshingCallback]; - }]; - }); + [UIView animateWithDuration:MJRefreshFastAnimationDuration animations:^{ + CGFloat top = self.scrollViewOriginalInset.top + self.mj_h; + // 增加滚动区域top + self.scrollView.mj_insetT = top; + // 设置滚动位置 + [self.scrollView setContentOffset:CGPointMake(0, -top) animated:NO]; + } completion:^(BOOL finished) { + [self executeRefreshingCallback]; + }]; } }