Quellcode durchsuchen

Coding style consistency

Includes automatic recommended Xcode project file fixes.
master
Lyubomir Marinov vor 8 Jahren
Ursprung
Commit
401a783d6a

+ 39
- 14
ios/jitsi-meet-react.xcodeproj/project.pbxproj Datei anzeigen

@@ -5,6 +5,7 @@
5 5
 	};
6 6
 	objectVersion = 46;
7 7
 	objects = {
8
+
8 9
 /* Begin PBXBuildFile section */
9 10
 		002AF788986B412780935607 /* FontAwesome.ttf in Resources */ = {isa = PBXBuildFile; fileRef = B96AF9B6FBC0453798399985 /* FontAwesome.ttf */; };
10 11
 		00C302E51ABCBA2D00DB3ED1 /* libRCTActionSheet.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */; };
@@ -24,6 +25,7 @@
24 25
 		2602576C1D0A7703001E3363 /* jitsi.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 2602576B1D0A7703001E3363 /* jitsi.ttf */; };
25 26
 		3847F11906B4479A9162628F /* libRNVectorIcons.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 821D8ABD506944B4BDBB069B /* libRNVectorIcons.a */; };
26 27
 		5E9157361DD0AC6A00FF2AA8 /* libRCTAnimation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */; };
28
+		7FAD39BE09A84D6AB0ABACA8 /* libRNBackgroundTimer.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 27A0018BBB2C4FD5A4F9CE71 /* libRNBackgroundTimer.a */; };
27 29
 		832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 832341B51AAA6A8300B99B32 /* libRCTText.a */; };
28 30
 		901FE90FA5744B5B94DCDC41 /* libKCKeepAwake.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 0EA8C046B2BF46279796F07D /* libKCKeepAwake.a */; };
29 31
 		B30EF2311DC0ED7C00690F45 /* WebRTC.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B30EF2301DC0ED7C00690F45 /* WebRTC.framework */; };
@@ -40,7 +42,6 @@
40 42
 		BF9643921C34FBF100B0BBDF /* libsqlite3.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = BF9643911C34FBF100B0BBDF /* libsqlite3.tbd */; };
41 43
 		BF9643941C34FBF900B0BBDF /* libstdc++.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = BF9643931C34FBF900B0BBDF /* libstdc++.tbd */; };
42 44
 		BFC745141CB829B300673F38 /* libRCTWebRTC.a in Frameworks */ = {isa = PBXBuildFile; fileRef = BFC745131CB829A700673F38 /* libRCTWebRTC.a */; };
43
-		7FAD39BE09A84D6AB0ABACA8 /* libRNBackgroundTimer.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 27A0018BBB2C4FD5A4F9CE71 /* libRNBackgroundTimer.a */; };
44 45
 /* End PBXBuildFile section */
45 46
 
46 47
 /* Begin PBXContainerItemProxy section */
@@ -184,6 +185,13 @@
184 185
 			remoteGlobalIDString = 58B5119B1A9E6C1200147676;
185 186
 			remoteInfo = RCTText;
186 187
 		};
188
+		B332D04E1E54E3170086EA16 /* PBXContainerItemProxy */ = {
189
+			isa = PBXContainerItemProxy;
190
+			containerPortal = 0965153BB98645B4A8B6AA10 /* RNBackgroundTimer.xcodeproj */;
191
+			proxyType = 2;
192
+			remoteGlobalIDString = 134814201AA4EA6300B7C361;
193
+			remoteInfo = RNBackgroundTimer;
194
+		};
187 195
 		B3BA19D41DC6B37B00BCD481 /* PBXContainerItemProxy */ = {
188 196
 			isa = PBXContainerItemProxy;
189 197
 			containerPortal = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */;
@@ -263,6 +271,7 @@
263 271
 		00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTImage.xcodeproj; path = "../node_modules/react-native/Libraries/Image/RCTImage.xcodeproj"; sourceTree = "<group>"; };
264 272
 		00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTNetwork.xcodeproj; path = "../node_modules/react-native/Libraries/Network/RCTNetwork.xcodeproj"; sourceTree = "<group>"; };
265 273
 		00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTVibration.xcodeproj; path = "../node_modules/react-native/Libraries/Vibration/RCTVibration.xcodeproj"; sourceTree = "<group>"; };
274
+		0965153BB98645B4A8B6AA10 /* RNBackgroundTimer.xcodeproj */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = "wrapper.pb-project"; name = RNBackgroundTimer.xcodeproj; path = "../node_modules/react-native-background-timer/ios/RNBackgroundTimer.xcodeproj"; sourceTree = "<group>"; };
266 275
 		0B42DFAD1E2FD90700111B12 /* AudioMode.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AudioMode.m; path = app/AudioMode.m; sourceTree = "<group>"; };
267 276
 		0EA8C046B2BF46279796F07D /* libKCKeepAwake.a */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = archive.ar; path = libKCKeepAwake.a; sourceTree = "<group>"; };
268 277
 		139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTSettings.xcodeproj; path = "../node_modules/react-native/Libraries/Settings/RCTSettings.xcodeproj"; sourceTree = "<group>"; };
@@ -277,6 +286,7 @@
277 286
 		146833FF1AC3E56700842450 /* React.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = React.xcodeproj; path = "../node_modules/react-native/React/React.xcodeproj"; sourceTree = "<group>"; };
278 287
 		22418656B14845609F953A42 /* RNVectorIcons.xcodeproj */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = "wrapper.pb-project"; name = RNVectorIcons.xcodeproj; path = "../node_modules/react-native-vector-icons/RNVectorIcons.xcodeproj"; sourceTree = "<group>"; };
279 288
 		2602576B1D0A7703001E3363 /* jitsi.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; name = jitsi.ttf; path = ../android/app/src/main/assets/fonts/jitsi.ttf; sourceTree = "<group>"; };
289
+		27A0018BBB2C4FD5A4F9CE71 /* libRNBackgroundTimer.a */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = archive.ar; path = libRNBackgroundTimer.a; sourceTree = "<group>"; };
280 290
 		5B09C20C78C74A548AAAC1FA /* KCKeepAwake.xcodeproj */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = "wrapper.pb-project"; name = KCKeepAwake.xcodeproj; path = "../node_modules/react-native-keep-awake/ios/KCKeepAwake.xcodeproj"; sourceTree = "<group>"; };
281 291
 		5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTAnimation.xcodeproj; path = "../node_modules/react-native/Libraries/NativeAnimation/RCTAnimation.xcodeproj"; sourceTree = "<group>"; };
282 292
 		78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTLinking.xcodeproj; path = "../node_modules/react-native/Libraries/LinkingIOS/RCTLinking.xcodeproj"; sourceTree = "<group>"; };
@@ -297,8 +307,6 @@
297 307
 		BF9643911C34FBF100B0BBDF /* libsqlite3.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libsqlite3.tbd; path = usr/lib/libsqlite3.tbd; sourceTree = SDKROOT; };
298 308
 		BF9643931C34FBF900B0BBDF /* libstdc++.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = "libstdc++.tbd"; path = "usr/lib/libstdc++.tbd"; sourceTree = SDKROOT; };
299 309
 		BFC7450D1CB829A700673F38 /* RCTWebRTC.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTWebRTC.xcodeproj; path = "../node_modules/react-native-webrtc/ios/RCTWebRTC.xcodeproj"; sourceTree = "<group>"; };
300
-		0965153BB98645B4A8B6AA10 /* RNBackgroundTimer.xcodeproj */ = {isa = PBXFileReference; name = "RNBackgroundTimer.xcodeproj"; path = "../node_modules/react-native-background-timer/ios/RNBackgroundTimer.xcodeproj"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = wrapper.pb-project; explicitFileType = undefined; includeInIndex = 0; };
301
-		27A0018BBB2C4FD5A4F9CE71 /* libRNBackgroundTimer.a */ = {isa = PBXFileReference; name = "libRNBackgroundTimer.a"; path = "libRNBackgroundTimer.a"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = archive.ar; explicitFileType = undefined; includeInIndex = 0; };
302 310
 /* End PBXFileReference section */
303 311
 
304 312
 /* Begin PBXFrameworksBuildPhase section */
@@ -317,7 +325,7 @@
317 325
 				BF9643881C34FBC800B0BBDF /* GLKit.framework in Frameworks */,
318 326
 				B30EF2311DC0ED7C00690F45 /* WebRTC.framework in Frameworks */,
319 327
 				BF96438E1C34FBE100B0BBDF /* VideoToolbox.framework in Frameworks */,
320
-				146834051AC3E58100842450 /* libReact.a in Frameworks */,
328
+				901FE90FA5744B5B94DCDC41 /* libKCKeepAwake.a in Frameworks */,
321 329
 				00C302E51ABCBA2D00DB3ED1 /* libRCTActionSheet.a in Frameworks */,
322 330
 				5E9157361DD0AC6A00FF2AA8 /* libRCTAnimation.a in Frameworks */,
323 331
 				00C302E71ABCBA2D00DB3ED1 /* libRCTGeolocation.a in Frameworks */,
@@ -329,9 +337,9 @@
329 337
 				00C302EA1ABCBA2D00DB3ED1 /* libRCTVibration.a in Frameworks */,
330 338
 				BFC745141CB829B300673F38 /* libRCTWebRTC.a in Frameworks */,
331 339
 				139FDEF61B0652A700C62182 /* libRCTWebSocket.a in Frameworks */,
332
-				3847F11906B4479A9162628F /* libRNVectorIcons.a in Frameworks */,
333
-				901FE90FA5744B5B94DCDC41 /* libKCKeepAwake.a in Frameworks */,
340
+				146834051AC3E58100842450 /* libReact.a in Frameworks */,
334 341
 				7FAD39BE09A84D6AB0ABACA8 /* libRNBackgroundTimer.a in Frameworks */,
342
+				3847F11906B4479A9162628F /* libRNVectorIcons.a in Frameworks */,
335 343
 			);
336 344
 			runOnlyForDeploymentPostprocessing = 0;
337 345
 		};
@@ -491,8 +499,8 @@
491 499
 				BFC7450D1CB829A700673F38 /* RCTWebRTC.xcodeproj */,
492 500
 				139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */,
493 501
 				146833FF1AC3E56700842450 /* React.xcodeproj */,
494
-				22418656B14845609F953A42 /* RNVectorIcons.xcodeproj */,
495 502
 				0965153BB98645B4A8B6AA10 /* RNBackgroundTimer.xcodeproj */,
503
+				22418656B14845609F953A42 /* RNVectorIcons.xcodeproj */,
496 504
 			);
497 505
 			name = Libraries;
498 506
 			sourceTree = "<group>";
@@ -528,6 +536,14 @@
528 536
 			name = Products;
529 537
 			sourceTree = "<group>";
530 538
 		};
539
+		B332D0301E54E3170086EA16 /* Products */ = {
540
+			isa = PBXGroup;
541
+			children = (
542
+				B332D04F1E54E3170086EA16 /* libRNBackgroundTimer.a */,
543
+			);
544
+			name = Products;
545
+			sourceTree = "<group>";
546
+		};
531 547
 		B3BA19B71DC6B02F00BCD481 /* Frameworks */ = {
532 548
 			isa = PBXGroup;
533 549
 			children = (
@@ -580,7 +596,7 @@
580 596
 		83CBB9F71A601CBA00E9B192 /* Project object */ = {
581 597
 			isa = PBXProject;
582 598
 			attributes = {
583
-				LastUpgradeCheck = 820;
599
+				LastUpgradeCheck = 0820;
584 600
 				ORGANIZATIONNAME = Facebook;
585 601
 				TargetAttributes = {
586 602
 					13B07F861A680F5B00A75B9A = {
@@ -657,6 +673,10 @@
657 673
 					ProductGroup = 146834001AC3E56700842450 /* Products */;
658 674
 					ProjectRef = 146833FF1AC3E56700842450 /* React.xcodeproj */;
659 675
 				},
676
+				{
677
+					ProductGroup = B332D0301E54E3170086EA16 /* Products */;
678
+					ProjectRef = 0965153BB98645B4A8B6AA10 /* RNBackgroundTimer.xcodeproj */;
679
+				},
660 680
 				{
661 681
 					ProductGroup = 26D589F81D0B42EE00FC396B /* Products */;
662 682
 					ProjectRef = 22418656B14845609F953A42 /* RNVectorIcons.xcodeproj */;
@@ -810,6 +830,13 @@
810 830
 			remoteRef = 832341B41AAA6A8300B99B32 /* PBXContainerItemProxy */;
811 831
 			sourceTree = BUILT_PRODUCTS_DIR;
812 832
 		};
833
+		B332D04F1E54E3170086EA16 /* libRNBackgroundTimer.a */ = {
834
+			isa = PBXReferenceProxy;
835
+			fileType = archive.ar;
836
+			path = libRNBackgroundTimer.a;
837
+			remoteRef = B332D04E1E54E3170086EA16 /* PBXContainerItemProxy */;
838
+			sourceTree = BUILT_PRODUCTS_DIR;
839
+		};
813 840
 		B3BA19D51DC6B37B00BCD481 /* libRCTImage-tvOS.a */ = {
814 841
 			isa = PBXReferenceProxy;
815 842
 			fileType = archive.ar;
@@ -956,9 +983,9 @@
956 983
 					/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
957 984
 					"$(SRCROOT)/../node_modules/react-native/React/**",
958 985
 					"$(SRCROOT)/../node_modules/react-native/Libraries/LinkingIOS/**",
986
+					"$(SRCROOT)/../node_modules/react-native-background-timer/ios",
959 987
 					"$(SRCROOT)/../node_modules/react-native-keep-awake/ios",
960 988
 					"$(SRCROOT)/../node_modules/react-native-vector-icons/RNVectorIconsManager",
961
-					"$(SRCROOT)/../node_modules/react-native-background-timer/ios",
962 989
 				);
963 990
 				INFOPLIST_FILE = app/Info.plist;
964 991
 				IPHONEOS_DEPLOYMENT_TARGET = 9.0;
@@ -966,7 +993,6 @@
966 993
 				LIBRARY_SEARCH_PATHS = (
967 994
 					"$(inherited)",
968 995
 					"$(SRCROOT)/../node_modules/react-native-webrtc/**",
969
-					"\"$(SRCROOT)/jitsi-meet-react\"",
970 996
 				);
971 997
 				OTHER_LDFLAGS = (
972 998
 					"$(inherited)",
@@ -994,9 +1020,9 @@
994 1020
 					/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
995 1021
 					"$(SRCROOT)/../node_modules/react-native/React/**",
996 1022
 					"$(SRCROOT)/../node_modules/react-native/Libraries/LinkingIOS/**",
1023
+					"$(SRCROOT)/../node_modules/react-native-background-timer/ios",
997 1024
 					"$(SRCROOT)/../node_modules/react-native-keep-awake/ios",
998 1025
 					"$(SRCROOT)/../node_modules/react-native-vector-icons/RNVectorIconsManager",
999
-					"$(SRCROOT)/../node_modules/react-native-background-timer/ios",
1000 1026
 				);
1001 1027
 				INFOPLIST_FILE = app/Info.plist;
1002 1028
 				IPHONEOS_DEPLOYMENT_TARGET = 9.0;
@@ -1004,7 +1030,6 @@
1004 1030
 				LIBRARY_SEARCH_PATHS = (
1005 1031
 					"$(inherited)",
1006 1032
 					"$(SRCROOT)/../node_modules/react-native-webrtc/**",
1007
-					"\"$(SRCROOT)/jitsi-meet-react\"",
1008 1033
 				);
1009 1034
 				OTHER_LDFLAGS = (
1010 1035
 					"$(inherited)",
@@ -1058,9 +1083,9 @@
1058 1083
 					"$(inherited)",
1059 1084
 					/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
1060 1085
 					"$(SRCROOT)/../node_modules/react-native/React/**",
1086
+					"$(SRCROOT)/../node_modules/react-native-background-timer/ios",
1061 1087
 					"$(SRCROOT)/../node_modules/react-native-keep-awake/ios",
1062 1088
 					"$(SRCROOT)/../node_modules/react-native-vector-icons/RNVectorIconsManager",
1063
-					"$(SRCROOT)/../node_modules/react-native-background-timer/ios",
1064 1089
 				);
1065 1090
 				IPHONEOS_DEPLOYMENT_TARGET = 8.0;
1066 1091
 				MTL_ENABLE_DEBUG_INFO = YES;
@@ -1104,9 +1129,9 @@
1104 1129
 					"$(inherited)",
1105 1130
 					/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
1106 1131
 					"$(SRCROOT)/../node_modules/react-native/React/**",
1132
+					"$(SRCROOT)/../node_modules/react-native-background-timer/ios",
1107 1133
 					"$(SRCROOT)/../node_modules/react-native-keep-awake/ios",
1108 1134
 					"$(SRCROOT)/../node_modules/react-native-vector-icons/RNVectorIconsManager",
1109
-					"$(SRCROOT)/../node_modules/react-native-background-timer/ios",
1110 1135
 				);
1111 1136
 				IPHONEOS_DEPLOYMENT_TARGET = 8.0;
1112 1137
 				MTL_ENABLE_DEBUG_INFO = NO;

+ 2
- 2
react/features/base/conference/functions.js Datei anzeigen

@@ -19,8 +19,8 @@ export function _addLocalTracksToConference(conference, localTracks) {
19 19
         // XXX The library lib-jitsi-meet may be draconian, for example, when
20 20
         // adding one and the same video track multiple times.
21 21
         if (conferenceLocalTracks.indexOf(track) === -1) {
22
-            promises.push(conference.addTrack(track)
23
-                .catch(err => {
22
+            promises.push(
23
+                conference.addTrack(track).catch(err => {
24 24
                     _reportError(
25 25
                         'Failed to add local track to conference',
26 26
                         err);

+ 12
- 15
react/features/base/lib-jitsi-meet/native/polyfills-browser.js Datei anzeigen

@@ -1,4 +1,5 @@
1 1
 import BackgroundTimer from 'react-native-background-timer';
2
+import 'url-polyfill'; // Polyfill for URL constructor
2 3
 
3 4
 /**
4 5
  * Gets the first common prototype of two specified Objects (treating the
@@ -86,10 +87,6 @@ function _visitNode(node, callback) {
86 87
 }
87 88
 
88 89
 (global => {
89
-
90
-    // Polyfill for URL constructor
91
-    require('url-polyfill');
92
-
93 90
     const DOMParser = require('xmldom').DOMParser;
94 91
 
95 92
     // addEventListener
@@ -110,8 +107,8 @@ function _visitNode(node, callback) {
110 107
     if (typeof global.document === 'undefined') {
111 108
         const document
112 109
             = new DOMParser().parseFromString(
113
-            /* source */ '<html><head></head><body></body></html>',
114
-            /* mineType */ 'text/xml');
110
+                    '<html><head></head><body></body></html>',
111
+                    'text/xml');
115 112
 
116 113
         // document.addEventListener
117 114
         //
@@ -334,17 +331,17 @@ function _visitNode(node, callback) {
334 331
         //
335 332
         // Required by:
336 333
         // - Strophe
337
-        if (prototype && typeof prototype.responseXML === 'undefined') {
334
+        if (prototype && !prototype.hasOwnProperty('responseXML')) {
338 335
             Object.defineProperty(prototype, 'responseXML', {
339
-                configurable: true,
340
-                enumerable: true,
341 336
                 get() {
342 337
                     const responseText = this.responseText;
343 338
                     let responseXML;
344 339
 
345 340
                     if (responseText) {
346
-                        responseXML = new DOMParser()
347
-                            .parseFromString(responseText);
341
+                        responseXML
342
+                            = new DOMParser().parseFromString(
343
+                                    responseText,
344
+                                    'text/xml');
348 345
                     }
349 346
 
350 347
                     return responseXML;
@@ -355,16 +352,16 @@ function _visitNode(node, callback) {
355 352
 
356 353
     // Timers
357 354
     //
358
-    // React Native's timers won't run while the app is in the background,
359
-    // this is a known limitation. Replace them with a background-friendly
355
+    // React Native's timers won't run while the app is in the background, this
356
+    // is a known limitation. Replace them with a background-friendly
360 357
     // alternative.
361 358
     //
362 359
     // Required by:
363 360
     // - lib-jitsi-meet
364 361
     // - Strophe
365
-    global.setTimeout = window.setTimeout = BackgroundTimer.setTimeout;
366 362
     global.clearTimeout = window.clearTimeout = BackgroundTimer.clearTimeout;
367
-    global.setInterval = window.setInterval = BackgroundTimer.setInterval;
368 363
     global.clearInterval = window.clearInterval = BackgroundTimer.clearInterval;
364
+    global.setInterval = window.setInterval = BackgroundTimer.setInterval;
365
+    global.setTimeout = window.setTimeout = BackgroundTimer.setTimeout;
369 366
 
370 367
 })(global || window || this); // eslint-disable-line no-invalid-this

Laden…
Abbrechen
Speichern