Various fixes

This commit is contained in:
Ilya Laktyushin
2025-04-14 19:16:00 +04:00
parent c3051cbf90
commit 1f051f737a
4 changed files with 30 additions and 11 deletions

View File

@@ -1370,6 +1370,16 @@ final class ContextControllerNode: ViewControllerTracingNode, ASScrollViewDelega
}
}
func animateDismissalIfNeeded() {
guard let layout = self.validLayout, layout.metrics.isTablet else {
return
}
if let sourceContainer = self.sourceContainer {
sourceContainer.animateOut(result: .dismissWithoutContent, completion: {})
return
}
}
func getActionsMinHeight() -> ContextController.ActionsHeight? {
if !self.actionsContainerNode.bounds.height.isZero {
return ContextController.ActionsHeight(
@@ -2789,6 +2799,10 @@ public final class ContextController: ViewController, StandalonePresentableContr
}
}
public func animateDismissalIfNeeded() {
self.controllerNode.animateDismissalIfNeeded()
}
public func cancelReactionAnimation() {
self.controllerNode.cancelReactionAnimation()
}