mirror of
https://github.com/wahyd4/Yep.git
synced 2026-08-26 05:05:52 +10:00
delay 0.3s before finish for pullToRefreshView in Feeds
This commit is contained in:
@@ -1267,9 +1267,11 @@ extension FeedsViewController: PullToRefreshViewDelegate {
|
||||
activityIndicator.alpha = 0
|
||||
|
||||
let finish: () -> Void = { [weak self] in
|
||||
pulllToRefreshView.endRefreshingAndDoFurtherAction() {}
|
||||
delay(0.3) { // 人为延迟,增加等待感
|
||||
pulllToRefreshView.endRefreshingAndDoFurtherAction() {}
|
||||
|
||||
self?.activityIndicator.alpha = 1
|
||||
self?.activityIndicator.alpha = 1
|
||||
}
|
||||
}
|
||||
|
||||
pullToRefreshView.refreshTimeoutAction = finish
|
||||
|
||||
Reference in New Issue
Block a user