mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Fix minimize/restore crash (#46023)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/46023 Minimizing and restoring a Mac Catalyst app causes an `interfaceOrientationDidChange` which causes a downstream crash on `application.delegate.window`. There doesn't seem to be a clean way to get if an app is fullscreen in Mac Catalyst, so just no-oping for now. Changelog: [Internal] Reviewed By: shwanton Differential Revision: D61253706 fbshipit-source-id: 73d260366adcc74e88f43f256cc5aff8a6e3ef71
This commit is contained in:
committed by
Facebook GitHub Bot
parent
94407f56d1
commit
9bc32a0101
@@ -214,7 +214,7 @@ static NSDictionary *RCTExportedDimensions(CGFloat fontScale)
|
||||
|
||||
- (void)_interfaceOrientationDidChange
|
||||
{
|
||||
#if TARGET_OS_IOS
|
||||
#if TARGET_OS_IOS && !TARGET_OS_MACCATALYST
|
||||
UIApplication *application = RCTSharedApplication();
|
||||
UIInterfaceOrientation nextOrientation = RCTKeyWindow().windowScene.interfaceOrientation;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user