hybrid-navigation 3.1.4 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -4
- package/android/build.gradle +1 -2
- package/android/src/main/java/androidx/fragment/app/InternalFragment.java +22 -0
- package/android/src/main/java/com/navigation/androidx/AppUtils.java +54 -0
- package/android/src/main/java/com/navigation/androidx/AwesomeActivity.java +211 -0
- package/android/src/main/java/com/navigation/androidx/AwesomeFragment.java +685 -0
- package/android/src/main/java/com/navigation/androidx/BarStyle.java +7 -0
- package/android/src/main/java/com/navigation/androidx/DefaultTabBarProvider.java +89 -0
- package/android/src/main/java/com/navigation/androidx/DrawableUtils.java +57 -0
- package/android/src/main/java/com/navigation/androidx/DrawerFragment.java +392 -0
- package/android/src/main/java/com/navigation/androidx/FragmentHelper.java +318 -0
- package/android/src/main/java/com/navigation/androidx/LifecycleDelegate.java +86 -0
- package/android/src/main/java/com/navigation/androidx/PresentableActivity.java +23 -0
- package/android/src/main/java/com/navigation/androidx/PresentationDelegate.java +195 -0
- package/android/src/main/java/com/navigation/androidx/PresentationStyle.java +5 -0
- package/android/src/main/java/com/navigation/androidx/StackDelegate.java +111 -0
- package/android/src/main/java/com/navigation/androidx/StackFragment.java +287 -0
- package/android/src/main/java/com/navigation/androidx/StackLayoutInflater.java +34 -0
- package/android/src/main/java/com/navigation/androidx/Style.java +141 -0
- package/android/src/main/java/com/navigation/androidx/SystemUI.java +240 -0
- package/android/src/main/java/com/navigation/androidx/SystemUI30.java +87 -0
- package/android/src/main/java/com/navigation/androidx/TabBar.java +353 -0
- package/android/src/main/java/com/navigation/androidx/TabBarFragment.java +313 -0
- package/android/src/main/java/com/navigation/androidx/TabBarItem.java +102 -0
- package/android/src/main/java/com/navigation/androidx/TabBarProvider.java +30 -0
- package/android/src/main/java/com/navigation/androidx/TabView.java +226 -0
- package/android/src/main/java/com/navigation/androidx/TransitionAnimation.java +31 -0
- package/android/src/main/java/com/reactnative/hybridnavigation/Garden.java +6 -243
- package/android/src/main/java/com/reactnative/hybridnavigation/GlobalStyle.java +8 -141
- package/android/src/main/java/com/reactnative/hybridnavigation/HBDRootView.java +4 -68
- package/android/src/main/java/com/reactnative/hybridnavigation/HybridFragment.java +12 -61
- package/android/src/main/java/com/reactnative/hybridnavigation/NativeGarden.java +0 -47
- package/android/src/main/java/com/reactnative/hybridnavigation/Parameters.java +3 -3
- package/android/src/main/java/com/reactnative/hybridnavigation/ReactAppCompatActivityDelegate.java +2 -0
- package/android/src/main/java/com/reactnative/hybridnavigation/ReactFragment.java +1 -88
- package/android/src/main/java/com/reactnative/hybridnavigation/ReactManager.java +0 -5
- package/android/src/main/java/com/reactnative/hybridnavigation/ReactStackFragment.java +0 -18
- package/android/src/main/java/com/reactnative/hybridnavigation/ReactTabBarFragment.java +1 -0
- package/android/src/main/java/com/reactnative/hybridnavigation/Utils.java +1 -10
- package/android/src/main/res/anim/{nav_push_translucent_enter.xml → nav_delay.xml} +1 -1
- package/android/src/main/res/anim/{nav_pop_translucent_enter.xml → nav_dismiss_enter.xml} +1 -1
- package/android/src/main/res/anim/nav_dismiss_exit.xml +6 -0
- package/android/src/main/res/anim/nav_fade_in.xml +5 -0
- package/android/src/main/res/anim/nav_fade_out.xml +5 -0
- package/android/src/main/res/anim/nav_pop_enter.xml +6 -0
- package/android/src/main/res/anim/nav_pop_exit.xml +6 -0
- package/android/src/main/res/anim/nav_present_enter.xml +6 -0
- package/android/src/main/res/anim/{nav_pop_translucent_exit.xml → nav_present_exit.xml} +1 -1
- package/android/src/main/res/anim/nav_push_enter.xml +6 -0
- package/android/src/main/res/anim/{nav_push_translucent_exit.xml → nav_push_exit.xml} +2 -1
- package/android/src/main/res/drawable/nav_dot_badge_background.xml +5 -0
- package/android/src/main/res/drawable/nav_text_badge_background.xml +5 -0
- package/android/src/main/res/drawable-v21/nav_toolbar_button_item_background.xml +24 -0
- package/android/src/main/res/layout/nav_fragment_drawer.xml +23 -0
- package/android/src/main/res/layout/nav_fragment_navigation.xml +7 -0
- package/android/src/main/res/layout/nav_fragment_tabbar.xml +13 -0
- package/android/src/main/res/layout/nav_tab_bar_container.xml +15 -0
- package/android/src/main/res/layout/nav_tab_bar_item.xml +49 -0
- package/android/src/main/res/values/dimens.xml +11 -0
- package/android/src/main/res/values/strings.xml +1 -0
- package/dist/{NativeEvent.d.ts → src/NativeEvent.d.ts} +0 -5
- package/dist/{NativeGarden.d.ts → src/NativeGarden.d.ts} +0 -5
- package/dist/{Navigation.d.ts → src/Navigation.d.ts} +1 -11
- package/dist/{Navigation.js → src/Navigation.js} +1 -31
- package/dist/{Navigator.js → src/Navigator.js} +0 -4
- package/dist/src/Options.d.ts +61 -0
- package/dist/src/Options.js +2 -0
- package/ios/GlobalStyle.h +1 -9
- package/ios/GlobalStyle.mm +48 -310
- package/ios/HBDUtils.h +0 -14
- package/ios/HBDUtils.mm +1 -116
- package/ios/HybridNavigation.h +0 -3
- package/ios/Navigator/HBDScreenNavigator.mm +31 -13
- package/ios/Navigator/HBDStackNavigator.mm +36 -39
- package/ios/React/HBDNativeGarden.mm +0 -40
- package/ios/React/HBDNativeNavigation.mm +21 -16
- package/ios/View/HBDRootView.h +0 -2
- package/ios/View/HBDRootView.mm +0 -21
- package/ios/View/UIImage+WithBadge.mm +14 -36
- package/ios/ViewController/HBDDrawerController.mm +3 -11
- package/ios/ViewController/HBDFadeAnimation.mm +10 -26
- package/ios/ViewController/HBDNavigationController.h +0 -6
- package/ios/ViewController/HBDNavigationController.mm +42 -661
- package/ios/ViewController/HBDReactViewController.mm +7 -101
- package/ios/ViewController/HBDTabBarController.mm +10 -6
- package/ios/ViewController/HBDViewController.h +2 -0
- package/ios/ViewController/HBDViewController.mm +58 -182
- package/ios/ViewController/UINavigationController+HBD.mm +0 -3
- package/ios/ViewController/UIViewController+HBD.h +0 -9
- package/ios/ViewController/UIViewController+HBD.mm +1 -131
- package/package.json +1 -1
- package/src/NativeEvent.ts +0 -6
- package/src/NativeGarden.ts +0 -11
- package/src/Navigation.ts +2 -68
- package/src/Navigator.ts +0 -5
- package/src/Options.ts +2 -76
- package/dist/Options.d.ts +0 -129
- package/dist/Options.js +0 -6
- package/dist/handler/BarButtonEventHandler.d.ts +0 -10
- package/dist/handler/BarButtonEventHandler.js +0 -38
- package/ios/View/HBDBackBarButtonItem.h +0 -9
- package/ios/View/HBDBackBarButtonItem.mm +0 -13
- package/ios/View/HBDBarButtonItem.h +0 -24
- package/ios/View/HBDBarButtonItem.mm +0 -69
- package/ios/View/HBDNavigationBar.h +0 -15
- package/ios/View/HBDNavigationBar.mm +0 -207
- package/ios/View/HBDTitleView.h +0 -7
- package/ios/View/HBDTitleView.mm +0 -66
- package/ios/ViewController/HBDPopAnimation.h +0 -9
- package/ios/ViewController/HBDPopAnimation.mm +0 -27
- package/ios/ViewController/HBDPushAnimation.h +0 -9
- package/ios/ViewController/HBDPushAnimation.mm +0 -28
- package/ios/ViewController/HBDViewController+Garden.h +0 -17
- package/ios/ViewController/HBDViewController+Garden.mm +0 -183
- package/src/handler/BarButtonEventHandler.ts +0 -50
- /package/dist/{DeepLink.d.ts → src/DeepLink.d.ts} +0 -0
- /package/dist/{DeepLink.js → src/DeepLink.js} +0 -0
- /package/dist/{NativeEvent.js → src/NativeEvent.js} +0 -0
- /package/dist/{NativeGarden.js → src/NativeGarden.js} +0 -0
- /package/dist/{NativeNavigation.d.ts → src/NativeNavigation.d.ts} +0 -0
- /package/dist/{NativeNavigation.js → src/NativeNavigation.js} +0 -0
- /package/dist/{NavigationComponentWrap.d.ts → src/NavigationComponentWrap.d.ts} +0 -0
- /package/dist/{NavigationComponentWrap.js → src/NavigationComponentWrap.js} +0 -0
- /package/dist/{Navigator.d.ts → src/Navigator.d.ts} +0 -0
- /package/dist/{Route.d.ts → src/Route.d.ts} +0 -0
- /package/dist/{Route.js → src/Route.js} +0 -0
- /package/dist/{handler → src/handler}/DispatchCommandHandler.d.ts +0 -0
- /package/dist/{handler → src/handler}/DispatchCommandHandler.js +0 -0
- /package/dist/{handler → src/handler}/LayoutCommandHandler.d.ts +0 -0
- /package/dist/{handler → src/handler}/LayoutCommandHandler.js +0 -0
- /package/dist/{handler → src/handler}/ResultEventHandler.d.ts +0 -0
- /package/dist/{handler → src/handler}/ResultEventHandler.js +0 -0
- /package/dist/{handler → src/handler}/VisibilityEventHandler.d.ts +0 -0
- /package/dist/{handler → src/handler}/VisibilityEventHandler.js +0 -0
- /package/dist/{hooks.d.ts → src/hooks.d.ts} +0 -0
- /package/dist/{hooks.js → src/hooks.js} +0 -0
- /package/dist/{index.d.ts → src/index.d.ts} +0 -0
- /package/dist/{index.js → src/index.js} +0 -0
- /package/dist/{router → src/router}/drawer.d.ts +0 -0
- /package/dist/{router → src/router}/drawer.js +0 -0
- /package/dist/{router → src/router}/index.d.ts +0 -0
- /package/dist/{router → src/router}/index.js +0 -0
- /package/dist/{router → src/router}/screen.d.ts +0 -0
- /package/dist/{router → src/router}/screen.js +0 -0
- /package/dist/{router → src/router}/stack.d.ts +0 -0
- /package/dist/{router → src/router}/stack.js +0 -0
- /package/dist/{router → src/router}/tabs.d.ts +0 -0
- /package/dist/{router → src/router}/tabs.js +0 -0
- /package/dist/{store.d.ts → src/store.d.ts} +0 -0
- /package/dist/{store.js → src/store.js} +0 -0
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
#import "HBDReactBridgeManager.h"
|
|
4
4
|
#import "HBDNavigationController.h"
|
|
5
|
+
#import "HBDViewController.h"
|
|
5
6
|
#import "UIViewController+HBD.h"
|
|
6
7
|
|
|
7
8
|
#import <React/RCTLog.h>
|
|
@@ -21,7 +22,7 @@
|
|
|
21
22
|
if (!model) {
|
|
22
23
|
return nil;
|
|
23
24
|
}
|
|
24
|
-
|
|
25
|
+
|
|
25
26
|
NSString *moduleName = model[@"moduleName"];
|
|
26
27
|
NSDictionary *props = model[@"props"];
|
|
27
28
|
NSDictionary *options = model[@"options"];
|
|
@@ -54,27 +55,27 @@
|
|
|
54
55
|
[self handlePresentWithViewController:vc extras:extras callback:callback];
|
|
55
56
|
return;
|
|
56
57
|
}
|
|
57
|
-
|
|
58
|
+
|
|
58
59
|
if ([action isEqualToString:@"dismiss"]) {
|
|
59
60
|
[self handleDismissWithViewController:vc callback:callback];
|
|
60
61
|
return;
|
|
61
62
|
}
|
|
62
|
-
|
|
63
|
+
|
|
63
64
|
if ([action isEqualToString:@"showModal"]) {
|
|
64
65
|
[self handleShowModalWithViewController:vc extras:extras callback:callback];
|
|
65
66
|
return;
|
|
66
67
|
}
|
|
67
|
-
|
|
68
|
+
|
|
68
69
|
if ([action isEqualToString:@"hideModal"]) {
|
|
69
70
|
[self handleDismissWithViewController:vc callback:callback];
|
|
70
71
|
return;
|
|
71
72
|
}
|
|
72
|
-
|
|
73
|
+
|
|
73
74
|
if ([action isEqualToString:@"presentLayout"]) {
|
|
74
75
|
[self handlePresentLayoutWithViewController:vc extras:extras callback:callback];
|
|
75
76
|
return;
|
|
76
77
|
}
|
|
77
|
-
|
|
78
|
+
|
|
78
79
|
if ([action isEqualToString:@"showModalLayout"]) {
|
|
79
80
|
[self handleShowModalLayoutWithViewController:vc extras:extras callback:callback];
|
|
80
81
|
return;
|
|
@@ -86,7 +87,7 @@
|
|
|
86
87
|
callback(@[NSNull.null, @NO]);
|
|
87
88
|
return;
|
|
88
89
|
}
|
|
89
|
-
|
|
90
|
+
|
|
90
91
|
UIViewController *vc = [self viewControllerWithExtras:extras];
|
|
91
92
|
NSInteger requestCode = [extras[@"requestCode"] integerValue];
|
|
92
93
|
HBDNavigationController *nav = [[HBDNavigationController alloc] initWithRootViewController:vc];
|
|
@@ -100,14 +101,31 @@
|
|
|
100
101
|
}];
|
|
101
102
|
}
|
|
102
103
|
|
|
104
|
+
- (UIViewController *)modalHostViewControllerForViewController:(UIViewController *)vc {
|
|
105
|
+
UIViewController *host = vc;
|
|
106
|
+
while (host.parentViewController != nil) {
|
|
107
|
+
host = host.parentViewController;
|
|
108
|
+
}
|
|
109
|
+
return host;
|
|
110
|
+
}
|
|
111
|
+
|
|
103
112
|
- (void)handleDismissWithViewController:(UIViewController *) vc callback:(RCTResponseSenderBlock)callback {
|
|
104
113
|
BOOL animated = YES;
|
|
105
114
|
if ([vc isKindOfClass:[HBDViewController class]]) {
|
|
106
115
|
HBDViewController *hbdvc = (HBDViewController *)vc;
|
|
107
116
|
animated = hbdvc.animatedTransition;
|
|
108
117
|
}
|
|
109
|
-
|
|
110
|
-
|
|
118
|
+
|
|
119
|
+
UIViewController *modalHost = [self modalHostViewControllerForViewController:vc];
|
|
120
|
+
UIViewController *presenting = modalHost.presentingViewController;
|
|
121
|
+
|
|
122
|
+
[modalHost dismissViewControllerAnimated:animated completion:^{
|
|
123
|
+
if (presenting != nil) {
|
|
124
|
+
HBDViewController *hbdvc = [[HBDReactBridgeManager get] primaryViewControllerWithViewController:presenting];
|
|
125
|
+
if (hbdvc != nil) {
|
|
126
|
+
[hbdvc adjustScreenOrientation];
|
|
127
|
+
}
|
|
128
|
+
}
|
|
111
129
|
callback(@[NSNull.null, @YES]);
|
|
112
130
|
}];
|
|
113
131
|
}
|
|
@@ -117,19 +135,19 @@
|
|
|
117
135
|
callback(@[NSNull.null, @NO]);
|
|
118
136
|
return;
|
|
119
137
|
}
|
|
120
|
-
|
|
138
|
+
|
|
121
139
|
UIViewController *vc = [self viewControllerWithExtras:extras];
|
|
122
140
|
NSInteger requestCode = [extras[@"requestCode"] integerValue];
|
|
123
141
|
vc.modalPresentationStyle = UIModalPresentationOverFullScreen;
|
|
124
142
|
vc.modalTransitionStyle = UIModalTransitionStyleCrossDissolve;
|
|
125
143
|
[vc setRequestCode:requestCode];
|
|
126
|
-
|
|
144
|
+
|
|
127
145
|
BOOL animated = YES;
|
|
128
146
|
if ([vc isKindOfClass:[HBDViewController class]]) {
|
|
129
147
|
HBDViewController *hbdvc = (HBDViewController *)vc;
|
|
130
148
|
animated = hbdvc.animatedTransition;
|
|
131
149
|
}
|
|
132
|
-
|
|
150
|
+
|
|
133
151
|
[presenting presentViewController:vc animated:animated completion:^{
|
|
134
152
|
callback(@[NSNull.null, @YES]);
|
|
135
153
|
}];
|
|
@@ -173,7 +191,7 @@
|
|
|
173
191
|
}
|
|
174
192
|
|
|
175
193
|
- (void)invalidate {
|
|
176
|
-
//
|
|
194
|
+
//
|
|
177
195
|
}
|
|
178
196
|
|
|
179
197
|
@end
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
if (!model) {
|
|
22
22
|
return nil;
|
|
23
23
|
}
|
|
24
|
-
|
|
24
|
+
|
|
25
25
|
NSArray *children = model[@"children"];
|
|
26
26
|
UIViewController *vc = [[HBDReactBridgeManager get] viewControllerWithLayout:children.firstObject];
|
|
27
27
|
return [[HBDNavigationController alloc] initWithRootViewController:vc];
|
|
@@ -31,9 +31,9 @@
|
|
|
31
31
|
if (![vc isKindOfClass:[HBDNavigationController class]]) {
|
|
32
32
|
return nil;
|
|
33
33
|
}
|
|
34
|
-
|
|
34
|
+
|
|
35
35
|
HBDNavigationController *nav = (HBDNavigationController *) vc;
|
|
36
|
-
|
|
36
|
+
|
|
37
37
|
NSMutableArray *children = [[NSMutableArray alloc] init];
|
|
38
38
|
for (NSUInteger i = 0; i < nav.childViewControllers.count; i++) {
|
|
39
39
|
UIViewController *child = nav.childViewControllers[i];
|
|
@@ -82,27 +82,27 @@
|
|
|
82
82
|
[self handlePushWithNavigationController:nav extras:extras callback:callback];
|
|
83
83
|
return;
|
|
84
84
|
}
|
|
85
|
-
|
|
85
|
+
|
|
86
86
|
if ([action isEqualToString:@"pop"]) {
|
|
87
87
|
[self handlePopWithNavigationController:nav viewController:vc callback:callback];
|
|
88
88
|
return;
|
|
89
89
|
}
|
|
90
|
-
|
|
90
|
+
|
|
91
91
|
if ([action isEqualToString:@"popTo"]) {
|
|
92
92
|
[self handlePopToWithNavigationController:nav extras:extras callback:callback];
|
|
93
93
|
return;
|
|
94
94
|
}
|
|
95
|
-
|
|
95
|
+
|
|
96
96
|
if ([action isEqualToString:@"popToRoot"]) {
|
|
97
97
|
[self handlePopToRootWithNavigationController:nav extras:extras callback:callback];
|
|
98
98
|
return;
|
|
99
99
|
}
|
|
100
|
-
|
|
100
|
+
|
|
101
101
|
if ([action isEqualToString:@"redirectTo"]) {
|
|
102
102
|
[self handleRedirectToWithNavigationController:nav target:vc extras:extras callback:callback];
|
|
103
103
|
return;
|
|
104
104
|
}
|
|
105
|
-
|
|
105
|
+
|
|
106
106
|
if ([action isEqualToString:@"pushLayout"]) {
|
|
107
107
|
[self handlePushLayoutWithNavigationController:nav extras:extras callback:callback];
|
|
108
108
|
return;
|
|
@@ -117,14 +117,12 @@
|
|
|
117
117
|
return;
|
|
118
118
|
}
|
|
119
119
|
|
|
120
|
-
vc.hidesBottomBarWhenPushed = nav.hidesBottomBarWhenPushed;
|
|
121
|
-
|
|
122
120
|
BOOL animated = YES;
|
|
123
121
|
if ([vc isKindOfClass:[HBDViewController class]]) {
|
|
124
122
|
HBDViewController *hdbvc = (HBDViewController *)vc;
|
|
125
123
|
animated = hdbvc.animatedTransition || hdbvc.forceScreenLandscape;
|
|
126
124
|
}
|
|
127
|
-
|
|
125
|
+
|
|
128
126
|
if (animated) {
|
|
129
127
|
[nav pushViewController:vc animated:YES];
|
|
130
128
|
[self animateAlongsideTransition:nav callback:callback];
|
|
@@ -140,7 +138,7 @@
|
|
|
140
138
|
HBDViewController *hdbvc = (HBDViewController *)vc;
|
|
141
139
|
animated = hdbvc.animatedTransition || hdbvc.forceScreenLandscape;
|
|
142
140
|
}
|
|
143
|
-
|
|
141
|
+
|
|
144
142
|
if (animated) {
|
|
145
143
|
[nav popViewControllerAnimated:YES];
|
|
146
144
|
[self animateAlongsideTransition:nav callback:callback];
|
|
@@ -157,15 +155,15 @@
|
|
|
157
155
|
callback(@[NSNull.null, @NO]);
|
|
158
156
|
return;
|
|
159
157
|
}
|
|
160
|
-
|
|
158
|
+
|
|
161
159
|
UIViewController *from_vc = [self findFromViewControllerWithNavigationController:nav extras:extras];
|
|
162
|
-
|
|
160
|
+
|
|
163
161
|
BOOL animated = YES;
|
|
164
162
|
if ([from_vc isKindOfClass:[HBDViewController class]]) {
|
|
165
163
|
HBDViewController *hbdvc = (HBDViewController *)from_vc;
|
|
166
|
-
animated = hbdvc.animatedTransition;
|
|
164
|
+
animated = hbdvc.animatedTransition || hbdvc.forceScreenLandscape;
|
|
167
165
|
}
|
|
168
|
-
|
|
166
|
+
|
|
169
167
|
if (animated) {
|
|
170
168
|
[nav popToViewController:vc animated:YES];
|
|
171
169
|
[self animateAlongsideTransition:nav callback:callback];
|
|
@@ -173,14 +171,14 @@
|
|
|
173
171
|
[nav popToViewController:vc animated:NO];
|
|
174
172
|
callback(@[NSNull.null, @YES]);
|
|
175
173
|
}
|
|
176
|
-
|
|
174
|
+
|
|
177
175
|
}
|
|
178
176
|
|
|
179
177
|
- (UIViewController *)findFromViewControllerWithNavigationController:(UINavigationController *)nav extras:(NSDictionary *)extras {
|
|
180
178
|
NSArray *children = nav.childViewControllers;
|
|
181
179
|
NSString *moduleName = extras[@"from"];
|
|
182
180
|
BOOL inclusive = [extras[@"inclusive"] boolValue];
|
|
183
|
-
|
|
181
|
+
|
|
184
182
|
for (NSUInteger i = children.count; i > 0; i--) {
|
|
185
183
|
NSUInteger index = i - 1;
|
|
186
184
|
HBDViewController *vc = children[index];
|
|
@@ -191,7 +189,7 @@
|
|
|
191
189
|
return vc;
|
|
192
190
|
}
|
|
193
191
|
}
|
|
194
|
-
|
|
192
|
+
|
|
195
193
|
return nil;
|
|
196
194
|
}
|
|
197
195
|
|
|
@@ -199,7 +197,7 @@
|
|
|
199
197
|
NSArray *children = nav.childViewControllers;
|
|
200
198
|
NSString *moduleName = extras[@"moduleName"];
|
|
201
199
|
BOOL inclusive = [extras[@"inclusive"] boolValue];
|
|
202
|
-
|
|
200
|
+
|
|
203
201
|
for (NSUInteger i = children.count; i > 0; i--) {
|
|
204
202
|
NSUInteger index = i - 1;
|
|
205
203
|
HBDViewController *vc = children[index];
|
|
@@ -210,21 +208,21 @@
|
|
|
210
208
|
return vc;
|
|
211
209
|
}
|
|
212
210
|
}
|
|
213
|
-
|
|
211
|
+
|
|
214
212
|
return nil;
|
|
215
213
|
}
|
|
216
214
|
|
|
217
215
|
- (void)handlePopToRootWithNavigationController:(UINavigationController *)nav extras:(NSDictionary *)extras callback:(RCTResponseSenderBlock)callback {
|
|
218
|
-
|
|
216
|
+
|
|
219
217
|
UIViewController *from_vc = [self findFromViewControllerWithNavigationController:nav extras:extras];
|
|
220
|
-
|
|
218
|
+
|
|
221
219
|
BOOL animated = YES;
|
|
222
|
-
|
|
220
|
+
|
|
223
221
|
if ([from_vc isKindOfClass:[HBDViewController class]]) {
|
|
224
222
|
HBDViewController *hbdvc = (HBDViewController *)from_vc;
|
|
225
|
-
animated = hbdvc.animatedTransition;
|
|
223
|
+
animated = hbdvc.animatedTransition || hbdvc.forceScreenLandscape;
|
|
226
224
|
}
|
|
227
|
-
|
|
225
|
+
|
|
228
226
|
if (animated) {
|
|
229
227
|
[nav popToRootViewControllerAnimated:YES];
|
|
230
228
|
[self animateAlongsideTransition:nav callback:callback];
|
|
@@ -242,12 +240,12 @@
|
|
|
242
240
|
return;
|
|
243
241
|
}
|
|
244
242
|
BOOL animated = YES;
|
|
245
|
-
|
|
243
|
+
|
|
246
244
|
if ([vc isKindOfClass:[HBDViewController class]]) {
|
|
247
245
|
HBDViewController *hbdvc = (HBDViewController *)vc;
|
|
248
|
-
animated = hbdvc.animatedTransition;
|
|
246
|
+
animated = hbdvc.animatedTransition || hbdvc.forceScreenLandscape;
|
|
249
247
|
}
|
|
250
|
-
|
|
248
|
+
|
|
251
249
|
if (animated) {
|
|
252
250
|
[nav redirectToViewController:vc target:target animated:YES];
|
|
253
251
|
[self animateAlongsideTransition:nav callback:callback];
|
|
@@ -255,7 +253,7 @@
|
|
|
255
253
|
[nav redirectToViewController:vc target:target animated:NO];
|
|
256
254
|
callback(@[NSNull.null, @YES]);
|
|
257
255
|
}
|
|
258
|
-
|
|
256
|
+
|
|
259
257
|
}
|
|
260
258
|
|
|
261
259
|
- (void)handlePushLayoutWithNavigationController:(UINavigationController *)nav extras:(NSDictionary *)extras callback:(RCTResponseSenderBlock)callback {
|
|
@@ -266,8 +264,7 @@
|
|
|
266
264
|
callback(@[NSNull.null, @NO]);
|
|
267
265
|
return;
|
|
268
266
|
}
|
|
269
|
-
|
|
270
|
-
vc.hidesBottomBarWhenPushed = nav.hidesBottomBarWhenPushed;
|
|
267
|
+
|
|
271
268
|
[nav pushViewController:vc animated:YES];
|
|
272
269
|
[self animateAlongsideTransition:nav callback:callback];
|
|
273
270
|
}
|
|
@@ -277,7 +274,7 @@
|
|
|
277
274
|
callback(@[NSNull.null, @YES]);
|
|
278
275
|
return;
|
|
279
276
|
}
|
|
280
|
-
|
|
277
|
+
|
|
281
278
|
[nav.transitionCoordinator animateAlongsideTransition:^(id<UIViewControllerTransitionCoordinatorContext> _Nonnull context) {
|
|
282
279
|
// empty
|
|
283
280
|
} completion:^(id<UIViewControllerTransitionCoordinatorContext> _Nonnull context) {
|
|
@@ -296,17 +293,17 @@
|
|
|
296
293
|
if ([vc isKindOfClass:[UINavigationController class]]) {
|
|
297
294
|
return (UINavigationController *)vc;
|
|
298
295
|
}
|
|
299
|
-
|
|
296
|
+
|
|
300
297
|
UINavigationController *nav = vc.navigationController;
|
|
301
298
|
if (nav) {
|
|
302
299
|
return nav;
|
|
303
300
|
}
|
|
304
|
-
|
|
301
|
+
|
|
305
302
|
HBDDrawerController *drawer = vc.drawerController;
|
|
306
303
|
if (!drawer) {
|
|
307
304
|
return nil;
|
|
308
305
|
}
|
|
309
|
-
|
|
306
|
+
|
|
310
307
|
if ([drawer.contentController isKindOfClass:[UITabBarController class]]) {
|
|
311
308
|
UITabBarController *tabs = (UITabBarController *)drawer.contentController;
|
|
312
309
|
if ([tabs.selectedViewController isKindOfClass:[UINavigationController class]]) {
|
|
@@ -314,16 +311,16 @@
|
|
|
314
311
|
}
|
|
315
312
|
return nil;
|
|
316
313
|
}
|
|
317
|
-
|
|
314
|
+
|
|
318
315
|
if ([drawer.contentController isKindOfClass:[UINavigationController class]]) {
|
|
319
316
|
return (UINavigationController *)drawer.contentController;
|
|
320
317
|
}
|
|
321
|
-
|
|
318
|
+
|
|
322
319
|
return drawer.contentController.navigationController;
|
|
323
320
|
}
|
|
324
321
|
|
|
325
322
|
- (void)invalidate {
|
|
326
|
-
//
|
|
323
|
+
//
|
|
327
324
|
}
|
|
328
325
|
|
|
329
326
|
@end
|
|
@@ -49,22 +49,6 @@
|
|
|
49
49
|
return [self constantsToExport];
|
|
50
50
|
}
|
|
51
51
|
|
|
52
|
-
- (void)setLeftBarButtonItem:(nonnull NSString *)sceneId item:(NSDictionary * _Nullable)item {
|
|
53
|
-
HBDViewController *vc = [self viewControllerWithSceneId:sceneId];
|
|
54
|
-
if (vc) {
|
|
55
|
-
[vc updateNavigationBarOptions:@{@"leftBarButtonItem": RCTNullIfNil(item)}];
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
- (void)setLeftBarButtonItems:(nonnull NSString *)sceneId items:(NSArray * _Nullable)items {
|
|
61
|
-
HBDViewController *vc = [self viewControllerWithSceneId:sceneId];
|
|
62
|
-
if (vc) {
|
|
63
|
-
[vc updateNavigationBarOptions:@{@"leftBarButtonItems": RCTNullIfNil(items)}];
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
|
|
68
52
|
- (void)setMenuInteractive:(nonnull NSString *)sceneId enabled:(BOOL)enabled {
|
|
69
53
|
UIViewController *vc = [self.bridgeManager viewControllerBySceneId:sceneId];
|
|
70
54
|
HBDDrawerController *drawer = [vc drawerController];
|
|
@@ -74,22 +58,6 @@
|
|
|
74
58
|
}
|
|
75
59
|
|
|
76
60
|
|
|
77
|
-
- (void)setRightBarButtonItem:(nonnull NSString *)sceneId item:(NSDictionary * _Nullable)item {
|
|
78
|
-
HBDViewController *vc = [self viewControllerWithSceneId:sceneId];
|
|
79
|
-
if (vc) {
|
|
80
|
-
[vc updateNavigationBarOptions:@{@"rightBarButtonItem": RCTNullIfNil(item)}];
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
- (void)setRightBarButtonItems:(nonnull NSString *)sceneId items:(NSArray * _Nullable)items {
|
|
86
|
-
HBDViewController *vc = [self viewControllerWithSceneId:sceneId];
|
|
87
|
-
if (vc) {
|
|
88
|
-
[vc updateNavigationBarOptions:@{@"rightBarButtonItems": RCTNullIfNil(items)}];
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
|
|
93
61
|
- (void)setStyle:(nonnull NSDictionary *)style {
|
|
94
62
|
[GlobalStyle createWithOptions:style];
|
|
95
63
|
}
|
|
@@ -106,14 +74,6 @@
|
|
|
106
74
|
}
|
|
107
75
|
|
|
108
76
|
|
|
109
|
-
- (void)setTitleItem:(nonnull NSString *)sceneId item:(nonnull NSDictionary *)item {
|
|
110
|
-
HBDViewController *vc = [self viewControllerWithSceneId:sceneId];
|
|
111
|
-
if (vc) {
|
|
112
|
-
[vc updateNavigationBarOptions:@{@"titleItem": RCTNullIfNil(item)}];
|
|
113
|
-
}
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
|
|
117
77
|
- (void)updateOptions:(nonnull NSString *)sceneId options:(nonnull NSDictionary *)options {
|
|
118
78
|
RCTLogInfo(@"[Navigation] updateNavigationBarOptions: %@", options);
|
|
119
79
|
HBDViewController *vc = [self viewControllerWithSceneId:sceneId];
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
|
|
15
15
|
@implementation HBDNativeNavigation
|
|
16
16
|
|
|
17
|
-
+ (NSString *)moduleName {
|
|
17
|
+
+ (NSString *)moduleName {
|
|
18
18
|
return @"HBDNativeNavigation";
|
|
19
19
|
}
|
|
20
20
|
|
|
@@ -43,11 +43,11 @@
|
|
|
43
43
|
[self.bridgeManager invalidate];
|
|
44
44
|
}
|
|
45
45
|
|
|
46
|
-
- (std::shared_ptr<facebook::react::TurboModule>)getTurboModule:(const facebook::react::ObjCTurboModule::InitParams &)params {
|
|
46
|
+
- (std::shared_ptr<facebook::react::TurboModule>)getTurboModule:(const facebook::react::ObjCTurboModule::InitParams &)params {
|
|
47
47
|
return std::make_shared<facebook::react::NativeNavigationSpecJSI>(params);
|
|
48
48
|
}
|
|
49
49
|
|
|
50
|
-
- (nonnull facebook::react::ModuleConstants<JS::NativeNavigation::Constants::Builder>)constantsToExport {
|
|
50
|
+
- (nonnull facebook::react::ModuleConstants<JS::NativeNavigation::Constants::Builder>)constantsToExport {
|
|
51
51
|
JS::NativeNavigation::Constants::Builder::Input input = {
|
|
52
52
|
ResultOK,
|
|
53
53
|
ResultCancel,
|
|
@@ -90,7 +90,7 @@
|
|
|
90
90
|
}
|
|
91
91
|
}
|
|
92
92
|
|
|
93
|
-
- (void)currentRoute:(nonnull RCTResponseSenderBlock)callback {
|
|
93
|
+
- (void)currentRoute:(nonnull RCTResponseSenderBlock)callback {
|
|
94
94
|
[self performSelector:@selector(currentRouteWithCallback:) withObject:callback];
|
|
95
95
|
}
|
|
96
96
|
|
|
@@ -98,14 +98,14 @@
|
|
|
98
98
|
[self performSelector:@selector(routeGraphWithCallback:) withObject:callback];
|
|
99
99
|
}
|
|
100
100
|
|
|
101
|
-
- (void)findSceneIdByModuleName:(nonnull NSString *)moduleName callback:(nonnull RCTResponseSenderBlock)callback {
|
|
101
|
+
- (void)findSceneIdByModuleName:(nonnull NSString *)moduleName callback:(nonnull RCTResponseSenderBlock)callback {
|
|
102
102
|
[self performSelector:@selector(findSceneIdWithParams:) withObject:@{
|
|
103
103
|
@"callback": callback,
|
|
104
104
|
@"moduleName": moduleName,
|
|
105
105
|
}];
|
|
106
106
|
}
|
|
107
107
|
|
|
108
|
-
- (void)isStackRoot:(nonnull NSString *)sceneId callback:(nonnull RCTResponseSenderBlock)callback {
|
|
108
|
+
- (void)isStackRoot:(nonnull NSString *)sceneId callback:(nonnull RCTResponseSenderBlock)callback {
|
|
109
109
|
UIViewController *vc = [self.bridgeManager viewControllerBySceneId:sceneId];
|
|
110
110
|
UINavigationController *nav = vc.navigationController;
|
|
111
111
|
if (!nav) {
|
|
@@ -125,10 +125,15 @@
|
|
|
125
125
|
return;
|
|
126
126
|
}
|
|
127
127
|
|
|
128
|
+
if (children.count == 1 && [root isKindOfClass:[UITabBarController class]]) {
|
|
129
|
+
callback(@[NSNull.null, @YES]);
|
|
130
|
+
return;
|
|
131
|
+
}
|
|
132
|
+
|
|
128
133
|
callback(@[NSNull.null, @NO]);
|
|
129
134
|
}
|
|
130
135
|
|
|
131
|
-
- (void)dispatch:(nonnull NSString *)sceneId action:(nonnull NSString *)action params:(nonnull NSDictionary *)params callback:(nonnull RCTResponseSenderBlock)callback {
|
|
136
|
+
- (void)dispatch:(nonnull NSString *)sceneId action:(nonnull NSString *)action params:(nonnull NSDictionary *)params callback:(nonnull RCTResponseSenderBlock)callback {
|
|
132
137
|
UIViewController *vc = [self.bridgeManager viewControllerBySceneId:sceneId];
|
|
133
138
|
if (!vc) {
|
|
134
139
|
callback(@[NSNull.null, @NO]);
|
|
@@ -139,23 +144,23 @@
|
|
|
139
144
|
[self.bridgeManager handleNavigationWithViewController:vc action:action extras:params callback:(RCTResponseSenderBlock)callback];
|
|
140
145
|
}
|
|
141
146
|
|
|
142
|
-
- (void)setRoot:(nonnull NSDictionary *)layout sticky:(BOOL)sticky callback:(nonnull RCTResponseSenderBlock)callback {
|
|
147
|
+
- (void)setRoot:(nonnull NSDictionary *)layout sticky:(BOOL)sticky callback:(nonnull RCTResponseSenderBlock)callback {
|
|
143
148
|
self.bridgeManager.viewHierarchyReady = NO;
|
|
144
149
|
UIViewController *vc = [self.bridgeManager viewControllerWithLayout:layout];
|
|
145
150
|
if (!vc) {
|
|
146
151
|
@throw [[NSException alloc] initWithName:@"IllegalArgumentsException" reason:@"无法创建 ViewController" userInfo:@{ @"layout": layout }];
|
|
147
152
|
}
|
|
148
|
-
|
|
153
|
+
|
|
149
154
|
if (self.bridgeManager.didSetRoot) {
|
|
150
155
|
self.bridgeManager.didSetRoot(@[NSNull.null, @NO]);
|
|
151
156
|
}
|
|
152
157
|
self.bridgeManager.didSetRoot = callback;
|
|
153
158
|
self.bridgeManager.hasRootLayout = YES;
|
|
154
|
-
|
|
159
|
+
|
|
155
160
|
[self.bridgeManager setRootViewController:vc];
|
|
156
161
|
}
|
|
157
162
|
|
|
158
|
-
- (void)setResult:(nonnull NSString *)sceneId resultCode:(double)resultCode data:(nonnull NSDictionary *)data {
|
|
163
|
+
- (void)setResult:(nonnull NSString *)sceneId resultCode:(double)resultCode data:(nonnull NSDictionary *)data {
|
|
159
164
|
UIViewController *vc = [self.bridgeManager viewControllerBySceneId:sceneId];
|
|
160
165
|
[vc setResultCode:resultCode resultData:data];
|
|
161
166
|
}
|
|
@@ -168,14 +173,14 @@
|
|
|
168
173
|
|
|
169
174
|
NSString *moduleName = params[@"moduleName"];
|
|
170
175
|
RCTResponseSenderBlock callback = params[@"callback"];
|
|
171
|
-
|
|
176
|
+
|
|
172
177
|
NSString *sceneId = [self findSceneIdByModuleName:moduleName];
|
|
173
178
|
if (sceneId == nil) {
|
|
174
179
|
RCTLogInfo(@"[Navigation] Can't find sceneId by : %@", moduleName);
|
|
175
180
|
callback(@[NSNull.null, NSNull.null]);
|
|
176
181
|
return;
|
|
177
182
|
}
|
|
178
|
-
|
|
183
|
+
|
|
179
184
|
RCTLogInfo(@"[Navigation] The sceneId found by %@ : %@", moduleName, sceneId);
|
|
180
185
|
callback(@[[NSNull null], sceneId]);
|
|
181
186
|
}
|
|
@@ -189,9 +194,9 @@
|
|
|
189
194
|
return sceneId;
|
|
190
195
|
}
|
|
191
196
|
}
|
|
192
|
-
|
|
197
|
+
|
|
193
198
|
RCTLogInfo(@"[Navigation] KeyWindow NOT found.");
|
|
194
|
-
|
|
199
|
+
|
|
195
200
|
return nil;
|
|
196
201
|
}
|
|
197
202
|
|
|
@@ -232,7 +237,7 @@
|
|
|
232
237
|
}
|
|
233
238
|
|
|
234
239
|
HBDViewController *current = [self.bridgeManager primaryViewController];
|
|
235
|
-
|
|
240
|
+
|
|
236
241
|
if (current) {
|
|
237
242
|
callback(@[[NSNull null], @{
|
|
238
243
|
@"moduleName": RCTNullIfNil(current.moduleName),
|
package/ios/View/HBDRootView.h
CHANGED
package/ios/View/HBDRootView.mm
CHANGED
|
@@ -44,27 +44,6 @@ RCT_NOT_IMPLEMENTED(-(nullable instancetype)initWithCoder : (NSCoder *)coder)
|
|
|
44
44
|
[_surface stop];
|
|
45
45
|
}
|
|
46
46
|
|
|
47
|
-
- (UIView *)hitTest:(CGPoint)point withEvent:(UIEvent *)event {
|
|
48
|
-
UIView *hitView = [super hitTest:point withEvent:event];
|
|
49
|
-
if (self.passThroughTouches && [self shouldPassTouches:hitView]) {
|
|
50
|
-
return nil;
|
|
51
|
-
}
|
|
52
|
-
return hitView;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
- (BOOL)shouldPassTouches:(UIView *)hitView {
|
|
56
|
-
if (!hitView) {
|
|
57
|
-
return true;
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
// RCTRootComponentView
|
|
61
|
-
if (hitView == _surfaceView || hitView == [_surfaceView.subviews firstObject]) {
|
|
62
|
-
return true;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
return false;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
47
|
- (NSDictionary *)appProperties {
|
|
69
48
|
return _surface.properties;
|
|
70
49
|
}
|
|
@@ -4,53 +4,31 @@
|
|
|
4
4
|
|
|
5
5
|
- (UIImage *)withIconColor:(UIColor *)iconColor badgeColor:(UIColor *)badgeColor {
|
|
6
6
|
CGSize imageSize = self.size;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
UIImage *iconTintedImage = [self imageWithRenderingMode:UIImageRenderingModeAlwaysTemplate];
|
|
11
|
-
[iconColor set];
|
|
12
|
-
[iconTintedImage drawAtPoint:CGPointZero];
|
|
13
|
-
}];
|
|
14
|
-
return [resultImage imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal];
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
static CGFloat const HBDTabBarBadgeHorizontalPadding = 8.0;
|
|
18
|
-
static CGFloat const HBDTabBarBadgeVerticalPadding = 2.0;
|
|
19
|
-
static CGFloat const HBDTabBarBadgeOffsetX = 0.0;
|
|
20
|
-
static CGFloat const HBDTabBarBadgeOffsetY = 0.0;
|
|
21
|
-
CGSize canvasSize = CGSizeMake(
|
|
22
|
-
imageSize.width + HBDTabBarBadgeHorizontalPadding * 2,
|
|
23
|
-
imageSize.height + HBDTabBarBadgeVerticalPadding * 2
|
|
24
|
-
);
|
|
25
|
-
|
|
26
|
-
UIGraphicsImageRenderer *render = [[UIGraphicsImageRenderer alloc] initWithSize:canvasSize];
|
|
27
|
-
|
|
7
|
+
|
|
8
|
+
UIGraphicsImageRenderer *render = [[UIGraphicsImageRenderer alloc] initWithSize:imageSize];
|
|
9
|
+
|
|
28
10
|
UIImage *resultImage = [render imageWithActions:^(UIGraphicsImageRendererContext * _Nonnull rendererContext) {
|
|
29
11
|
// 创建 tint 后的图标图片
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
(canvasSize.height - imageSize.height) / 2.0
|
|
34
|
-
);
|
|
35
|
-
CGRect iconFrame = CGRectMake(iconOrigin.x, iconOrigin.y, imageSize.width, imageSize.height);
|
|
36
|
-
|
|
12
|
+
if (iconColor) {
|
|
13
|
+
UIImage *iconTintedImage = [self imageWithRenderingMode:UIImageRenderingModeAlwaysTemplate];
|
|
14
|
+
|
|
37
15
|
// 设置图标颜色并绘制
|
|
38
16
|
[iconColor set];
|
|
39
|
-
[iconTintedImage drawAtPoint:
|
|
40
|
-
|
|
17
|
+
[iconTintedImage drawAtPoint:CGPointZero];
|
|
18
|
+
} else {
|
|
19
|
+
[self drawAtPoint:CGPointZero];
|
|
20
|
+
}
|
|
21
|
+
|
|
41
22
|
// 创建徽章
|
|
42
23
|
CGSize badgeSize = CGSizeMake(8, 8);
|
|
43
|
-
CGPoint badgeOrigin = CGPointMake(
|
|
44
|
-
CGRectGetMaxX(iconFrame) + HBDTabBarBadgeOffsetX,
|
|
45
|
-
HBDTabBarBadgeOffsetY
|
|
46
|
-
);
|
|
24
|
+
CGPoint badgeOrigin = CGPointMake(imageSize.width - badgeSize.width, 0);
|
|
47
25
|
CGRect badgeRect = CGRectMake(badgeOrigin.x, badgeOrigin.y, badgeSize.width, badgeSize.height);
|
|
48
|
-
|
|
26
|
+
|
|
49
27
|
UIBezierPath *badgePath = [UIBezierPath bezierPathWithOvalInRect:badgeRect];
|
|
50
28
|
[badgeColor setFill];
|
|
51
29
|
[badgePath fill];
|
|
52
30
|
}];
|
|
53
|
-
|
|
31
|
+
|
|
54
32
|
return [resultImage imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal];
|
|
55
33
|
}
|
|
56
34
|
|
|
@@ -82,16 +82,8 @@
|
|
|
82
82
|
self.menuController.view.frame = CGRectMake(0, 0, [self menuWidth], size.height);
|
|
83
83
|
}
|
|
84
84
|
} completion:^(id <UIViewControllerTransitionCoordinatorContext> _Nonnull context) {
|
|
85
|
-
|
|
86
|
-
}];
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
- (void)setContentViewController:(UIViewController *)contentViewController {
|
|
90
|
-
_contentController = contentViewController;
|
|
91
|
-
}
|
|
92
85
|
|
|
93
|
-
|
|
94
|
-
_menuController = menuViewController;
|
|
86
|
+
}];
|
|
95
87
|
}
|
|
96
88
|
|
|
97
89
|
- (void)openMenu {
|
|
@@ -105,7 +97,7 @@
|
|
|
105
97
|
[self dismissMenuView];
|
|
106
98
|
}
|
|
107
99
|
}
|
|
108
|
-
|
|
100
|
+
|
|
109
101
|
- (void)toggleMenu {
|
|
110
102
|
if (self.isMenuOpened) {
|
|
111
103
|
[self closeMenu];
|
|
@@ -161,7 +153,7 @@
|
|
|
161
153
|
[self addChildViewController:menu];
|
|
162
154
|
[menu didMoveToParentViewController:self];
|
|
163
155
|
}
|
|
164
|
-
|
|
156
|
+
|
|
165
157
|
UIView *menuHolderView = [[UIView alloc] initWithFrame:self.view.bounds];
|
|
166
158
|
self.menuHolderView = menuHolderView;
|
|
167
159
|
UIView *dimmingView = [[UIView alloc] initWithFrame:self.view.bounds];
|