Yogev Ben David 6 years ago
parent
commit
feab91de5c
No account linked to committer's email address
1 changed files with 9 additions and 1 deletions
  1. 9
    1
      lib/ios/RNNReactRootView.m

+ 9
- 1
lib/ios/RNNReactRootView.m View File

1
 #import "RNNReactRootView.h"
1
 #import "RNNReactRootView.h"
2
 #import "RCTHelpers.h"
2
 #import "RCTHelpers.h"
3
+#import <React/RCTUIManager.h>
3
 
4
 
4
-@implementation RNNReactRootView
5
+@implementation RNNReactRootView {
6
+	RCTBridge* _bridge;
7
+};
5
 
8
 
6
 - (instancetype)initWithBridge:(RCTBridge *)bridge moduleName:(NSString *)moduleName initialProperties:(NSDictionary *)initialProperties {
9
 - (instancetype)initWithBridge:(RCTBridge *)bridge moduleName:(NSString *)moduleName initialProperties:(NSDictionary *)initialProperties {
7
 	self = [super initWithBridge:bridge moduleName:moduleName initialProperties:initialProperties];
10
 	self = [super initWithBridge:bridge moduleName:moduleName initialProperties:initialProperties];
39
 	}
42
 	}
40
 }
43
 }
41
 
44
 
45
+- (void)layoutSubviews {
46
+	[super layoutSubviews];
47
+	[_bridge.uiManager setSize:self.bounds.size forView:self];
48
+}
49
+
42
 @end
50
 @end