[ReactNative] Unfork RKRootView

This commit is contained in:
Tadeu Zagallo
2015-04-02 07:33:21 -07:00
parent b1e502a083
commit f370f9cbc4
15 changed files with 448 additions and 298 deletions

View File

@@ -30,8 +30,7 @@
@property (nonatomic, readwrite, weak) id<UIScrollViewDelegate> nativeMainScrollDelegate;
/**
* Register a root view with the RCTUIManager. Theoretically, a single manager
* can support multiple root views, however this feature is not currently exposed.
* Register a root view with the RCTUIManager.
*/
- (void)registerRootView:(UIView *)rootView;

View File

@@ -192,9 +192,10 @@ static UIViewAnimationCurve UIViewAnimationCurveFromRCTAnimationType(RCTAnimatio
NSMutableDictionary *_defaultShadowViews; // RCT thread only
NSMutableDictionary *_defaultViews; // Main thread only
NSDictionary *_viewManagers;
NSUInteger _rootTag;
}
@synthesize bridge =_bridge;
@synthesize bridge = _bridge;
/**
* This function derives the view name automatically
@@ -239,6 +240,7 @@ static NSString *RCTViewNameForModuleName(NSString *moduleName)
// Internal resources
_pendingUIBlocks = [[NSMutableArray alloc] init];
_rootViewTags = [[NSMutableSet alloc] init];
_rootTag = 1;
}
return self;
}
@@ -259,6 +261,7 @@ static NSString *RCTViewNameForModuleName(NSString *moduleName)
_bridge = bridge;
_shadowQueue = _bridge.shadowQueue;
_shadowViewRegistry = [[RCTSparseArray alloc] init];
// Get view managers from bridge
NSMutableDictionary *viewManagers = [[NSMutableDictionary alloc] init];