Refresh UI (including progress indicator) on Timeline when coming out of suspend.
This commit is contained in:
parent
9ba0b37cf9
commit
746d061dcf
|
@ -51,6 +51,7 @@ class MasterTimelineViewController: UITableViewController, UndoableCommandRunner
|
||||||
NotificationCenter.default.addObserver(self, selector: #selector(userDefaultsDidChange(_:)), name: UserDefaults.didChangeNotification, object: nil)
|
NotificationCenter.default.addObserver(self, selector: #selector(userDefaultsDidChange(_:)), name: UserDefaults.didChangeNotification, object: nil)
|
||||||
NotificationCenter.default.addObserver(self, selector: #selector(contentSizeCategoryDidChange), name: UIContentSizeCategory.didChangeNotification, object: nil)
|
NotificationCenter.default.addObserver(self, selector: #selector(contentSizeCategoryDidChange), name: UIContentSizeCategory.didChangeNotification, object: nil)
|
||||||
NotificationCenter.default.addObserver(self, selector: #selector(displayNameDidChange), name: .DisplayNameDidChange, object: nil)
|
NotificationCenter.default.addObserver(self, selector: #selector(displayNameDidChange), name: .DisplayNameDidChange, object: nil)
|
||||||
|
NotificationCenter.default.addObserver(self, selector: #selector(willEnterForeground(_:)), name: UIApplication.willEnterForegroundNotification, object: nil)
|
||||||
|
|
||||||
// Setup the Search Controller
|
// Setup the Search Controller
|
||||||
searchController.delegate = self
|
searchController.delegate = self
|
||||||
|
@ -448,6 +449,10 @@ class MasterTimelineViewController: UITableViewController, UndoableCommandRunner
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@objc func willEnterForeground(_ note: Notification) {
|
||||||
|
updateUI()
|
||||||
|
}
|
||||||
|
|
||||||
@objc func scrollPositionDidChange() {
|
@objc func scrollPositionDidChange() {
|
||||||
coordinator.timelineMiddleIndexPath = tableView.middleVisibleRow()
|
coordinator.timelineMiddleIndexPath = tableView.middleVisibleRow()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue