File tree Expand file tree Collapse file tree 3 files changed +146
-170
lines changed
react-native/React/CoreModules
rn-tester/RNTesterPods.xcodeproj Expand file tree Collapse file tree 3 files changed +146
-170
lines changed Original file line number Diff line number Diff line change @@ -60,6 +60,7 @@ - (void)initialize
60
60
selector: @selector (interfaceOrientationDidChange )
61
61
name: UIApplicationDidChangeStatusBarOrientationNotification
62
62
object: nil ];
63
+ #endif
63
64
64
65
_currentInterfaceDimensions = [self _exportedDimensions ];
65
66
@@ -77,10 +78,13 @@ - (void)initialize
77
78
selector: @selector (interfaceFrameDidChange )
78
79
name: RCTWindowFrameDidChangeNotification
79
80
object: nil ];
81
+ #if !TARGET_OS_VISION
80
82
[[NSNotificationCenter defaultCenter ] addObserver: self
81
83
selector: @selector (interfaceFrameDidChange )
82
84
name: UIDeviceOrientationDidChangeNotification
83
85
object: nil ];
86
+ #endif
87
+
84
88
85
89
// TODO T175901725 - Registering the RCTDeviceInfo module to the notification is a short-term fix to unblock 0.73
86
90
// The actual behavior should be that the module is properly registered in the TurboModule/Bridge infrastructure
@@ -120,7 +124,9 @@ - (void)_cleanupObservers
120
124
121
125
[[NSNotificationCenter defaultCenter ] removeObserver: self name: RCTBridgeWillInvalidateModulesNotification object: nil ];
122
126
127
+ #if !TARGET_OS_VISION
123
128
[[NSNotificationCenter defaultCenter ] removeObserver: self name: UIDeviceOrientationDidChangeNotification object: nil ];
129
+ #endif
124
130
}
125
131
126
132
static BOOL RCTIsIPhoneNotched ()
You can’t perform that action at this time.
0 commit comments