Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

react-native+0.61.5-jitsi.2.patch 3.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. diff --git a/node_modules/react-native/Libraries/WebSocket/RCTWebSocketModule.m b/node_modules/react-native/Libraries/WebSocket/RCTWebSocketModule.m
  2. index d9387c4..a487da0 100644
  3. --- a/node_modules/react-native/Libraries/WebSocket/RCTWebSocketModule.m
  4. +++ b/node_modules/react-native/Libraries/WebSocket/RCTWebSocketModule.m
  5. @@ -165,10 +165,10 @@ - (void)webSocket:(RCTSRWebSocket *)webSocket didFailWithError:(NSError *)error
  6. NSNumber *socketID = [webSocket reactTag];
  7. _contentHandlers[socketID] = nil;
  8. _sockets[socketID] = nil;
  9. - [self sendEventWithName:@"websocketFailed" body:@{
  10. - @"message": error.localizedDescription,
  11. - @"id": socketID
  12. - }];
  13. + NSDictionary *body =
  14. + @{@"message" : error.localizedDescription ?: @"Undefined, error is nil",
  15. + @"id" : socketID ?: @(-1)};
  16. + [self sendEventWithName:@"websocketFailed" body:body];
  17. }
  18. - (void)webSocket:(RCTSRWebSocket *)webSocket
  19. diff --git a/node_modules/react-native/React/CxxBridge/RCTCxxBridge.mm b/node_modules/react-native/React/CxxBridge/RCTCxxBridge.mm
  20. index bd48f44..d243ed0 100644
  21. --- a/node_modules/react-native/React/CxxBridge/RCTCxxBridge.mm
  22. +++ b/node_modules/react-native/React/CxxBridge/RCTCxxBridge.mm
  23. @@ -767,7 +767,7 @@ - (void)registerExtraLazyModules
  24. #endif
  25. }
  26. -- (NSArray<RCTModuleData *> *)_initializeModules:(NSArray<id<RCTBridgeModule>> *)modules
  27. +- (NSArray<RCTModuleData *> *)_initializeModules:(NSArray<Class> *)modules
  28. withDispatchGroup:(dispatch_group_t)dispatchGroup
  29. lazilyDiscovered:(BOOL)lazilyDiscovered
  30. {
  31. diff --git a/node_modules/react-native/React/Modules/RCTTiming.m b/node_modules/react-native/React/Modules/RCTTiming.m
  32. index 8a09022..265d7b6 100644
  33. --- a/node_modules/react-native/React/Modules/RCTTiming.m
  34. +++ b/node_modules/react-native/React/Modules/RCTTiming.m
  35. @@ -130,6 +130,11 @@ - (void)setBridge:(RCTBridge *)bridge
  36. object:nil];
  37. }
  38. + [[NSNotificationCenter defaultCenter] addObserver:self
  39. + selector:@selector(proximityChanged)
  40. + name:UIDeviceProximityStateDidChangeNotification
  41. + object:nil];
  42. +
  43. _bridge = bridge;
  44. }
  45. @@ -276,6 +281,16 @@ - (void)didUpdateFrame:(RCTFrameUpdate *)update
  46. }
  47. }
  48. +-(void)proximityChanged
  49. +{
  50. + BOOL near = [UIDevice currentDevice].proximityState;
  51. + if (near) {
  52. + [self appDidMoveToBackground];
  53. + } else {
  54. + [self appDidMoveToForeground];
  55. + }
  56. +}
  57. +
  58. - (void)scheduleSleepTimer:(NSDate *)sleepTarget
  59. {
  60. @synchronized (self) {
  61. 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
  62. index 3cb73b5..e4a14b4 100644
  63. --- a/node_modules/react-native/ReactCommon/turbomodule/core/platform/ios/RCTTurboModuleManager.mm
  64. +++ b/node_modules/react-native/ReactCommon/turbomodule/core/platform/ios/RCTTurboModuleManager.mm
  65. @@ -297,7 +297,7 @@ - (void)notifyAboutTurboModuleSetup:(const char *)name
  66. @"%@ has no setter or ivar for its bridge, which is not "
  67. "permitted. You must either @synthesize the bridge property, "
  68. "or provide your own setter method.",
  69. - RCTBridgeModuleNameForClass(module));
  70. + RCTBridgeModuleNameForClass(Class(module)));
  71. }
  72. }