mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-22 14:20:20 +00:00
Auto-remove fixes
This commit is contained in:
@@ -50,7 +50,7 @@ private final class InnerActionsContainerNode: ASDisplayNode {
|
||||
private let feedbackTap: () -> Void
|
||||
|
||||
private(set) var gesture: UIGestureRecognizer?
|
||||
private var currentHighlightedActionNode: ContextActionNode?
|
||||
private var currentHighlightedActionNode: ContextActionNodeProtocol?
|
||||
|
||||
var panSelectionGestureEnabled: Bool = true {
|
||||
didSet {
|
||||
@@ -291,13 +291,17 @@ private final class InnerActionsContainerNode: ASDisplayNode {
|
||||
self.containerNode.backgroundColor = presentationData.theme.contextMenu.backgroundColor
|
||||
}
|
||||
|
||||
func actionNode(at point: CGPoint) -> ContextActionNode? {
|
||||
func actionNode(at point: CGPoint) -> ContextActionNodeProtocol? {
|
||||
for itemNode in self.itemNodes {
|
||||
switch itemNode {
|
||||
case let .action(actionNode):
|
||||
if actionNode.frame.contains(point) {
|
||||
return actionNode
|
||||
}
|
||||
case let .custom(node):
|
||||
if let node = node as? ContextActionNodeProtocol, node.frame.contains(point) {
|
||||
return node
|
||||
}
|
||||
default:
|
||||
break
|
||||
}
|
||||
@@ -536,7 +540,7 @@ final class ContextActionsContainerNode: ASDisplayNode {
|
||||
self.scrollNode.frame = CGRect(origin: CGPoint(), size: containerSize)
|
||||
}
|
||||
|
||||
func actionNode(at point: CGPoint) -> ContextActionNode? {
|
||||
func actionNode(at point: CGPoint) -> ContextActionNodeProtocol? {
|
||||
return self.actionsNode.actionNode(at: self.view.convert(point, to: self.actionsNode.view))
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user