123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051 |
- //
- // RNNSideMenuChildVC.m
- // ReactNativeNavigation
- //
- // Created by Ran Greenberg on 09/02/2017.
- // Copyright © 2017 Wix. All rights reserved.
- //
-
- #import "RNNSideMenuChildVC.h"
-
- @interface RNNSideMenuChildVC ()
-
- @property (readwrite) RNNSideMenuChildType type;
- @property (readwrite) UIViewController<RNNRootViewProtocol> *child;
-
- @end
-
- @implementation RNNSideMenuChildVC
-
- -(instancetype) initWithChild:(UIViewController<RNNRootViewProtocol>*)child type:(RNNSideMenuChildType)type {
- self = [super init];
-
- self.child = child;
- [self addChildViewController:self.child];
- [self.child.view setFrame:self.view.bounds];
- [self.view addSubview:self.child.view];
- [self.view bringSubviewToFront:self.child.view];
-
- self.type = type;
-
- return self;
- }
-
- - (void)mergeOptions:(RNNOptions *)options {
- [self.child mergeOptions:options];
- }
-
- - (void)waitForReactViewRender:(BOOL)wait perform:(RNNReactViewReadyCompletionBlock)readyBlock {
- [self.child waitForReactViewRender:wait perform:readyBlock];
- }
-
- - (UIStatusBarStyle)preferredStatusBarStyle {
- return self.child.preferredStatusBarStyle;
- }
-
- - (NSString *)componentId {
- return _child.componentId;
- }
-
- @end
|