Proper check for RCTRootShadowView in RCTUIManager

Summary: Because setting `intrinsicContentSize` for `RCTSurfaceRootView` doesn't have much sense.

Reviewed By: mmmulani

Differential Revision: D6701107

fbshipit-source-id: 259cdd27339bba3e8c9f98b6ca34affeb87f298c
This commit is contained in:
Valentin Shergin 2018-01-11 18:34:32 -08:00 committed by Facebook Github Bot
parent a580a44b0d
commit 7d9e902d72

View File

@ -548,7 +548,10 @@ static NSDictionary *deviceOrientationEventBody(UIDeviceOrientation orientation)
});
}
if (RCTIsReactRootView(reactTag)) {
if (
RCTIsReactRootView(reactTag) &&
[shadowView isKindOfClass:[RCTRootShadowView class]]
) {
CGSize contentSize = shadowView.frame.size;
RCTExecuteOnMainQueue(^{