mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-23 14:45:21 +00:00
Various fixes
This commit is contained in:
@@ -392,7 +392,10 @@ public class AttachmentController: ViewController {
|
||||
self.container.interactivelyDismissed = { [weak self] velocity in
|
||||
if let strongSelf = self, let layout = strongSelf.validLayout {
|
||||
if let controller = strongSelf.controller, controller.shouldMinimizeOnSwipe?(strongSelf.currentType) == true {
|
||||
let delta = layout.size.height - controller.minimizedTopEdgeOffset
|
||||
var delta = layout.size.height
|
||||
if let minimizedTopEdgeOffset = controller.minimizedTopEdgeOffset {
|
||||
delta -= minimizedTopEdgeOffset
|
||||
}
|
||||
let damping: CGFloat = 180.0
|
||||
let initialVelocity: CGFloat = delta > 0.0 ? velocity / delta : 0.0
|
||||
|
||||
|
||||
Reference in New Issue
Block a user