|
@@ -11,6 +11,39 @@ index bd48f44..d243ed0 100644
|
11
|
11
|
withDispatchGroup:(dispatch_group_t)dispatchGroup
|
12
|
12
|
lazilyDiscovered:(BOOL)lazilyDiscovered
|
13
|
13
|
{
|
|
14
|
+diff --git a/node_modules/react-native/React/Modules/RCTTiming.m b/node_modules/react-native/React/Modules/RCTTiming.m
|
|
15
|
+index 8a09022..265d7b6 100644
|
|
16
|
+--- a/node_modules/react-native/React/Modules/RCTTiming.m
|
|
17
|
++++ b/node_modules/react-native/React/Modules/RCTTiming.m
|
|
18
|
+@@ -130,6 +130,11 @@ - (void)setBridge:(RCTBridge *)bridge
|
|
19
|
+ object:nil];
|
|
20
|
+ }
|
|
21
|
+
|
|
22
|
++ [[NSNotificationCenter defaultCenter] addObserver:self
|
|
23
|
++ selector:@selector(proximityChanged)
|
|
24
|
++ name:UIDeviceProximityStateDidChangeNotification
|
|
25
|
++ object:nil];
|
|
26
|
++
|
|
27
|
+ _bridge = bridge;
|
|
28
|
+ }
|
|
29
|
+
|
|
30
|
+@@ -276,6 +281,16 @@ - (void)didUpdateFrame:(RCTFrameUpdate *)update
|
|
31
|
+ }
|
|
32
|
+ }
|
|
33
|
+
|
|
34
|
++-(void)proximityChanged
|
|
35
|
++{
|
|
36
|
++ BOOL near = [UIDevice currentDevice].proximityState;
|
|
37
|
++ if (near) {
|
|
38
|
++ [self appDidMoveToBackground];
|
|
39
|
++ } else {
|
|
40
|
++ [self appDidMoveToForeground];
|
|
41
|
++ }
|
|
42
|
++}
|
|
43
|
++
|
|
44
|
+ - (void)scheduleSleepTimer:(NSDate *)sleepTarget
|
|
45
|
+ {
|
|
46
|
+ @synchronized (self) {
|
14
|
47
|
diff --git a/node_modules/react-native/ReactCommon/turbomodule/core/platform/ios/RCTTurboModuleManager.mm b/node_modules/react-native/ReactCommon/turbomodule/core/platform/ios/RCTTurboModuleManager.mm
|
15
|
48
|
index 3cb73b5..e4a14b4 100644
|
16
|
49
|
--- a/node_modules/react-native/ReactCommon/turbomodule/core/platform/ios/RCTTurboModuleManager.mm
|