mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-15 18:59:54 +00:00
Cleanup
This commit is contained in:
parent
f27bc011dc
commit
9cb0610c4b
@ -227,9 +227,7 @@ public extension ContainedViewLayoutTransition {
|
||||
case .spring:
|
||||
timingFunction = kCAMediaTimingFunctionSpring
|
||||
}
|
||||
node.layer.animateBoundsOriginXAdditive(from: offset, to: 0.0, duration: duration, timingFunction: timingFunction, completion: { completed in
|
||||
print("completed \(completed)")
|
||||
})
|
||||
node.layer.animateBoundsOriginXAdditive(from: offset, to: 0.0, duration: duration, timingFunction: timingFunction)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -384,6 +384,18 @@ open class ViewControllerPresentationArguments {
|
||||
}
|
||||
}
|
||||
|
||||
@available(iOSApplicationExtension 9.0, *)
|
||||
public func registerForPreviewingNonNative(with delegate: UIViewControllerPreviewingDelegate, sourceView: UIView, theme: PeekControllerTheme) {
|
||||
if self.traitCollection.forceTouchCapability != .available {
|
||||
if self.previewingContext == nil {
|
||||
let previewingContext = SimulatedViewControllerPreviewing(theme: theme, delegate: delegate, sourceView: sourceView, node: self.displayNode, present: { [weak self] c, a in
|
||||
self?.presentInGlobalOverlay(c, with: a)
|
||||
})
|
||||
self.previewingContext = previewingContext
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@available(iOSApplicationExtension 9.0, *)
|
||||
open override func unregisterForPreviewing(withContext previewing: UIViewControllerPreviewing) {
|
||||
if self.previewingContext != nil {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user