react-native-macos 0.66.77 → 0.66.80

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -12,6 +12,6 @@
12
12
  exports.version = {
13
13
  major: 0,
14
14
  minor: 66,
15
- patch: 77,
15
+ patch: 80,
16
16
  prerelease: null,
17
17
  };
@@ -23,7 +23,7 @@ NSDictionary* RCTGetReactNativeVersion(void)
23
23
  __rnVersion = @{
24
24
  RCTVersionMajor: @(0),
25
25
  RCTVersionMinor: @(66),
26
- RCTVersionPatch: @(77),
26
+ RCTVersionPatch: @(80),
27
27
  RCTVersionPrerelease: [NSNull null],
28
28
  };
29
29
  });
@@ -168,7 +168,7 @@ RCT_EXPORT_MODULE()
168
168
  {
169
169
  if (!_devMenuItem) {
170
170
  __weak __typeof__(self) weakSelf = self;
171
- __weak RCTDevSettings *devSettings = [self->_moduleRegistry moduleForName:"DevSettings"];
171
+ __weak RCTDevSettings *devSettings = [[self bridge] devSettings]; // TODO(macOS GH#774)
172
172
  if (devSettings.isPerfMonitorShown) {
173
173
  [weakSelf show];
174
174
  }
@@ -8,7 +8,8 @@
8
8
  #import "RCTActivityIndicatorView.h"
9
9
 
10
10
  #if TARGET_OS_OSX // [TODO(macOS GH#774)
11
- #import <QuartzCore/QuartzCore.h>
11
+ #import <CoreImage/CIFilter.h>
12
+ #import <CoreImage/CIVector.h>
12
13
 
13
14
  @interface RCTActivityIndicatorView ()
14
15
  @property (nonatomic, readwrite, getter=isAnimating) BOOL animating;
@@ -789,6 +789,9 @@ RCT_NOT_IMPLEMENTED(-(instancetype)initWithCoder : unused)
789
789
  name:NSViewBoundsDidChangeNotification
790
790
  object:[[self enclosingScrollView] contentView]];
791
791
  }
792
+
793
+ [self reactViewDidMoveToWindow]; // TODO(macOS GH#1412)
794
+
792
795
  [super viewDidMoveToWindow];
793
796
  }
794
797
 
@@ -91,6 +91,8 @@
91
91
  - (void)reactAddControllerToClosestParent:(UIViewController *)controller;
92
92
  #endif // TODO(macOS GH#774)
93
93
 
94
+ - (void)reactViewDidMoveToWindow; // TODO(macOS GH#1412)
95
+
94
96
  /**
95
97
  * Focus manipulation.
96
98
  */
@@ -270,18 +270,17 @@
270
270
  }
271
271
  #endif // TODO(macOS GH#774)
272
272
 
273
- /**
274
- * Focus manipulation.
275
- */
276
- - (BOOL)reactIsFocusNeeded
273
+ // [TODO(macOS GH#1412)
274
+ - (void)reactViewDidMoveToWindow
277
275
  {
278
- return [(NSNumber *)objc_getAssociatedObject(self, @selector(reactIsFocusNeeded)) boolValue];
276
+ [self reactFocusIfNeeded];
279
277
  }
278
+ // TODO(macOS GH#1412)]
280
279
 
281
- - (void)setReactIsFocusNeeded:(BOOL)isFocusNeeded
282
- {
283
- objc_setAssociatedObject(self, @selector(reactIsFocusNeeded), @(isFocusNeeded), OBJC_ASSOCIATION_RETAIN_NONATOMIC);
284
- }
280
+ /**
281
+ * Focus manipulation.
282
+ */
283
+ static __weak RCTPlatformView *_pendingFocusView; // TODO(macOS GH#1412)
285
284
 
286
285
  - (void)reactFocus
287
286
  {
@@ -290,19 +289,23 @@
290
289
  #else
291
290
  if (![self becomeFirstResponder]) {
292
291
  #endif //// TODO(macOS GH#774)]
293
- self.reactIsFocusNeeded = YES;
294
- }
292
+ // [TODO(macOS GH#1412)
293
+ _pendingFocusView = self;
294
+ } else {
295
+ _pendingFocusView = nil;
296
+ }
297
+ // TODO(macOS GH#1412)]
295
298
  }
296
299
 
297
300
  - (void)reactFocusIfNeeded
298
301
  {
299
- if (self.reactIsFocusNeeded) {
302
+ if ([self isEqual:_pendingFocusView]) { // TODO(macOS GH#1412)
300
303
  #if TARGET_OS_OSX // [TODO(macOS GH#774)
301
304
  if ([[self window] makeFirstResponder:self]) {
302
305
  #else
303
306
  if ([self becomeFirstResponder]) {
304
307
  #endif // TODO(macOS GH#774)]
305
- self.reactIsFocusNeeded = NO;
308
+ _pendingFocusView = nil; // TODO(macOS GH#1412)
306
309
  }
307
310
  }
308
311
  }
@@ -316,6 +319,12 @@
316
319
  #else
317
320
  [self resignFirstResponder];
318
321
  #endif // TODO(macOS GH#774)]
322
+
323
+ // [TODO(macOS GH#1412)
324
+ if ([self isEqual:_pendingFocusView]) {
325
+ _pendingFocusView = nil;
326
+ }
327
+ // TODO(macOS GH#1412)]
319
328
  }
320
329
 
321
330
  #pragma mark - Layout
@@ -1,4 +1,4 @@
1
- VERSION_NAME=0.66.77
1
+ VERSION_NAME=0.66.80
2
2
  GROUP=com.facebook.react
3
3
 
4
4
  POM_NAME=ReactNative
@@ -17,6 +17,6 @@ public class ReactNativeVersion {
17
17
  public static final Map<String, Object> VERSION = MapBuilder.<String, Object>of(
18
18
  "major", 0,
19
19
  "minor", 66,
20
- "patch", 77,
20
+ "patch", 80,
21
21
  "prerelease", null);
22
22
  }
@@ -17,7 +17,7 @@ namespace facebook::react {
17
17
  constexpr struct {
18
18
  int32_t Major = 0;
19
19
  int32_t Minor = 66;
20
- int32_t Patch = 77;
20
+ int32_t Patch = 80;
21
21
  std::string_view Prerelease = "";
22
22
  } ReactNativeVersion;
23
23
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-macos",
3
- "version": "0.66.77",
3
+ "version": "0.66.80",
4
4
  "bin": "./cli.js",
5
5
  "description": "React Native for macOS",
6
6
  "license": "MIT",
@@ -11,7 +11,7 @@
11
11
  },
12
12
  "dependencies": {
13
13
  "react": "17.0.2",
14
- "react-native": "0.66.77"
14
+ "react-native": "0.66.80"
15
15
  },
16
16
  "devDependencies": {
17
17
  "@babel/core": "^7.12.9",