mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-22 22:25:57 +00:00
Update PlayerV2
This commit is contained in:
@@ -54,6 +54,7 @@ final class VideoNavigationControllerDropContentItem: NavigationControllerDropCo
|
||||
}
|
||||
|
||||
private final class ChatControllerNodeView: UITracingLayerView, WindowInputAccessoryHeightProvider {
|
||||
weak var node: ChatControllerNode?
|
||||
var inputAccessoryHeight: (() -> CGFloat)?
|
||||
var hitTestImpl: ((CGPoint, UIEvent?) -> UIView?)?
|
||||
|
||||
@@ -65,7 +66,17 @@ private final class ChatControllerNodeView: UITracingLayerView, WindowInputAcces
|
||||
if let result = self.hitTestImpl?(point, event) {
|
||||
return result
|
||||
}
|
||||
return super.hitTest(point, with: event)
|
||||
guard let result = super.hitTest(point, with: event) else {
|
||||
return nil
|
||||
}
|
||||
if let node = self.node {
|
||||
if result === node.historyNodeContainer.view {
|
||||
if node.historyNode.alpha == 0.0 {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
}
|
||||
return result
|
||||
}
|
||||
}
|
||||
|
||||
@@ -172,7 +183,7 @@ class ChatControllerNode: ASDisplayNode, ASScrollViewDelegate {
|
||||
private(set) var validLayout: (ContainerViewLayout, CGFloat)?
|
||||
private var visibleAreaInset = UIEdgeInsets()
|
||||
|
||||
private var searchNavigationNode: ChatSearchNavigationContentNode?
|
||||
private(set) var searchNavigationNode: ChatSearchNavigationContentNode?
|
||||
|
||||
private var navigationModalFrame: NavigationModalFrame?
|
||||
|
||||
@@ -727,6 +738,8 @@ class ChatControllerNode: ASDisplayNode, ASScrollViewDelegate {
|
||||
return ChatControllerNodeView()
|
||||
})
|
||||
|
||||
(self.view as? ChatControllerNodeView)?.node = self
|
||||
|
||||
(self.view as? ChatControllerNodeView)?.inputAccessoryHeight = { [weak self] in
|
||||
if let strongSelf = self {
|
||||
return strongSelf.getWindowInputAccessoryHeight()
|
||||
|
||||
Reference in New Issue
Block a user