mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-24 04:16:00 +08:00
Demolishing of background color propagation infra
Summary: As it was mentioned in previous diffs, we are removing this because it overcomplicates rendering layer and provides (almost) no benefits (and cannot be implemented 100% accurate way). Reviewed By: mmmulani Differential Revision: D6582560 fbshipit-source-id: 0778db96a45dd8e2520268d5d00792677cb01a20
This commit is contained in:
committed by
Facebook Github Bot
parent
d89901fa60
commit
2679f3efb6
@@ -18,9 +18,6 @@
|
||||
#import "UIView+React.h"
|
||||
|
||||
@implementation RCTRootContentView
|
||||
{
|
||||
UIColor *_backgroundColor;
|
||||
}
|
||||
|
||||
- (instancetype)initWithFrame:(CGRect)frame
|
||||
bridge:(RCTBridge *)bridge
|
||||
@@ -34,7 +31,6 @@
|
||||
_touchHandler = [[RCTTouchHandler alloc] initWithBridge:_bridge];
|
||||
[_touchHandler attachToView:self];
|
||||
[_bridge.uiManager registerRootView:self];
|
||||
self.layer.backgroundColor = NULL;
|
||||
}
|
||||
return self;
|
||||
}
|
||||
@@ -89,19 +85,6 @@ RCT_NOT_IMPLEMENTED(-(instancetype)initWithCoder:(nonnull NSCoder *)aDecoder)
|
||||
[_bridge.uiManager setAvailableSize:self.availableSize forRootView:self];
|
||||
}
|
||||
|
||||
- (void)setBackgroundColor:(UIColor *)backgroundColor
|
||||
{
|
||||
_backgroundColor = backgroundColor;
|
||||
if (self.reactTag && _bridge.isValid) {
|
||||
[_bridge.uiManager setBackgroundColor:backgroundColor forView:self];
|
||||
}
|
||||
}
|
||||
|
||||
- (UIColor *)backgroundColor
|
||||
{
|
||||
return _backgroundColor;
|
||||
}
|
||||
|
||||
- (UIView *)hitTest:(CGPoint)point withEvent:(UIEvent *)event
|
||||
{
|
||||
// The root content view itself should never receive touches
|
||||
|
||||
Reference in New Issue
Block a user