react-native 0.81.0 → 0.81.2
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.
- package/Libraries/Components/Switch/Switch.js +1 -1
- package/Libraries/Components/TextInput/TextInput.js +6 -1
- package/Libraries/Core/ReactNativeVersion.js +1 -1
- package/React/Base/RCTUtils.h +1 -0
- package/React/Base/RCTUtils.mm +12 -0
- package/React/Base/RCTVersion.m +1 -1
- package/React/FBReactNativeSpec/FBReactNativeSpecJSI-generated.cpp +12 -0
- package/React/FBReactNativeSpec/FBReactNativeSpecJSI.h +18 -0
- package/React/FBReactNativeSpec/react/renderer/components/FBReactNativeSpec/ComponentDescriptors.cpp +0 -1
- package/React/FBReactNativeSpec/react/renderer/components/FBReactNativeSpec/ComponentDescriptors.h +0 -1
- package/React/FBReactNativeSpec/react/renderer/components/FBReactNativeSpec/ShadowNodes.cpp +0 -1
- package/React/FBReactNativeSpec/react/renderer/components/FBReactNativeSpec/ShadowNodes.h +0 -11
- package/React/FBReactNativeSpec/react/renderer/components/FBReactNativeSpec/States.h +0 -2
- package/React/Fabric/Mounting/ComponentViews/Modal/RCTModalHostViewComponentView.mm +22 -0
- package/React/Fabric/Mounting/ComponentViews/Switch/RCTSwitchComponentView.mm +1 -1
- package/React/Fabric/Mounting/ComponentViews/TextInput/RCTTextInputComponentView.mm +2 -1
- package/React/React-RCTFBReactNativeSpec.podspec +1 -4
- package/React/React-RCTFabric.podspec +1 -0
- package/React/Runtime/React-RCTRuntime.podspec +1 -3
- package/ReactAndroid/build.gradle.kts +10 -1
- package/ReactAndroid/gradle.properties +1 -1
- package/ReactAndroid/hermes-engine/build.gradle.kts +6 -0
- package/ReactAndroid/src/main/java/com/facebook/react/bridge/ReadableNativeArray.kt +9 -1
- package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlags.kt +13 -1
- package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsCxxAccessor.kt +21 -1
- package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsCxxInterop.kt +5 -1
- package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsDefaults.kt +5 -1
- package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsLocalAccessor.kt +23 -1
- package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsOverrides_RNOSS_Experimental_Android.kt +5 -1
- package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsProvider.kt +5 -1
- package/ReactAndroid/src/main/java/com/facebook/react/modules/systeminfo/ReactNativeVersion.kt +1 -1
- package/ReactAndroid/src/main/java/com/facebook/react/uimanager/TransformHelper.kt +19 -0
- package/ReactAndroid/src/main/jni/react/featureflags/JReactNativeFeatureFlagsCxxInterop.cpp +29 -1
- package/ReactAndroid/src/main/jni/react/featureflags/JReactNativeFeatureFlagsCxxInterop.h +7 -1
- package/ReactAndroid/src/main/jni/react/hermes/reactexecutor/CMakeLists.txt +3 -1
- package/ReactAndroid/src/main/jni/react/jni/CMakeLists.txt +2 -1
- package/ReactAndroid/src/main/jni/react/jni/NativeArray.h +4 -0
- package/ReactAndroid/src/main/jni/react/jni/OnLoad-common.cpp +2 -0
- package/ReactAndroid/src/main/jni/react/jni/ReadableNativeArray.cpp +6 -0
- package/ReactAndroid/src/main/jni/react/jni/ReadableNativeArray.h +1 -0
- package/ReactAndroid/src/main/jni/react/jni/TransformHelper.cpp +60 -0
- package/ReactAndroid/src/main/jni/react/jni/TransformHelper.h +22 -0
- package/ReactAndroid/src/main/jni/react/runtime/hermes/jni/CMakeLists.txt +3 -1
- package/ReactAndroid/src/main/jni/react/runtime/jni/CMakeLists.txt +3 -1
- package/ReactCommon/React-Fabric.podspec +1 -4
- package/ReactCommon/React-FabricComponents.podspec +9 -4
- package/ReactCommon/React-FabricImage.podspec +1 -4
- package/ReactCommon/React-Mapbuffer.podspec +1 -4
- package/ReactCommon/ReactCommon.podspec +2 -3
- package/ReactCommon/cxxreact/ReactNativeVersion.h +2 -2
- package/ReactCommon/hermes/executor/CMakeLists.txt +1 -1
- package/ReactCommon/hermes/executor/React-jsitracing.podspec +1 -4
- package/ReactCommon/hermes/inspector-modern/CMakeLists.txt +1 -1
- package/ReactCommon/jserrorhandler/React-jserrorhandler.podspec +2 -4
- package/ReactCommon/jsinspector-modern/CMakeLists.txt +6 -4
- package/ReactCommon/jsinspector-modern/React-jsinspector.podspec +2 -3
- package/ReactCommon/jsinspector-modern/cdp/React-jsinspectorcdp.podspec +1 -4
- package/ReactCommon/jsinspector-modern/network/React-jsinspectornetwork.podspec +1 -4
- package/ReactCommon/jsinspector-modern/tracing/React-jsinspectortracing.podspec +1 -4
- package/ReactCommon/jsitooling/React-jsitooling.podspec +1 -4
- package/ReactCommon/react/debug/CMakeLists.txt +1 -1
- package/ReactCommon/react/debug/React-debug.podspec +1 -4
- package/ReactCommon/react/featureflags/React-featureflags.podspec +1 -4
- package/ReactCommon/react/featureflags/ReactNativeFeatureFlags.cpp +9 -1
- package/ReactCommon/react/featureflags/ReactNativeFeatureFlags.h +11 -1
- package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsAccessor.cpp +44 -8
- package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsAccessor.h +6 -2
- package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsDefaults.h +9 -1
- package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsDynamicProvider.h +19 -1
- package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsOverridesOSSExperimental.h +9 -1
- package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsProvider.h +3 -1
- package/ReactCommon/react/nativemodule/core/platform/ios/React-NativeModulesApple.podspec +2 -3
- package/ReactCommon/react/nativemodule/defaults/React-defaultsnativemodule.podspec +1 -4
- package/ReactCommon/react/nativemodule/dom/React-domnativemodule.podspec +1 -4
- package/ReactCommon/react/nativemodule/featureflags/NativeReactNativeFeatureFlags.cpp +11 -1
- package/ReactCommon/react/nativemodule/featureflags/NativeReactNativeFeatureFlags.h +5 -1
- package/ReactCommon/react/nativemodule/featureflags/React-featureflagsnativemodule.podspec +1 -4
- package/ReactCommon/react/nativemodule/idlecallbacks/React-idlecallbacksnativemodule.podspec +1 -4
- package/ReactCommon/react/nativemodule/microtasks/React-microtasksnativemodule.podspec +1 -4
- package/ReactCommon/react/nativemodule/samples/ReactCommon-Samples.podspec +2 -0
- package/ReactCommon/react/performance/timeline/React-performancetimeline.podspec +1 -4
- package/ReactCommon/react/renderer/components/switch/iosswitch/react/renderer/components/switch/AppleSwitchComponentDescriptor.h +30 -0
- package/ReactCommon/react/renderer/components/switch/iosswitch/react/renderer/components/switch/AppleSwitchShadowNode.h +42 -0
- package/ReactCommon/react/renderer/components/switch/iosswitch/react/renderer/components/switch/IOSSwitchShadowNode.mm +28 -0
- package/ReactCommon/react/renderer/components/switch/iosswitch/react/renderer/components/switch/MacOSSwitchShadowNode.mm +32 -0
- package/ReactCommon/react/renderer/components/textinput/BaseTextInputProps.h +2 -1
- package/ReactCommon/react/renderer/components/view/BaseViewProps.cpp +8 -2
- package/ReactCommon/react/renderer/components/view/BaseViewProps.h +5 -0
- package/ReactCommon/react/renderer/consistency/React-rendererconsistency.podspec +2 -4
- package/ReactCommon/react/renderer/css/React-renderercss.podspec +2 -5
- package/ReactCommon/react/renderer/debug/React-rendererdebug.podspec +1 -4
- package/ReactCommon/react/renderer/graphics/React-graphics.podspec +3 -3
- package/ReactCommon/react/renderer/imagemanager/platform/ios/React-ImageManager.podspec +1 -4
- package/ReactCommon/react/renderer/runtimescheduler/React-runtimescheduler.podspec +1 -4
- package/ReactCommon/react/runtime/CMakeLists.txt +3 -1
- package/ReactCommon/react/runtime/React-RuntimeCore.podspec +1 -4
- package/ReactCommon/react/runtime/React-RuntimeHermes.podspec +1 -4
- package/ReactCommon/react/runtime/hermes/CMakeLists.txt +1 -1
- package/ReactCommon/react/runtime/platform/ios/React-RuntimeApple.podspec +1 -4
- package/ReactCommon/react/runtime/platform/ios/ReactCommon/RCTInstance.mm +1 -0
- package/ReactCommon/react/timing/React-timing.podspec +3 -4
- package/ReactCommon/react/utils/React-utils.podspec +3 -3
- package/ReactCommon/runtimeexecutor/React-runtimeexecutor.podspec +3 -2
- package/package.json +8 -8
- package/scripts/cocoapods/autolinking.rb +6 -0
- package/scripts/cocoapods/codegen_utils.rb +1 -1
- package/scripts/cocoapods/new_architecture.rb +1 -0
- package/scripts/cocoapods/utils.rb +15 -1
- package/scripts/codegen/generate-artifacts-executor/generateReactCodegenPodspec.js +3 -3
- package/scripts/codegen/generate-artifacts-executor/index.js +5 -1
- package/scripts/codegen/generate-artifacts-executor/utils.js +41 -10
- package/scripts/codegen/templates/ReactCodegen.podspec.template +1 -0
- package/scripts/react-native-xcode.sh +2 -2
- package/scripts/react_native_pods.rb +21 -0
- package/scripts/replace-rncore-version.js +4 -2
- package/scripts/xcode/with-environment.sh +1 -1
- package/sdks/hermes-engine/utils/replace_hermes_version.js +4 -2
- package/sdks/hermesc/osx-bin/hermes +0 -0
- package/sdks/hermesc/osx-bin/hermesc +0 -0
- package/sdks/hermesc/win64-bin/hermesc.exe +0 -0
- package/src/private/featureflags/ReactNativeFeatureFlags.js +11 -1
- package/src/private/featureflags/specs/NativeReactNativeFeatureFlags.js +3 -1
- package/src/private/specs_DEPRECATED/components/SwitchNativeComponent.js +1 -0
- package/third-party-podspecs/ReactNativeDependencies.podspec +1 -1
- package/third-party-podspecs/replace_dependencies_version.js +4 -2
|
@@ -618,6 +618,9 @@ function InternalTextInput(props: TextInputProps): React.Node {
|
|
|
618
618
|
// so omitting onBlur and onFocus pressability handlers here.
|
|
619
619
|
const {onBlur, onFocus, ...eventHandlers} = usePressability(config);
|
|
620
620
|
|
|
621
|
+
const _accessibilityLabel =
|
|
622
|
+
props?.['aria-label'] ?? props?.accessibilityLabel;
|
|
623
|
+
|
|
621
624
|
let _accessibilityState;
|
|
622
625
|
if (
|
|
623
626
|
accessibilityState != null ||
|
|
@@ -681,6 +684,7 @@ function InternalTextInput(props: TextInputProps): React.Node {
|
|
|
681
684
|
{...otherProps}
|
|
682
685
|
{...eventHandlers}
|
|
683
686
|
acceptDragAndDropTypes={props.experimental_acceptDragAndDropTypes}
|
|
687
|
+
accessibilityLabel={_accessibilityLabel}
|
|
684
688
|
accessibilityState={_accessibilityState}
|
|
685
689
|
accessible={accessible}
|
|
686
690
|
submitBehavior={submitBehavior}
|
|
@@ -744,8 +748,9 @@ function InternalTextInput(props: TextInputProps): React.Node {
|
|
|
744
748
|
{...otherProps}
|
|
745
749
|
{...colorProps}
|
|
746
750
|
{...eventHandlers}
|
|
747
|
-
|
|
751
|
+
accessibilityLabel={_accessibilityLabel}
|
|
748
752
|
accessibilityLabelledBy={_accessibilityLabelledBy}
|
|
753
|
+
accessibilityState={_accessibilityState}
|
|
749
754
|
accessible={accessible}
|
|
750
755
|
acceptDragAndDropTypes={props.experimental_acceptDragAndDropTypes}
|
|
751
756
|
autoCapitalize={autoCapitalize}
|
package/React/Base/RCTUtils.h
CHANGED
|
@@ -54,6 +54,7 @@ RCT_EXTERN CGFloat RCTScreenScale(void);
|
|
|
54
54
|
RCT_EXTERN CGFloat RCTFontSizeMultiplier(void);
|
|
55
55
|
RCT_EXTERN CGSize RCTScreenSize(void);
|
|
56
56
|
RCT_EXTERN CGSize RCTViewportSize(void);
|
|
57
|
+
RCT_EXTERN CGSize RCTSwitchSize(void);
|
|
57
58
|
|
|
58
59
|
// Round float coordinates to nearest whole screen pixel (not point)
|
|
59
60
|
RCT_EXTERN CGFloat RCTRoundPixelValue(CGFloat value);
|
package/React/Base/RCTUtils.mm
CHANGED
|
@@ -426,6 +426,18 @@ CGSize RCTViewportSize(void)
|
|
|
426
426
|
return window ? window.bounds.size : RCTScreenSize();
|
|
427
427
|
}
|
|
428
428
|
|
|
429
|
+
CGSize RCTSwitchSize(void)
|
|
430
|
+
{
|
|
431
|
+
static CGSize rctSwitchSize;
|
|
432
|
+
static dispatch_once_t onceToken;
|
|
433
|
+
dispatch_once(&onceToken, ^{
|
|
434
|
+
RCTUnsafeExecuteOnMainQueueSync(^{
|
|
435
|
+
rctSwitchSize = [UISwitch new].intrinsicContentSize;
|
|
436
|
+
});
|
|
437
|
+
});
|
|
438
|
+
return rctSwitchSize;
|
|
439
|
+
}
|
|
440
|
+
|
|
429
441
|
CGFloat RCTRoundPixelValue(CGFloat value)
|
|
430
442
|
{
|
|
431
443
|
CGFloat scale = RCTScreenScale();
|
package/React/Base/RCTVersion.m
CHANGED
|
@@ -347,6 +347,16 @@ static jsi::Value __hostFunction_NativeReactNativeFeatureFlagsCxxSpecJSI_useFabr
|
|
|
347
347
|
rt
|
|
348
348
|
);
|
|
349
349
|
}
|
|
350
|
+
static jsi::Value __hostFunction_NativeReactNativeFeatureFlagsCxxSpecJSI_useNativeEqualsInNativeReadableArrayAndroid(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
|
|
351
|
+
return static_cast<NativeReactNativeFeatureFlagsCxxSpecJSI *>(&turboModule)->useNativeEqualsInNativeReadableArrayAndroid(
|
|
352
|
+
rt
|
|
353
|
+
);
|
|
354
|
+
}
|
|
355
|
+
static jsi::Value __hostFunction_NativeReactNativeFeatureFlagsCxxSpecJSI_useNativeTransformHelperAndroid(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
|
|
356
|
+
return static_cast<NativeReactNativeFeatureFlagsCxxSpecJSI *>(&turboModule)->useNativeTransformHelperAndroid(
|
|
357
|
+
rt
|
|
358
|
+
);
|
|
359
|
+
}
|
|
350
360
|
static jsi::Value __hostFunction_NativeReactNativeFeatureFlagsCxxSpecJSI_useNativeViewConfigsInBridgelessMode(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
|
|
351
361
|
return static_cast<NativeReactNativeFeatureFlagsCxxSpecJSI *>(&turboModule)->useNativeViewConfigsInBridgelessMode(
|
|
352
362
|
rt
|
|
@@ -438,6 +448,8 @@ NativeReactNativeFeatureFlagsCxxSpecJSI::NativeReactNativeFeatureFlagsCxxSpecJSI
|
|
|
438
448
|
methodMap_["updateRuntimeShadowNodeReferencesOnCommit"] = MethodMetadata {0, __hostFunction_NativeReactNativeFeatureFlagsCxxSpecJSI_updateRuntimeShadowNodeReferencesOnCommit};
|
|
439
449
|
methodMap_["useAlwaysAvailableJSErrorHandling"] = MethodMetadata {0, __hostFunction_NativeReactNativeFeatureFlagsCxxSpecJSI_useAlwaysAvailableJSErrorHandling};
|
|
440
450
|
methodMap_["useFabricInterop"] = MethodMetadata {0, __hostFunction_NativeReactNativeFeatureFlagsCxxSpecJSI_useFabricInterop};
|
|
451
|
+
methodMap_["useNativeEqualsInNativeReadableArrayAndroid"] = MethodMetadata {0, __hostFunction_NativeReactNativeFeatureFlagsCxxSpecJSI_useNativeEqualsInNativeReadableArrayAndroid};
|
|
452
|
+
methodMap_["useNativeTransformHelperAndroid"] = MethodMetadata {0, __hostFunction_NativeReactNativeFeatureFlagsCxxSpecJSI_useNativeTransformHelperAndroid};
|
|
441
453
|
methodMap_["useNativeViewConfigsInBridgelessMode"] = MethodMetadata {0, __hostFunction_NativeReactNativeFeatureFlagsCxxSpecJSI_useNativeViewConfigsInBridgelessMode};
|
|
442
454
|
methodMap_["useOptimizedEventBatchingOnAndroid"] = MethodMetadata {0, __hostFunction_NativeReactNativeFeatureFlagsCxxSpecJSI_useOptimizedEventBatchingOnAndroid};
|
|
443
455
|
methodMap_["useRawPropsJsiValue"] = MethodMetadata {0, __hostFunction_NativeReactNativeFeatureFlagsCxxSpecJSI_useRawPropsJsiValue};
|
|
@@ -379,6 +379,8 @@ public:
|
|
|
379
379
|
virtual bool updateRuntimeShadowNodeReferencesOnCommit(jsi::Runtime &rt) = 0;
|
|
380
380
|
virtual bool useAlwaysAvailableJSErrorHandling(jsi::Runtime &rt) = 0;
|
|
381
381
|
virtual bool useFabricInterop(jsi::Runtime &rt) = 0;
|
|
382
|
+
virtual bool useNativeEqualsInNativeReadableArrayAndroid(jsi::Runtime &rt) = 0;
|
|
383
|
+
virtual bool useNativeTransformHelperAndroid(jsi::Runtime &rt) = 0;
|
|
382
384
|
virtual bool useNativeViewConfigsInBridgelessMode(jsi::Runtime &rt) = 0;
|
|
383
385
|
virtual bool useOptimizedEventBatchingOnAndroid(jsi::Runtime &rt) = 0;
|
|
384
386
|
virtual bool useRawPropsJsiValue(jsi::Runtime &rt) = 0;
|
|
@@ -840,6 +842,22 @@ private:
|
|
|
840
842
|
return bridging::callFromJs<bool>(
|
|
841
843
|
rt, &T::useFabricInterop, jsInvoker_, instance_);
|
|
842
844
|
}
|
|
845
|
+
bool useNativeEqualsInNativeReadableArrayAndroid(jsi::Runtime &rt) override {
|
|
846
|
+
static_assert(
|
|
847
|
+
bridging::getParameterCount(&T::useNativeEqualsInNativeReadableArrayAndroid) == 1,
|
|
848
|
+
"Expected useNativeEqualsInNativeReadableArrayAndroid(...) to have 1 parameters");
|
|
849
|
+
|
|
850
|
+
return bridging::callFromJs<bool>(
|
|
851
|
+
rt, &T::useNativeEqualsInNativeReadableArrayAndroid, jsInvoker_, instance_);
|
|
852
|
+
}
|
|
853
|
+
bool useNativeTransformHelperAndroid(jsi::Runtime &rt) override {
|
|
854
|
+
static_assert(
|
|
855
|
+
bridging::getParameterCount(&T::useNativeTransformHelperAndroid) == 1,
|
|
856
|
+
"Expected useNativeTransformHelperAndroid(...) to have 1 parameters");
|
|
857
|
+
|
|
858
|
+
return bridging::callFromJs<bool>(
|
|
859
|
+
rt, &T::useNativeTransformHelperAndroid, jsInvoker_, instance_);
|
|
860
|
+
}
|
|
843
861
|
bool useNativeViewConfigsInBridgelessMode(jsi::Runtime &rt) override {
|
|
844
862
|
static_assert(
|
|
845
863
|
bridging::getParameterCount(&T::useNativeViewConfigsInBridgelessMode) == 1,
|
package/React/FBReactNativeSpec/react/renderer/components/FBReactNativeSpec/ComponentDescriptors.cpp
CHANGED
|
@@ -21,7 +21,6 @@ registry->add(concreteComponentDescriptorProvider<AndroidDrawerLayoutComponentDe
|
|
|
21
21
|
registry->add(concreteComponentDescriptorProvider<AndroidSwipeRefreshLayoutComponentDescriptor>());
|
|
22
22
|
registry->add(concreteComponentDescriptorProvider<DebuggingOverlayComponentDescriptor>());
|
|
23
23
|
registry->add(concreteComponentDescriptorProvider<PullToRefreshViewComponentDescriptor>());
|
|
24
|
-
registry->add(concreteComponentDescriptorProvider<SwitchComponentDescriptor>());
|
|
25
24
|
registry->add(concreteComponentDescriptorProvider<UnimplementedNativeViewComponentDescriptor>());
|
|
26
25
|
}
|
|
27
26
|
|
package/React/FBReactNativeSpec/react/renderer/components/FBReactNativeSpec/ComponentDescriptors.h
CHANGED
|
@@ -21,7 +21,6 @@ using AndroidDrawerLayoutComponentDescriptor = ConcreteComponentDescriptor<Andro
|
|
|
21
21
|
using AndroidSwipeRefreshLayoutComponentDescriptor = ConcreteComponentDescriptor<AndroidSwipeRefreshLayoutShadowNode>;
|
|
22
22
|
using DebuggingOverlayComponentDescriptor = ConcreteComponentDescriptor<DebuggingOverlayShadowNode>;
|
|
23
23
|
using PullToRefreshViewComponentDescriptor = ConcreteComponentDescriptor<PullToRefreshViewShadowNode>;
|
|
24
|
-
using SwitchComponentDescriptor = ConcreteComponentDescriptor<SwitchShadowNode>;
|
|
25
24
|
using UnimplementedNativeViewComponentDescriptor = ConcreteComponentDescriptor<UnimplementedNativeViewShadowNode>;
|
|
26
25
|
|
|
27
26
|
void FBReactNativeSpec_registerComponentDescriptorsFromCodegen(
|
|
@@ -17,7 +17,6 @@ extern const char AndroidDrawerLayoutComponentName[] = "AndroidDrawerLayout";
|
|
|
17
17
|
extern const char AndroidSwipeRefreshLayoutComponentName[] = "AndroidSwipeRefreshLayout";
|
|
18
18
|
extern const char DebuggingOverlayComponentName[] = "DebuggingOverlay";
|
|
19
19
|
extern const char PullToRefreshViewComponentName[] = "PullToRefreshView";
|
|
20
|
-
extern const char SwitchComponentName[] = "Switch";
|
|
21
20
|
extern const char UnimplementedNativeViewComponentName[] = "UnimplementedNativeView";
|
|
22
21
|
|
|
23
22
|
} // namespace facebook::react
|
|
@@ -73,17 +73,6 @@ using PullToRefreshViewShadowNode = ConcreteViewShadowNode<
|
|
|
73
73
|
PullToRefreshViewEventEmitter,
|
|
74
74
|
PullToRefreshViewState>;
|
|
75
75
|
|
|
76
|
-
JSI_EXPORT extern const char SwitchComponentName[];
|
|
77
|
-
|
|
78
|
-
/*
|
|
79
|
-
* `ShadowNode` for <Switch> component.
|
|
80
|
-
*/
|
|
81
|
-
using SwitchShadowNode = ConcreteViewShadowNode<
|
|
82
|
-
SwitchComponentName,
|
|
83
|
-
SwitchProps,
|
|
84
|
-
SwitchEventEmitter,
|
|
85
|
-
SwitchState>;
|
|
86
|
-
|
|
87
76
|
JSI_EXPORT extern const char UnimplementedNativeViewComponentName[];
|
|
88
77
|
|
|
89
78
|
/*
|
|
@@ -96,6 +96,8 @@ static ModalHostViewEventEmitter::OnOrientationChange onOrientationChangeStruct(
|
|
|
96
96
|
|
|
97
97
|
@interface RCTModalHostViewComponentView () <RCTFabricModalHostViewControllerDelegate>
|
|
98
98
|
|
|
99
|
+
@property (nonatomic, weak) UIView *accessibilityFocusedView;
|
|
100
|
+
|
|
99
101
|
@end
|
|
100
102
|
|
|
101
103
|
@implementation RCTModalHostViewComponentView {
|
|
@@ -148,6 +150,7 @@ static ModalHostViewEventEmitter::OnOrientationChange onOrientationChangeStruct(
|
|
|
148
150
|
{
|
|
149
151
|
BOOL shouldBePresented = !_isPresented && _shouldPresent && self.window;
|
|
150
152
|
if (shouldBePresented) {
|
|
153
|
+
[self saveAccessibilityFocusedView];
|
|
151
154
|
self.viewController.presentationController.delegate = self;
|
|
152
155
|
|
|
153
156
|
_isPresented = YES;
|
|
@@ -179,6 +182,8 @@ static ModalHostViewEventEmitter::OnOrientationChange onOrientationChangeStruct(
|
|
|
179
182
|
if (eventEmitter) {
|
|
180
183
|
eventEmitter->onDismiss(ModalHostViewEventEmitter::OnDismiss{});
|
|
181
184
|
}
|
|
185
|
+
|
|
186
|
+
[self restoreAccessibilityFocusedView];
|
|
182
187
|
}];
|
|
183
188
|
}
|
|
184
189
|
}
|
|
@@ -207,6 +212,23 @@ static ModalHostViewEventEmitter::OnOrientationChange onOrientationChangeStruct(
|
|
|
207
212
|
[self ensurePresentedOnlyIfNeeded];
|
|
208
213
|
}
|
|
209
214
|
|
|
215
|
+
- (void)saveAccessibilityFocusedView
|
|
216
|
+
{
|
|
217
|
+
id focusedElement = UIAccessibilityFocusedElement(nil);
|
|
218
|
+
if (focusedElement && [focusedElement isKindOfClass:[UIView class]]) {
|
|
219
|
+
self.accessibilityFocusedView = (UIView *)focusedElement;
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
- (void)restoreAccessibilityFocusedView
|
|
224
|
+
{
|
|
225
|
+
id viewToFocus = self.accessibilityFocusedView;
|
|
226
|
+
if (viewToFocus) {
|
|
227
|
+
UIAccessibilityPostNotification(UIAccessibilityScreenChangedNotification, viewToFocus);
|
|
228
|
+
self.accessibilityFocusedView = nil;
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
|
|
210
232
|
#pragma mark - RCTFabricModalHostViewControllerDelegate
|
|
211
233
|
|
|
212
234
|
- (void)boundsDidChange:(CGRect)newBounds
|
|
@@ -9,10 +9,10 @@
|
|
|
9
9
|
|
|
10
10
|
#import <React/RCTConversions.h>
|
|
11
11
|
|
|
12
|
-
#import <react/renderer/components/FBReactNativeSpec/ComponentDescriptors.h>
|
|
13
12
|
#import <react/renderer/components/FBReactNativeSpec/EventEmitters.h>
|
|
14
13
|
#import <react/renderer/components/FBReactNativeSpec/Props.h>
|
|
15
14
|
#import <react/renderer/components/FBReactNativeSpec/RCTComponentViewHelpers.h>
|
|
15
|
+
#import <react/renderer/components/switch/AppleSwitchComponentDescriptor.h>
|
|
16
16
|
|
|
17
17
|
#import "RCTFabricComponentsPlugins.h"
|
|
18
18
|
|
|
@@ -22,6 +22,7 @@
|
|
|
22
22
|
#import "RCTTextInputNativeCommands.h"
|
|
23
23
|
#import "RCTTextInputUtils.h"
|
|
24
24
|
|
|
25
|
+
#import <limits>
|
|
25
26
|
#import "RCTFabricComponentsPlugins.h"
|
|
26
27
|
|
|
27
28
|
/** Native iOS text field bottom keyboard offset amount */
|
|
@@ -447,7 +448,7 @@ static NSSet<NSNumber *> *returnKeyTypesSet;
|
|
|
447
448
|
}
|
|
448
449
|
}
|
|
449
450
|
|
|
450
|
-
if (props.maxLength) {
|
|
451
|
+
if (props.maxLength < std::numeric_limits<int>::max()) {
|
|
451
452
|
NSInteger allowedLength = props.maxLength - _backedTextInputView.attributedText.string.length + range.length;
|
|
452
453
|
|
|
453
454
|
if (allowedLength > 0 && text.length > allowedLength) {
|
|
@@ -45,10 +45,7 @@ Pod::Spec.new do |s|
|
|
|
45
45
|
"HEADER_SEARCH_PATHS" => header_search_paths.join(' '),
|
|
46
46
|
}
|
|
47
47
|
|
|
48
|
-
|
|
49
|
-
s.header_mappings_dir = 'FBReactNativeSpec'
|
|
50
|
-
s.module_name = 'React_RCTFBReactNativeSpec'
|
|
51
|
-
end
|
|
48
|
+
resolve_use_frameworks(s, header_mappings_dir: 'FBReactNativeSpec', module_name: "React_RCTFBReactNativeSpec")
|
|
52
49
|
|
|
53
50
|
s.dependency "React-jsi"
|
|
54
51
|
s.dependency "RCTRequired"
|
|
@@ -75,6 +75,7 @@ Pod::Spec.new do |s|
|
|
|
75
75
|
"react/renderer/components/scrollview/platform/cxx",
|
|
76
76
|
"react/renderer/components/text/platform/cxx",
|
|
77
77
|
"react/renderer/components/textinput/platform/ios",
|
|
78
|
+
"react/renderer/components/switch/iosswitch",
|
|
78
79
|
]);
|
|
79
80
|
|
|
80
81
|
add_dependency(s, "React-graphics", :additional_framework_paths => ["react/renderer/graphics/platform/ios"])
|
|
@@ -35,9 +35,7 @@ Pod::Spec.new do |s|
|
|
|
35
35
|
s.header_dir = header_dir
|
|
36
36
|
s.module_name = module_name
|
|
37
37
|
|
|
38
|
-
|
|
39
|
-
s.header_mappings_dir = "./"
|
|
40
|
-
end
|
|
38
|
+
resolve_use_frameworks(s, header_mappings_dir: "./")
|
|
41
39
|
|
|
42
40
|
s.pod_target_xcconfig = {
|
|
43
41
|
"OTHER_CFLAGS" => "$(inherited) " + new_arch_flags,
|
|
@@ -598,7 +598,7 @@ android {
|
|
|
598
598
|
publishing {
|
|
599
599
|
multipleVariants {
|
|
600
600
|
withSourcesJar()
|
|
601
|
-
includeBuildTypeValues("debug", "release")
|
|
601
|
+
includeBuildTypeValues("debug", "release", "debugOptimized")
|
|
602
602
|
}
|
|
603
603
|
}
|
|
604
604
|
|
|
@@ -606,6 +606,15 @@ android {
|
|
|
606
606
|
unitTests { isIncludeAndroidResources = true }
|
|
607
607
|
targetSdk = libs.versions.targetSdk.get().toInt()
|
|
608
608
|
}
|
|
609
|
+
|
|
610
|
+
buildTypes {
|
|
611
|
+
create("debugOptimized") {
|
|
612
|
+
initWith(getByName("debug"))
|
|
613
|
+
externalNativeBuild {
|
|
614
|
+
cmake { arguments("-DCMAKE_BUILD_TYPE=Release", "-DREACT_NATIVE_DEBUG_OPTIMIZED=True") }
|
|
615
|
+
}
|
|
616
|
+
}
|
|
617
|
+
}
|
|
609
618
|
}
|
|
610
619
|
|
|
611
620
|
tasks.withType<KotlinCompile>().configureEach {
|
|
@@ -306,6 +306,12 @@ android {
|
|
|
306
306
|
}
|
|
307
307
|
}
|
|
308
308
|
}
|
|
309
|
+
buildTypes {
|
|
310
|
+
create("debugOptimized") {
|
|
311
|
+
initWith(getByName("debug"))
|
|
312
|
+
externalNativeBuild { cmake { arguments("-DCMAKE_BUILD_TYPE=Release") } }
|
|
313
|
+
}
|
|
314
|
+
}
|
|
309
315
|
}
|
|
310
316
|
|
|
311
317
|
sourceSets.getByName("main") {
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
package com.facebook.react.bridge
|
|
9
9
|
|
|
10
10
|
import com.facebook.proguard.annotations.DoNotStrip
|
|
11
|
+
import com.facebook.react.internal.featureflags.ReactNativeFeatureFlags
|
|
11
12
|
import java.util.ArrayList
|
|
12
13
|
import java.util.Arrays
|
|
13
14
|
import kotlin.jvm.JvmStatic
|
|
@@ -65,9 +66,16 @@ public open class ReadableNativeArray protected constructor() : NativeArray(), R
|
|
|
65
66
|
if (other !is ReadableNativeArray) {
|
|
66
67
|
return false
|
|
67
68
|
}
|
|
68
|
-
|
|
69
|
+
|
|
70
|
+
return if (ReactNativeFeatureFlags.useNativeEqualsInNativeReadableArrayAndroid()) {
|
|
71
|
+
nativeEquals(other)
|
|
72
|
+
} else {
|
|
73
|
+
localArray.contentDeepEquals(other.localArray)
|
|
74
|
+
}
|
|
69
75
|
}
|
|
70
76
|
|
|
77
|
+
private external fun nativeEquals(other: ReadableNativeArray): Boolean
|
|
78
|
+
|
|
71
79
|
override fun toArrayList(): ArrayList<Any?> {
|
|
72
80
|
val arrayList = ArrayList<Any?>()
|
|
73
81
|
repeat(size()) { i ->
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* This source code is licensed under the MIT license found in the
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
|
-
* @generated SignedSource<<
|
|
7
|
+
* @generated SignedSource<<c52f3977ea07f976e36177f13c1ec684>>
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -342,6 +342,18 @@ public object ReactNativeFeatureFlags {
|
|
|
342
342
|
@JvmStatic
|
|
343
343
|
public fun useFabricInterop(): Boolean = accessor.useFabricInterop()
|
|
344
344
|
|
|
345
|
+
/**
|
|
346
|
+
* Use a native implementation of equals in NativeReadableArray.
|
|
347
|
+
*/
|
|
348
|
+
@JvmStatic
|
|
349
|
+
public fun useNativeEqualsInNativeReadableArrayAndroid(): Boolean = accessor.useNativeEqualsInNativeReadableArrayAndroid()
|
|
350
|
+
|
|
351
|
+
/**
|
|
352
|
+
* Use a native implementation of TransformHelper
|
|
353
|
+
*/
|
|
354
|
+
@JvmStatic
|
|
355
|
+
public fun useNativeTransformHelperAndroid(): Boolean = accessor.useNativeTransformHelperAndroid()
|
|
356
|
+
|
|
345
357
|
/**
|
|
346
358
|
* When enabled, the native view configs are used in bridgeless mode.
|
|
347
359
|
*/
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* This source code is licensed under the MIT license found in the
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
|
-
* @generated SignedSource<<
|
|
7
|
+
* @generated SignedSource<<8e0125e82b359e6a175ffc49a4df5537>>
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -72,6 +72,8 @@ internal class ReactNativeFeatureFlagsCxxAccessor : ReactNativeFeatureFlagsAcces
|
|
|
72
72
|
private var updateRuntimeShadowNodeReferencesOnCommitCache: Boolean? = null
|
|
73
73
|
private var useAlwaysAvailableJSErrorHandlingCache: Boolean? = null
|
|
74
74
|
private var useFabricInteropCache: Boolean? = null
|
|
75
|
+
private var useNativeEqualsInNativeReadableArrayAndroidCache: Boolean? = null
|
|
76
|
+
private var useNativeTransformHelperAndroidCache: Boolean? = null
|
|
75
77
|
private var useNativeViewConfigsInBridgelessModeCache: Boolean? = null
|
|
76
78
|
private var useOptimizedEventBatchingOnAndroidCache: Boolean? = null
|
|
77
79
|
private var useRawPropsJsiValueCache: Boolean? = null
|
|
@@ -548,6 +550,24 @@ internal class ReactNativeFeatureFlagsCxxAccessor : ReactNativeFeatureFlagsAcces
|
|
|
548
550
|
return cached
|
|
549
551
|
}
|
|
550
552
|
|
|
553
|
+
override fun useNativeEqualsInNativeReadableArrayAndroid(): Boolean {
|
|
554
|
+
var cached = useNativeEqualsInNativeReadableArrayAndroidCache
|
|
555
|
+
if (cached == null) {
|
|
556
|
+
cached = ReactNativeFeatureFlagsCxxInterop.useNativeEqualsInNativeReadableArrayAndroid()
|
|
557
|
+
useNativeEqualsInNativeReadableArrayAndroidCache = cached
|
|
558
|
+
}
|
|
559
|
+
return cached
|
|
560
|
+
}
|
|
561
|
+
|
|
562
|
+
override fun useNativeTransformHelperAndroid(): Boolean {
|
|
563
|
+
var cached = useNativeTransformHelperAndroidCache
|
|
564
|
+
if (cached == null) {
|
|
565
|
+
cached = ReactNativeFeatureFlagsCxxInterop.useNativeTransformHelperAndroid()
|
|
566
|
+
useNativeTransformHelperAndroidCache = cached
|
|
567
|
+
}
|
|
568
|
+
return cached
|
|
569
|
+
}
|
|
570
|
+
|
|
551
571
|
override fun useNativeViewConfigsInBridgelessMode(): Boolean {
|
|
552
572
|
var cached = useNativeViewConfigsInBridgelessModeCache
|
|
553
573
|
if (cached == null) {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* This source code is licensed under the MIT license found in the
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
|
-
* @generated SignedSource<<
|
|
7
|
+
* @generated SignedSource<<a5d9d11cc2a6529641243dc47a61f201>>
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -132,6 +132,10 @@ public object ReactNativeFeatureFlagsCxxInterop {
|
|
|
132
132
|
|
|
133
133
|
@DoNotStrip @JvmStatic public external fun useFabricInterop(): Boolean
|
|
134
134
|
|
|
135
|
+
@DoNotStrip @JvmStatic public external fun useNativeEqualsInNativeReadableArrayAndroid(): Boolean
|
|
136
|
+
|
|
137
|
+
@DoNotStrip @JvmStatic public external fun useNativeTransformHelperAndroid(): Boolean
|
|
138
|
+
|
|
135
139
|
@DoNotStrip @JvmStatic public external fun useNativeViewConfigsInBridgelessMode(): Boolean
|
|
136
140
|
|
|
137
141
|
@DoNotStrip @JvmStatic public external fun useOptimizedEventBatchingOnAndroid(): Boolean
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* This source code is licensed under the MIT license found in the
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
|
-
* @generated SignedSource<<
|
|
7
|
+
* @generated SignedSource<<10d708ce4449eede46d750a1ed48d02e>>
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -127,6 +127,10 @@ public open class ReactNativeFeatureFlagsDefaults : ReactNativeFeatureFlagsProvi
|
|
|
127
127
|
|
|
128
128
|
override fun useFabricInterop(): Boolean = true
|
|
129
129
|
|
|
130
|
+
override fun useNativeEqualsInNativeReadableArrayAndroid(): Boolean = false
|
|
131
|
+
|
|
132
|
+
override fun useNativeTransformHelperAndroid(): Boolean = false
|
|
133
|
+
|
|
130
134
|
override fun useNativeViewConfigsInBridgelessMode(): Boolean = false
|
|
131
135
|
|
|
132
136
|
override fun useOptimizedEventBatchingOnAndroid(): Boolean = false
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* This source code is licensed under the MIT license found in the
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
|
-
* @generated SignedSource<<
|
|
7
|
+
* @generated SignedSource<<b04948c792c5db63decf1df80d3a867e>>
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -76,6 +76,8 @@ internal class ReactNativeFeatureFlagsLocalAccessor : ReactNativeFeatureFlagsAcc
|
|
|
76
76
|
private var updateRuntimeShadowNodeReferencesOnCommitCache: Boolean? = null
|
|
77
77
|
private var useAlwaysAvailableJSErrorHandlingCache: Boolean? = null
|
|
78
78
|
private var useFabricInteropCache: Boolean? = null
|
|
79
|
+
private var useNativeEqualsInNativeReadableArrayAndroidCache: Boolean? = null
|
|
80
|
+
private var useNativeTransformHelperAndroidCache: Boolean? = null
|
|
79
81
|
private var useNativeViewConfigsInBridgelessModeCache: Boolean? = null
|
|
80
82
|
private var useOptimizedEventBatchingOnAndroidCache: Boolean? = null
|
|
81
83
|
private var useRawPropsJsiValueCache: Boolean? = null
|
|
@@ -604,6 +606,26 @@ internal class ReactNativeFeatureFlagsLocalAccessor : ReactNativeFeatureFlagsAcc
|
|
|
604
606
|
return cached
|
|
605
607
|
}
|
|
606
608
|
|
|
609
|
+
override fun useNativeEqualsInNativeReadableArrayAndroid(): Boolean {
|
|
610
|
+
var cached = useNativeEqualsInNativeReadableArrayAndroidCache
|
|
611
|
+
if (cached == null) {
|
|
612
|
+
cached = currentProvider.useNativeEqualsInNativeReadableArrayAndroid()
|
|
613
|
+
accessedFeatureFlags.add("useNativeEqualsInNativeReadableArrayAndroid")
|
|
614
|
+
useNativeEqualsInNativeReadableArrayAndroidCache = cached
|
|
615
|
+
}
|
|
616
|
+
return cached
|
|
617
|
+
}
|
|
618
|
+
|
|
619
|
+
override fun useNativeTransformHelperAndroid(): Boolean {
|
|
620
|
+
var cached = useNativeTransformHelperAndroidCache
|
|
621
|
+
if (cached == null) {
|
|
622
|
+
cached = currentProvider.useNativeTransformHelperAndroid()
|
|
623
|
+
accessedFeatureFlags.add("useNativeTransformHelperAndroid")
|
|
624
|
+
useNativeTransformHelperAndroidCache = cached
|
|
625
|
+
}
|
|
626
|
+
return cached
|
|
627
|
+
}
|
|
628
|
+
|
|
607
629
|
override fun useNativeViewConfigsInBridgelessMode(): Boolean {
|
|
608
630
|
var cached = useNativeViewConfigsInBridgelessModeCache
|
|
609
631
|
if (cached == null) {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* This source code is licensed under the MIT license found in the
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
|
-
* @generated SignedSource<<
|
|
7
|
+
* @generated SignedSource<<0bafb0a2fb79c4220d21f1736894af14>>
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -24,4 +24,8 @@ public open class ReactNativeFeatureFlagsOverrides_RNOSS_Experimental_Android :
|
|
|
24
24
|
// but that is more expensive than just duplicating the defaults here.
|
|
25
25
|
|
|
26
26
|
override fun preventShadowTreeCommitExhaustion(): Boolean = true
|
|
27
|
+
|
|
28
|
+
override fun useNativeEqualsInNativeReadableArrayAndroid(): Boolean = true
|
|
29
|
+
|
|
30
|
+
override fun useNativeTransformHelperAndroid(): Boolean = true
|
|
27
31
|
}
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* This source code is licensed under the MIT license found in the
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
|
-
* @generated SignedSource<<
|
|
7
|
+
* @generated SignedSource<<21704207ce520def05b05f89dfba1048>>
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -127,6 +127,10 @@ public interface ReactNativeFeatureFlagsProvider {
|
|
|
127
127
|
|
|
128
128
|
@DoNotStrip public fun useFabricInterop(): Boolean
|
|
129
129
|
|
|
130
|
+
@DoNotStrip public fun useNativeEqualsInNativeReadableArrayAndroid(): Boolean
|
|
131
|
+
|
|
132
|
+
@DoNotStrip public fun useNativeTransformHelperAndroid(): Boolean
|
|
133
|
+
|
|
130
134
|
@DoNotStrip public fun useNativeViewConfigsInBridgelessMode(): Boolean
|
|
131
135
|
|
|
132
136
|
@DoNotStrip public fun useOptimizedEventBatchingOnAndroid(): Boolean
|
|
@@ -8,10 +8,12 @@
|
|
|
8
8
|
package com.facebook.react.uimanager
|
|
9
9
|
|
|
10
10
|
import com.facebook.common.logging.FLog
|
|
11
|
+
import com.facebook.react.bridge.NativeArray
|
|
11
12
|
import com.facebook.react.bridge.ReadableArray
|
|
12
13
|
import com.facebook.react.bridge.ReadableMap
|
|
13
14
|
import com.facebook.react.bridge.ReadableType
|
|
14
15
|
import com.facebook.react.common.ReactConstants
|
|
16
|
+
import com.facebook.react.internal.featureflags.ReactNativeFeatureFlags
|
|
15
17
|
|
|
16
18
|
public object TransformHelper {
|
|
17
19
|
|
|
@@ -69,6 +71,14 @@ public object TransformHelper {
|
|
|
69
71
|
transformOrigin: ReadableArray?,
|
|
70
72
|
allowPercentageResolution: Boolean
|
|
71
73
|
) {
|
|
74
|
+
if (allowPercentageResolution &&
|
|
75
|
+
ReactNativeFeatureFlags.useNativeTransformHelperAndroid() &&
|
|
76
|
+
transforms is NativeArray &&
|
|
77
|
+
transformOrigin is NativeArray?) {
|
|
78
|
+
nativeProcessTransform(transforms, result, viewWidth, viewHeight, transformOrigin)
|
|
79
|
+
return
|
|
80
|
+
}
|
|
81
|
+
|
|
72
82
|
val helperMatrix = helperMatrix.get()!!
|
|
73
83
|
MatrixMathHelper.resetIdentityMatrix(result)
|
|
74
84
|
val offsets =
|
|
@@ -220,4 +230,13 @@ public object TransformHelper {
|
|
|
220
230
|
|
|
221
231
|
return doubleArrayOf(newTranslateX, newTranslateY, newTranslateZ)
|
|
222
232
|
}
|
|
233
|
+
|
|
234
|
+
@JvmStatic
|
|
235
|
+
private external fun nativeProcessTransform(
|
|
236
|
+
transforms: NativeArray,
|
|
237
|
+
result: DoubleArray,
|
|
238
|
+
viewWidth: Float,
|
|
239
|
+
viewHeight: Float,
|
|
240
|
+
transformOrigin: NativeArray?
|
|
241
|
+
)
|
|
223
242
|
}
|