mirror of
https://gitcode.com/GitHub_Trending/ji/jitsi-meet.git
synced 2025-12-30 11:22:31 +00:00
I'm updating to RN 0.63 instead of the latest (0.66 at the time of this writing) so we can update the navigation related libraries to their latest versions, and then proceed with the larger leap towards the latest RN.
34 lines
1.1 KiB
Diff
34 lines
1.1 KiB
Diff
diff --git a/node_modules/react-native/React/CoreModules/RCTTiming.mm b/node_modules/react-native/React/CoreModules/RCTTiming.mm
|
|
index 7517771..5af8bdc 100644
|
|
--- a/node_modules/react-native/React/CoreModules/RCTTiming.mm
|
|
+++ b/node_modules/react-native/React/CoreModules/RCTTiming.mm
|
|
@@ -148,6 +148,11 @@ - (void)setup
|
|
name:name
|
|
object:nil];
|
|
}
|
|
+
|
|
+ [[NSNotificationCenter defaultCenter] addObserver:self
|
|
+ selector:@selector(proximityChanged)
|
|
+ name:UIDeviceProximityStateDidChangeNotification
|
|
+ object:nil];
|
|
}
|
|
|
|
- (void)dealloc
|
|
@@ -184,6 +189,16 @@ - (void)appDidMoveToForeground
|
|
[self startTimers];
|
|
}
|
|
|
|
+- (void)proximityChanged
|
|
+{
|
|
+ BOOL isClose = [UIDevice currentDevice].proximityState;
|
|
+ if (isClose) {
|
|
+ [self appDidMoveToBackground];
|
|
+ } else {
|
|
+ [self appDidMoveToForeground];
|
|
+ }
|
|
+}
|
|
+
|
|
- (void)stopTimers
|
|
{
|
|
if (_inBackground) {
|