mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-23 06:35:51 +00:00
Local scrolling
This commit is contained in:
@@ -327,6 +327,7 @@ class ChatControllerNode: ASDisplayNode, UIScrollViewDelegate {
|
||||
self.historyNode.rotated = true
|
||||
|
||||
self.historyScrollingArea = SparseDiscreteScrollingArea()
|
||||
self.historyNode.historyScrollingArea = self.historyScrollingArea
|
||||
|
||||
self.historyNodeContainer = ASDisplayNode()
|
||||
self.historyNodeContainer.addSubnode(self.historyNode)
|
||||
@@ -529,23 +530,6 @@ class ChatControllerNode: ASDisplayNode, UIScrollViewDelegate {
|
||||
self.textInputPanelNode?.updateActivity = { [weak self] in
|
||||
self?.updateTypingActivity(true)
|
||||
}
|
||||
|
||||
self.historyNode.updateScrollingIndicator = { [weak self] scrollingState, transition in
|
||||
guard let strongSelf = self else {
|
||||
return
|
||||
}
|
||||
guard let (_, _) = strongSelf.validLayout else {
|
||||
return
|
||||
}
|
||||
strongSelf.historyScrollingArea.update(
|
||||
containerSize: strongSelf.historyNode.bounds.size,
|
||||
containerInsets: UIEdgeInsets(top: strongSelf.historyNode.scrollIndicatorInsets.bottom, left: 0.0, bottom: strongSelf.historyNode.scrollIndicatorInsets.top, right: 0.0),
|
||||
scrollingState: scrollingState,
|
||||
isScrolling: true,
|
||||
theme: strongSelf.chatPresentationInterfaceState.theme,
|
||||
transition: transition
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
deinit {
|
||||
|
||||
Reference in New Issue
Block a user