forked from gini/gini-mobile-ios
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(GiniHealthSDK): Fix navigation flow
IPC-429
- Loading branch information
1 parent
0e31d11
commit bee9b1f
Showing
4 changed files
with
69 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
GiniComponents/GiniUtilites/Sources/GiniUtilites/Extensions/UINavigationController.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
// | ||
// UINavigationController.swift | ||
// | ||
// Copyright © 2024 Gini GmbH. All rights reserved. | ||
// | ||
|
||
import UIKit | ||
|
||
extension UINavigationController { | ||
public func pushViewController(viewController: UIViewController, animated: Bool, completion: @escaping () -> Void) { | ||
pushViewController(viewController, animated: animated) | ||
|
||
if animated, let coordinator = transitionCoordinator { | ||
coordinator.animate(alongsideTransition: nil) { _ in | ||
completion() | ||
} | ||
} else { | ||
completion() | ||
} | ||
} | ||
|
||
public func popViewController(animated: Bool, completion: @escaping () -> Void) { | ||
popViewController(animated: animated) | ||
|
||
if animated, let coordinator = transitionCoordinator { | ||
coordinator.animate(alongsideTransition: nil) { _ in | ||
completion() | ||
} | ||
} else { | ||
completion() | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters