Commit b9a25764 by Daniel Dahan

Added begin / end transition methods for from / to view controllers.

parent 9d898243
## 1.2.4
* Added begin / end transition methods for from / to view controllers.
## 1.2.3 ## 1.2.3
* Replaced DispatchQueue.main.async calls to Motion.async. * Replaced DispatchQueue.main.async calls to Motion.async.
......
Pod::Spec.new do |s| Pod::Spec.new do |s|
s.name = 'Motion' s.name = 'Motion'
s.version = '1.2.3' s.version = '1.2.4'
s.license = 'MIT' s.license = 'MIT'
s.summary = 'A library used to create beautiful animations and transitions for Apple devices.' s.summary = 'A library used to create beautiful animations and transitions for Apple devices.'
s.homepage = 'http://cosmicmind.com' s.homepage = 'http://cosmicmind.com'
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>FMWK</string> <string>FMWK</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>1.2.3</string> <string>1.2.4</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string> <string>$(CURRENT_PROJECT_VERSION)</string>
<key>NSPrincipalClass</key> <key>NSPrincipalClass</key>
......
...@@ -526,6 +526,9 @@ fileprivate extension Motion { ...@@ -526,6 +526,9 @@ fileprivate extension Motion {
return return
} }
fvc.beginAppearanceTransition(false, animated: true)
tvc.beginAppearanceTransition(true, animated: true)
processForMotionDelegate(viewController: fvc) { [weak self] in processForMotionDelegate(viewController: fvc) { [weak self] in
guard let s = self else { guard let s = self else {
return return
...@@ -560,6 +563,9 @@ fileprivate extension Motion { ...@@ -560,6 +563,9 @@ fileprivate extension Motion {
return return
} }
tvc.endAppearanceTransition()
fvc.endAppearanceTransition()
processForMotionDelegate(viewController: fvc) { [weak self] in processForMotionDelegate(viewController: fvc) { [weak self] in
guard let s = self else { guard let s = self else {
return return
...@@ -596,6 +602,9 @@ fileprivate extension Motion { ...@@ -596,6 +602,9 @@ fileprivate extension Motion {
return return
} }
tvc.endAppearanceTransition()
fvc.endAppearanceTransition()
processForMotionDelegate(viewController: fvc) { [weak self] in processForMotionDelegate(viewController: fvc) { [weak self] in
guard let s = self else { guard let s = self else {
return return
...@@ -727,6 +736,7 @@ extension Motion: UIViewControllerInteractiveTransitioning { ...@@ -727,6 +736,7 @@ extension Motion: UIViewControllerInteractiveTransitioning {
public var wantsInteractiveStart: Bool { public var wantsInteractiveStart: Bool {
return true return true
} }
public func startInteractiveTransition(_ transitionContext: UIViewControllerContextTransitioning) { public func startInteractiveTransition(_ transitionContext: UIViewControllerContextTransitioning) {
animateTransition(using: transitionContext) animateTransition(using: transitionContext)
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment