|
@@ -12,7 +12,7 @@
|
12
|
12
|
@implementation RNNModalManager {
|
13
|
13
|
NSMutableArray* _pendingModalIdsToDismiss;
|
14
|
14
|
NSMutableArray* _presentedModals;
|
15
|
|
- RCTUIManager* _uiManager;
|
|
15
|
+ RCTBridge* _bridge;
|
16
|
16
|
}
|
17
|
17
|
|
18
|
18
|
|
|
@@ -20,13 +20,12 @@
|
20
|
20
|
self = [super init];
|
21
|
21
|
_pendingModalIdsToDismiss = [[NSMutableArray alloc] init];
|
22
|
22
|
_presentedModals = [[NSMutableArray alloc] init];
|
23
|
|
-
|
24
|
23
|
return self;
|
25
|
24
|
}
|
26
|
25
|
|
27
|
|
-- (instancetype)initWithUIManager:(RCTUIManager *)uiManager {
|
|
26
|
+- (instancetype)initWithBridge:(RCTBridge *)bridge {
|
28
|
27
|
self = [self init];
|
29
|
|
- _uiManager = uiManager;
|
|
28
|
+ _bridge = bridge;
|
30
|
29
|
return self;
|
31
|
30
|
}
|
32
|
31
|
|
|
@@ -45,7 +44,7 @@
|
45
|
44
|
}
|
46
|
45
|
|
47
|
46
|
if (viewController.resolveOptionsWithDefault.animations.showModal.hasAnimation) {
|
48
|
|
- _modalTransitionDelegate = [[ModalTransitionDelegate alloc] initWithContentTransition:viewController.resolveOptionsWithDefault.animations.showModal uiManager:_uiManager];
|
|
47
|
+ _modalTransitionDelegate = [[ModalTransitionDelegate alloc] initWithContentTransition:viewController.resolveOptionsWithDefault.animations.showModal bridge:_bridge];
|
49
|
48
|
viewController.transitioningDelegate = _modalTransitionDelegate;
|
50
|
49
|
viewController.modalPresentationStyle = UIModalPresentationCustom;
|
51
|
50
|
}
|
|
@@ -101,7 +100,7 @@
|
101
|
100
|
UIViewController* topPresentedVC = [self topPresentedVC];
|
102
|
101
|
|
103
|
102
|
if (optionsWithDefault.animations.dismissModal.hasAnimation) {
|
104
|
|
- _modalTransitionDelegate = [[ModalDismissTransitionDelegate alloc] initWithContentTransition:modalToDismiss.resolveOptionsWithDefault.animations.dismissModal uiManager:_uiManager];
|
|
103
|
+ _modalTransitionDelegate = [[ModalDismissTransitionDelegate alloc] initWithContentTransition:modalToDismiss.resolveOptionsWithDefault.animations.dismissModal bridge:_bridge];
|
105
|
104
|
[self topViewControllerParent:modalToDismiss].transitioningDelegate = _modalTransitionDelegate;
|
106
|
105
|
}
|
107
|
106
|
|