Compare commits
No commits in common. "9c103103e8cb8641fd3deb94bf8c2158cc04bdec" and "2891f47cb34167e715d92b2c917a85bf03919c86" have entirely different histories.
9c103103e8
...
2891f47cb3
|
@ -85,14 +85,14 @@ class TrendingStatusesViewController: UIViewController {
|
|||
override func viewWillAppear(_ animated: Bool) {
|
||||
super.viewWillAppear(animated)
|
||||
|
||||
if !loaded {
|
||||
loaded = true
|
||||
var snapshot = NSDiffableDataSourceSnapshot<Section, Item>()
|
||||
snapshot.appendSections([.statuses])
|
||||
snapshot.appendItems([.loadingIndicator])
|
||||
dataSource.apply(snapshot, animatingDifferences: false)
|
||||
|
||||
Task {
|
||||
var snapshot = NSDiffableDataSourceSnapshot<Section, Item>()
|
||||
snapshot.appendSections([.statuses])
|
||||
snapshot.appendItems([.loadingIndicator])
|
||||
dataSource.apply(snapshot, animatingDifferences: false)
|
||||
|
||||
Task {
|
||||
if !loaded {
|
||||
loaded = true
|
||||
await loadTrendingStatuses()
|
||||
}
|
||||
}
|
||||
|
|
|
@ -35,15 +35,7 @@ extension ToastableViewController {
|
|||
}
|
||||
|
||||
var toastParentView: UIView { view }
|
||||
var toastScrollView: UIScrollView? {
|
||||
if let scrollView = view as? UIScrollView {
|
||||
return scrollView
|
||||
} else if let collectionVC = self as? CollectionViewController {
|
||||
return collectionVC.collectionView
|
||||
} else {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
var toastScrollView: UIScrollView? { view as? UIScrollView }
|
||||
|
||||
func showToast(configuration config: ToastConfiguration, animated: Bool) {
|
||||
currentToast?.dismissToast(animated: false)
|
||||
|
|
Loading…
Reference in New Issue