mirror of
https://github.com/facebook/react-native.git
synced 2026-11-18 20:19:07 +00:00
Remove shouldResetClickableWhenRecyclingView feature flag (#55106)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/55106 Changelog: [Android][Fixed] - Reset isClickable to false when recycling views to avoid accessibility tools finding views with incorrect state --- This diff removes the `shouldResetClickableWhenRecyclingView` feature flag since it has been tested in FB4A for a month with `defaultValue: true`. The flag was introduced to reset `isClickable` to false when recycling views on Android to avoid accessibility tools finding views with incorrect state after recycling. This behavior is now the default. Changes: - Removed the flag definition from `ReactNativeFeatureFlags.config.js` - Removed the conditional check in `BaseViewManager.java`, now `view.setClickable(false)` is always called unconditionally - Regenerated all feature flag files via `js1 featureflags --update` Reviewed By: javache Differential Revision: D90380899 fbshipit-source-id: df604556d3b1f6c108c4defe343f1ab6683f0ce0
This commit is contained in:
1 parent
20319bd5eb
commit
07c0539cb8
21 files changed
+37
-155
No files matched your search
+1
-7
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<b9a49024788f6d78e8bce1d8d7a00f16>>
|
||||
* @generated SignedSource<<01a8372ee4b908995e2c70eb7a972a39>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -414,12 +414,6 @@ public object ReactNativeFeatureFlags {
|
||||
@JvmStatic
|
||||
public fun shouldPressibilityUseW3CPointerEventsForHover(): Boolean = accessor.shouldPressibilityUseW3CPointerEventsForHover()
|
||||
|
||||
/**
|
||||
* Reset isClickable to false when recycling views on Android to avoid accessibility tools finding views with incorrect state after recycling.
|
||||
*/
|
||||
@JvmStatic
|
||||
public fun shouldResetClickableWhenRecyclingView(): Boolean = accessor.shouldResetClickableWhenRecyclingView()
|
||||
|
||||
/**
|
||||
* Reset OnClickListener to null when recycling views on Android to avoid accessibility tools finding views with incorrect state after recycling.
|
||||
*/
|
||||
|
||||
+1
-11
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<a45409be422bc544a43295eb4fe21074>>
|
||||
* @generated SignedSource<<397c978a91e1815389ce7162d7ce0181>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -84,7 +84,6 @@ internal class ReactNativeFeatureFlagsCxxAccessor : ReactNativeFeatureFlagsAcces
|
||||
private var preparedTextCacheSizeCache: Double? = null
|
||||
private var preventShadowTreeCommitExhaustionCache: Boolean? = null
|
||||
private var shouldPressibilityUseW3CPointerEventsForHoverCache: Boolean? = null
|
||||
private var shouldResetClickableWhenRecyclingViewCache: Boolean? = null
|
||||
private var shouldResetOnClickListenerWhenRecyclingViewCache: Boolean? = null
|
||||
private var shouldSetEnabledBasedOnAccessibilityStateCache: Boolean? = null
|
||||
private var shouldTriggerResponderTransferOnScrollAndroidCache: Boolean? = null
|
||||
@@ -678,15 +677,6 @@ internal class ReactNativeFeatureFlagsCxxAccessor : ReactNativeFeatureFlagsAcces
|
||||
return cached
|
||||
}
|
||||
|
||||
override fun shouldResetClickableWhenRecyclingView(): Boolean {
|
||||
var cached = shouldResetClickableWhenRecyclingViewCache
|
||||
if (cached == null) {
|
||||
cached = ReactNativeFeatureFlagsCxxInterop.shouldResetClickableWhenRecyclingView()
|
||||
shouldResetClickableWhenRecyclingViewCache = cached
|
||||
}
|
||||
return cached
|
||||
}
|
||||
|
||||
override fun shouldResetOnClickListenerWhenRecyclingView(): Boolean {
|
||||
var cached = shouldResetOnClickListenerWhenRecyclingViewCache
|
||||
if (cached == null) {
|
||||
|
||||
+1
-3
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<645d8233955b21a3b2d4e822976abd35>>
|
||||
* @generated SignedSource<<4f4cfab3f3d91fba4ea661a17dca0cb9>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -156,8 +156,6 @@ public object ReactNativeFeatureFlagsCxxInterop {
|
||||
|
||||
@DoNotStrip @JvmStatic public external fun shouldPressibilityUseW3CPointerEventsForHover(): Boolean
|
||||
|
||||
@DoNotStrip @JvmStatic public external fun shouldResetClickableWhenRecyclingView(): Boolean
|
||||
|
||||
@DoNotStrip @JvmStatic public external fun shouldResetOnClickListenerWhenRecyclingView(): Boolean
|
||||
|
||||
@DoNotStrip @JvmStatic public external fun shouldSetEnabledBasedOnAccessibilityState(): Boolean
|
||||
|
||||
+1
-3
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<d08d1352bfe98e3e84e58ab9ad2e70c6>>
|
||||
* @generated SignedSource<<c6f0c4d72a9ef24f5352976996a5e300>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -151,8 +151,6 @@ public open class ReactNativeFeatureFlagsDefaults : ReactNativeFeatureFlagsProvi
|
||||
|
||||
override fun shouldPressibilityUseW3CPointerEventsForHover(): Boolean = false
|
||||
|
||||
override fun shouldResetClickableWhenRecyclingView(): Boolean = true
|
||||
|
||||
override fun shouldResetOnClickListenerWhenRecyclingView(): Boolean = true
|
||||
|
||||
override fun shouldSetEnabledBasedOnAccessibilityState(): Boolean = true
|
||||
|
||||
+1
-12
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<5ad99dd8a367e7f12d68c9ef1a52cb56>>
|
||||
* @generated SignedSource<<77669091f5fbd91a7be1693375163c0c>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -88,7 +88,6 @@ internal class ReactNativeFeatureFlagsLocalAccessor : ReactNativeFeatureFlagsAcc
|
||||
private var preparedTextCacheSizeCache: Double? = null
|
||||
private var preventShadowTreeCommitExhaustionCache: Boolean? = null
|
||||
private var shouldPressibilityUseW3CPointerEventsForHoverCache: Boolean? = null
|
||||
private var shouldResetClickableWhenRecyclingViewCache: Boolean? = null
|
||||
private var shouldResetOnClickListenerWhenRecyclingViewCache: Boolean? = null
|
||||
private var shouldSetEnabledBasedOnAccessibilityStateCache: Boolean? = null
|
||||
private var shouldTriggerResponderTransferOnScrollAndroidCache: Boolean? = null
|
||||
@@ -746,16 +745,6 @@ internal class ReactNativeFeatureFlagsLocalAccessor : ReactNativeFeatureFlagsAcc
|
||||
return cached
|
||||
}
|
||||
|
||||
override fun shouldResetClickableWhenRecyclingView(): Boolean {
|
||||
var cached = shouldResetClickableWhenRecyclingViewCache
|
||||
if (cached == null) {
|
||||
cached = currentProvider.shouldResetClickableWhenRecyclingView()
|
||||
accessedFeatureFlags.add("shouldResetClickableWhenRecyclingView")
|
||||
shouldResetClickableWhenRecyclingViewCache = cached
|
||||
}
|
||||
return cached
|
||||
}
|
||||
|
||||
override fun shouldResetOnClickListenerWhenRecyclingView(): Boolean {
|
||||
var cached = shouldResetOnClickListenerWhenRecyclingViewCache
|
||||
if (cached == null) {
|
||||
|
||||
+1
-3
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<98babc53e50f8ec8b9e324727ed3734b>>
|
||||
* @generated SignedSource<<da8de211c4b7837291853f9b79d2f8e5>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -151,8 +151,6 @@ public interface ReactNativeFeatureFlagsProvider {
|
||||
|
||||
@DoNotStrip public fun shouldPressibilityUseW3CPointerEventsForHover(): Boolean
|
||||
|
||||
@DoNotStrip public fun shouldResetClickableWhenRecyclingView(): Boolean
|
||||
|
||||
@DoNotStrip public fun shouldResetOnClickListenerWhenRecyclingView(): Boolean
|
||||
|
||||
@DoNotStrip public fun shouldSetEnabledBasedOnAccessibilityState(): Boolean
|
||||
|
||||
+1
-3
@@ -154,9 +154,7 @@ public abstract class BaseViewManager<T extends View, C extends LayoutShadowNode
|
||||
if (ReactNativeFeatureFlags.shouldResetOnClickListenerWhenRecyclingView()) {
|
||||
view.setOnClickListener(null);
|
||||
}
|
||||
if (ReactNativeFeatureFlags.shouldResetClickableWhenRecyclingView()) {
|
||||
view.setClickable(false);
|
||||
}
|
||||
view.setClickable(false);
|
||||
view.setFocusable(false);
|
||||
view.setFocusableInTouchMode(false);
|
||||
|
||||
|
||||
+1
-15
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<3369c6073006f4dddb297f86f413363f>>
|
||||
* @generated SignedSource<<212a64efdf912e89b8330b292a8bccb5>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -423,12 +423,6 @@ class ReactNativeFeatureFlagsJavaProvider
|
||||
return method(javaProvider_);
|
||||
}
|
||||
|
||||
bool shouldResetClickableWhenRecyclingView() override {
|
||||
static const auto method =
|
||||
getReactNativeFeatureFlagsProviderJavaClass()->getMethod<jboolean()>("shouldResetClickableWhenRecyclingView");
|
||||
return method(javaProvider_);
|
||||
}
|
||||
|
||||
bool shouldResetOnClickListenerWhenRecyclingView() override {
|
||||
static const auto method =
|
||||
getReactNativeFeatureFlagsProviderJavaClass()->getMethod<jboolean()>("shouldResetOnClickListenerWhenRecyclingView");
|
||||
@@ -849,11 +843,6 @@ bool JReactNativeFeatureFlagsCxxInterop::shouldPressibilityUseW3CPointerEventsFo
|
||||
return ReactNativeFeatureFlags::shouldPressibilityUseW3CPointerEventsForHover();
|
||||
}
|
||||
|
||||
bool JReactNativeFeatureFlagsCxxInterop::shouldResetClickableWhenRecyclingView(
|
||||
facebook::jni::alias_ref<JReactNativeFeatureFlagsCxxInterop> /*unused*/) {
|
||||
return ReactNativeFeatureFlags::shouldResetClickableWhenRecyclingView();
|
||||
}
|
||||
|
||||
bool JReactNativeFeatureFlagsCxxInterop::shouldResetOnClickListenerWhenRecyclingView(
|
||||
facebook::jni::alias_ref<JReactNativeFeatureFlagsCxxInterop> /*unused*/) {
|
||||
return ReactNativeFeatureFlags::shouldResetOnClickListenerWhenRecyclingView();
|
||||
@@ -1157,9 +1146,6 @@ void JReactNativeFeatureFlagsCxxInterop::registerNatives() {
|
||||
makeNativeMethod(
|
||||
"shouldPressibilityUseW3CPointerEventsForHover",
|
||||
JReactNativeFeatureFlagsCxxInterop::shouldPressibilityUseW3CPointerEventsForHover),
|
||||
makeNativeMethod(
|
||||
"shouldResetClickableWhenRecyclingView",
|
||||
JReactNativeFeatureFlagsCxxInterop::shouldResetClickableWhenRecyclingView),
|
||||
makeNativeMethod(
|
||||
"shouldResetOnClickListenerWhenRecyclingView",
|
||||
JReactNativeFeatureFlagsCxxInterop::shouldResetOnClickListenerWhenRecyclingView),
|
||||
|
||||
+1
-4
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<818d29b2da08e64cec4d20e4b541b7cc>>
|
||||
* @generated SignedSource<<010228a95e878a109f1aa3d13a0c7606>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -222,9 +222,6 @@ class JReactNativeFeatureFlagsCxxInterop
|
||||
static bool shouldPressibilityUseW3CPointerEventsForHover(
|
||||
facebook::jni::alias_ref<JReactNativeFeatureFlagsCxxInterop>);
|
||||
|
||||
static bool shouldResetClickableWhenRecyclingView(
|
||||
facebook::jni::alias_ref<JReactNativeFeatureFlagsCxxInterop>);
|
||||
|
||||
static bool shouldResetOnClickListenerWhenRecyclingView(
|
||||
facebook::jni::alias_ref<JReactNativeFeatureFlagsCxxInterop>);
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<97daf46fe8af38d7af4b7241d1d3bc4e>>
|
||||
* @generated SignedSource<<8fa338ec73fcb7af019d877fd949543a>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -282,10 +282,6 @@ bool ReactNativeFeatureFlags::shouldPressibilityUseW3CPointerEventsForHover() {
|
||||
return getAccessor().shouldPressibilityUseW3CPointerEventsForHover();
|
||||
}
|
||||
|
||||
bool ReactNativeFeatureFlags::shouldResetClickableWhenRecyclingView() {
|
||||
return getAccessor().shouldResetClickableWhenRecyclingView();
|
||||
}
|
||||
|
||||
bool ReactNativeFeatureFlags::shouldResetOnClickListenerWhenRecyclingView() {
|
||||
return getAccessor().shouldResetOnClickListenerWhenRecyclingView();
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<4f7b218e3a60fd7877e46f04e9c084eb>>
|
||||
* @generated SignedSource<<b05e1657341801ec03c9f060f4015c0f>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -359,11 +359,6 @@ class ReactNativeFeatureFlags {
|
||||
*/
|
||||
RN_EXPORT static bool shouldPressibilityUseW3CPointerEventsForHover();
|
||||
|
||||
/**
|
||||
* Reset isClickable to false when recycling views on Android to avoid accessibility tools finding views with incorrect state after recycling.
|
||||
*/
|
||||
RN_EXPORT static bool shouldResetClickableWhenRecyclingView();
|
||||
|
||||
/**
|
||||
* Reset OnClickListener to null when recycling views on Android to avoid accessibility tools finding views with incorrect state after recycling.
|
||||
*/
|
||||
|
||||
+17
-35
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<57853bc021f127387c7435a88a857c2b>>
|
||||
* @generated SignedSource<<07ae9ccc85bb268bb3d06a71f63deca7>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -1181,24 +1181,6 @@ bool ReactNativeFeatureFlagsAccessor::shouldPressibilityUseW3CPointerEventsForHo
|
||||
return flagValue.value();
|
||||
}
|
||||
|
||||
bool ReactNativeFeatureFlagsAccessor::shouldResetClickableWhenRecyclingView() {
|
||||
auto flagValue = shouldResetClickableWhenRecyclingView_.load();
|
||||
|
||||
if (!flagValue.has_value()) {
|
||||
// This block is not exclusive but it is not necessary.
|
||||
// If multiple threads try to initialize the feature flag, we would only
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(64, "shouldResetClickableWhenRecyclingView");
|
||||
|
||||
flagValue = currentProvider_->shouldResetClickableWhenRecyclingView();
|
||||
shouldResetClickableWhenRecyclingView_ = flagValue;
|
||||
}
|
||||
|
||||
return flagValue.value();
|
||||
}
|
||||
|
||||
bool ReactNativeFeatureFlagsAccessor::shouldResetOnClickListenerWhenRecyclingView() {
|
||||
auto flagValue = shouldResetOnClickListenerWhenRecyclingView_.load();
|
||||
|
||||
@@ -1208,7 +1190,7 @@ bool ReactNativeFeatureFlagsAccessor::shouldResetOnClickListenerWhenRecyclingVie
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(65, "shouldResetOnClickListenerWhenRecyclingView");
|
||||
markFlagAsAccessed(64, "shouldResetOnClickListenerWhenRecyclingView");
|
||||
|
||||
flagValue = currentProvider_->shouldResetOnClickListenerWhenRecyclingView();
|
||||
shouldResetOnClickListenerWhenRecyclingView_ = flagValue;
|
||||
@@ -1226,7 +1208,7 @@ bool ReactNativeFeatureFlagsAccessor::shouldSetEnabledBasedOnAccessibilityState(
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(66, "shouldSetEnabledBasedOnAccessibilityState");
|
||||
markFlagAsAccessed(65, "shouldSetEnabledBasedOnAccessibilityState");
|
||||
|
||||
flagValue = currentProvider_->shouldSetEnabledBasedOnAccessibilityState();
|
||||
shouldSetEnabledBasedOnAccessibilityState_ = flagValue;
|
||||
@@ -1244,7 +1226,7 @@ bool ReactNativeFeatureFlagsAccessor::shouldTriggerResponderTransferOnScrollAndr
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(67, "shouldTriggerResponderTransferOnScrollAndroid");
|
||||
markFlagAsAccessed(66, "shouldTriggerResponderTransferOnScrollAndroid");
|
||||
|
||||
flagValue = currentProvider_->shouldTriggerResponderTransferOnScrollAndroid();
|
||||
shouldTriggerResponderTransferOnScrollAndroid_ = flagValue;
|
||||
@@ -1262,7 +1244,7 @@ bool ReactNativeFeatureFlagsAccessor::skipActivityIdentityAssertionOnHostPause()
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(68, "skipActivityIdentityAssertionOnHostPause");
|
||||
markFlagAsAccessed(67, "skipActivityIdentityAssertionOnHostPause");
|
||||
|
||||
flagValue = currentProvider_->skipActivityIdentityAssertionOnHostPause();
|
||||
skipActivityIdentityAssertionOnHostPause_ = flagValue;
|
||||
@@ -1280,7 +1262,7 @@ bool ReactNativeFeatureFlagsAccessor::traceTurboModulePromiseRejectionsOnAndroid
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(69, "traceTurboModulePromiseRejectionsOnAndroid");
|
||||
markFlagAsAccessed(68, "traceTurboModulePromiseRejectionsOnAndroid");
|
||||
|
||||
flagValue = currentProvider_->traceTurboModulePromiseRejectionsOnAndroid();
|
||||
traceTurboModulePromiseRejectionsOnAndroid_ = flagValue;
|
||||
@@ -1298,7 +1280,7 @@ bool ReactNativeFeatureFlagsAccessor::updateRuntimeShadowNodeReferencesOnCommit(
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(70, "updateRuntimeShadowNodeReferencesOnCommit");
|
||||
markFlagAsAccessed(69, "updateRuntimeShadowNodeReferencesOnCommit");
|
||||
|
||||
flagValue = currentProvider_->updateRuntimeShadowNodeReferencesOnCommit();
|
||||
updateRuntimeShadowNodeReferencesOnCommit_ = flagValue;
|
||||
@@ -1316,7 +1298,7 @@ bool ReactNativeFeatureFlagsAccessor::useAlwaysAvailableJSErrorHandling() {
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(71, "useAlwaysAvailableJSErrorHandling");
|
||||
markFlagAsAccessed(70, "useAlwaysAvailableJSErrorHandling");
|
||||
|
||||
flagValue = currentProvider_->useAlwaysAvailableJSErrorHandling();
|
||||
useAlwaysAvailableJSErrorHandling_ = flagValue;
|
||||
@@ -1334,7 +1316,7 @@ bool ReactNativeFeatureFlagsAccessor::useFabricInterop() {
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(72, "useFabricInterop");
|
||||
markFlagAsAccessed(71, "useFabricInterop");
|
||||
|
||||
flagValue = currentProvider_->useFabricInterop();
|
||||
useFabricInterop_ = flagValue;
|
||||
@@ -1352,7 +1334,7 @@ bool ReactNativeFeatureFlagsAccessor::useNativeViewConfigsInBridgelessMode() {
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(73, "useNativeViewConfigsInBridgelessMode");
|
||||
markFlagAsAccessed(72, "useNativeViewConfigsInBridgelessMode");
|
||||
|
||||
flagValue = currentProvider_->useNativeViewConfigsInBridgelessMode();
|
||||
useNativeViewConfigsInBridgelessMode_ = flagValue;
|
||||
@@ -1370,7 +1352,7 @@ bool ReactNativeFeatureFlagsAccessor::useShadowNodeStateOnClone() {
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(74, "useShadowNodeStateOnClone");
|
||||
markFlagAsAccessed(73, "useShadowNodeStateOnClone");
|
||||
|
||||
flagValue = currentProvider_->useShadowNodeStateOnClone();
|
||||
useShadowNodeStateOnClone_ = flagValue;
|
||||
@@ -1388,7 +1370,7 @@ bool ReactNativeFeatureFlagsAccessor::useSharedAnimatedBackend() {
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(75, "useSharedAnimatedBackend");
|
||||
markFlagAsAccessed(74, "useSharedAnimatedBackend");
|
||||
|
||||
flagValue = currentProvider_->useSharedAnimatedBackend();
|
||||
useSharedAnimatedBackend_ = flagValue;
|
||||
@@ -1406,7 +1388,7 @@ bool ReactNativeFeatureFlagsAccessor::useTraitHiddenOnAndroid() {
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(76, "useTraitHiddenOnAndroid");
|
||||
markFlagAsAccessed(75, "useTraitHiddenOnAndroid");
|
||||
|
||||
flagValue = currentProvider_->useTraitHiddenOnAndroid();
|
||||
useTraitHiddenOnAndroid_ = flagValue;
|
||||
@@ -1424,7 +1406,7 @@ bool ReactNativeFeatureFlagsAccessor::useTurboModuleInterop() {
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(77, "useTurboModuleInterop");
|
||||
markFlagAsAccessed(76, "useTurboModuleInterop");
|
||||
|
||||
flagValue = currentProvider_->useTurboModuleInterop();
|
||||
useTurboModuleInterop_ = flagValue;
|
||||
@@ -1442,7 +1424,7 @@ bool ReactNativeFeatureFlagsAccessor::useTurboModules() {
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(78, "useTurboModules");
|
||||
markFlagAsAccessed(77, "useTurboModules");
|
||||
|
||||
flagValue = currentProvider_->useTurboModules();
|
||||
useTurboModules_ = flagValue;
|
||||
@@ -1460,7 +1442,7 @@ double ReactNativeFeatureFlagsAccessor::viewCullingOutsetRatio() {
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(79, "viewCullingOutsetRatio");
|
||||
markFlagAsAccessed(78, "viewCullingOutsetRatio");
|
||||
|
||||
flagValue = currentProvider_->viewCullingOutsetRatio();
|
||||
viewCullingOutsetRatio_ = flagValue;
|
||||
@@ -1478,7 +1460,7 @@ double ReactNativeFeatureFlagsAccessor::virtualViewPrerenderRatio() {
|
||||
// be accessing the provider multiple times but the end state of this
|
||||
// instance and the returned flag value would be the same.
|
||||
|
||||
markFlagAsAccessed(80, "virtualViewPrerenderRatio");
|
||||
markFlagAsAccessed(79, "virtualViewPrerenderRatio");
|
||||
|
||||
flagValue = currentProvider_->virtualViewPrerenderRatio();
|
||||
virtualViewPrerenderRatio_ = flagValue;
|
||||
|
||||
+2
-4
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<f3ef67fea2e13d76fa9a1c80175e2409>>
|
||||
* @generated SignedSource<<7415ff393e743bd3360bd51d169d490c>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -96,7 +96,6 @@ class ReactNativeFeatureFlagsAccessor {
|
||||
double preparedTextCacheSize();
|
||||
bool preventShadowTreeCommitExhaustion();
|
||||
bool shouldPressibilityUseW3CPointerEventsForHover();
|
||||
bool shouldResetClickableWhenRecyclingView();
|
||||
bool shouldResetOnClickListenerWhenRecyclingView();
|
||||
bool shouldSetEnabledBasedOnAccessibilityState();
|
||||
bool shouldTriggerResponderTransferOnScrollAndroid();
|
||||
@@ -124,7 +123,7 @@ class ReactNativeFeatureFlagsAccessor {
|
||||
std::unique_ptr<ReactNativeFeatureFlagsProvider> currentProvider_;
|
||||
bool wasOverridden_;
|
||||
|
||||
std::array<std::atomic<const char*>, 81> accessedFeatureFlags_;
|
||||
std::array<std::atomic<const char*>, 80> accessedFeatureFlags_;
|
||||
|
||||
std::atomic<std::optional<bool>> commonTestFlag_;
|
||||
std::atomic<std::optional<bool>> cdpInteractionMetricsEnabled_;
|
||||
@@ -190,7 +189,6 @@ class ReactNativeFeatureFlagsAccessor {
|
||||
std::atomic<std::optional<double>> preparedTextCacheSize_;
|
||||
std::atomic<std::optional<bool>> preventShadowTreeCommitExhaustion_;
|
||||
std::atomic<std::optional<bool>> shouldPressibilityUseW3CPointerEventsForHover_;
|
||||
std::atomic<std::optional<bool>> shouldResetClickableWhenRecyclingView_;
|
||||
std::atomic<std::optional<bool>> shouldResetOnClickListenerWhenRecyclingView_;
|
||||
std::atomic<std::optional<bool>> shouldSetEnabledBasedOnAccessibilityState_;
|
||||
std::atomic<std::optional<bool>> shouldTriggerResponderTransferOnScrollAndroid_;
|
||||
|
||||
+1
-5
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<78c9750f16721340f8a73b711bbdd1d5>>
|
||||
* @generated SignedSource<<8bbb8ef8febaca4e72f6c15af0144616>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -283,10 +283,6 @@ class ReactNativeFeatureFlagsDefaults : public ReactNativeFeatureFlagsProvider {
|
||||
return false;
|
||||
}
|
||||
|
||||
bool shouldResetClickableWhenRecyclingView() override {
|
||||
return true;
|
||||
}
|
||||
|
||||
bool shouldResetOnClickListenerWhenRecyclingView() override {
|
||||
return true;
|
||||
}
|
||||
|
||||
+1
-10
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<434ae55a782eecd9fa3540c38c63b2f5>>
|
||||
* @generated SignedSource<<870178cd77459f3cb8ebb75683584f3e>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -621,15 +621,6 @@ class ReactNativeFeatureFlagsDynamicProvider : public ReactNativeFeatureFlagsDef
|
||||
return ReactNativeFeatureFlagsDefaults::shouldPressibilityUseW3CPointerEventsForHover();
|
||||
}
|
||||
|
||||
bool shouldResetClickableWhenRecyclingView() override {
|
||||
auto value = values_["shouldResetClickableWhenRecyclingView"];
|
||||
if (!value.isNull()) {
|
||||
return value.getBool();
|
||||
}
|
||||
|
||||
return ReactNativeFeatureFlagsDefaults::shouldResetClickableWhenRecyclingView();
|
||||
}
|
||||
|
||||
bool shouldResetOnClickListenerWhenRecyclingView() override {
|
||||
auto value = values_["shouldResetOnClickListenerWhenRecyclingView"];
|
||||
if (!value.isNull()) {
|
||||
|
||||
+1
-2
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<aad5f9fdfcebfdbc8a0a5235c02dfc18>>
|
||||
* @generated SignedSource<<52a45aa96ee016dbc229325711e018dd>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -89,7 +89,6 @@ class ReactNativeFeatureFlagsProvider {
|
||||
virtual double preparedTextCacheSize() = 0;
|
||||
virtual bool preventShadowTreeCommitExhaustion() = 0;
|
||||
virtual bool shouldPressibilityUseW3CPointerEventsForHover() = 0;
|
||||
virtual bool shouldResetClickableWhenRecyclingView() = 0;
|
||||
virtual bool shouldResetOnClickListenerWhenRecyclingView() = 0;
|
||||
virtual bool shouldSetEnabledBasedOnAccessibilityState() = 0;
|
||||
virtual bool shouldTriggerResponderTransferOnScrollAndroid() = 0;
|
||||
|
||||
+1
-6
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<d7a2b793416ce4bd933ebe59ac540c1c>>
|
||||
* @generated SignedSource<<f66847ab3dab07d8cbd2caa21deb69f1>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -364,11 +364,6 @@ bool NativeReactNativeFeatureFlags::shouldPressibilityUseW3CPointerEventsForHove
|
||||
return ReactNativeFeatureFlags::shouldPressibilityUseW3CPointerEventsForHover();
|
||||
}
|
||||
|
||||
bool NativeReactNativeFeatureFlags::shouldResetClickableWhenRecyclingView(
|
||||
jsi::Runtime& /*runtime*/) {
|
||||
return ReactNativeFeatureFlags::shouldResetClickableWhenRecyclingView();
|
||||
}
|
||||
|
||||
bool NativeReactNativeFeatureFlags::shouldResetOnClickListenerWhenRecyclingView(
|
||||
jsi::Runtime& /*runtime*/) {
|
||||
return ReactNativeFeatureFlags::shouldResetOnClickListenerWhenRecyclingView();
|
||||
|
||||
+1
-3
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<52f15288cfcd99ac5bf23bd69269a575>>
|
||||
* @generated SignedSource<<14a066fb4e2b8eaa47642dd5b28eee52>>
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -164,8 +164,6 @@ class NativeReactNativeFeatureFlags
|
||||
|
||||
bool shouldPressibilityUseW3CPointerEventsForHover(jsi::Runtime& runtime);
|
||||
|
||||
bool shouldResetClickableWhenRecyclingView(jsi::Runtime& runtime);
|
||||
|
||||
bool shouldResetOnClickListenerWhenRecyclingView(jsi::Runtime& runtime);
|
||||
|
||||
bool shouldSetEnabledBasedOnAccessibilityState(jsi::Runtime& runtime);
|
||||
|
||||
@@ -732,16 +732,6 @@ const definitions: FeatureFlagDefinitions = {
|
||||
},
|
||||
ossReleaseStage: 'none',
|
||||
},
|
||||
shouldResetClickableWhenRecyclingView: {
|
||||
defaultValue: true,
|
||||
metadata: {
|
||||
description:
|
||||
'Reset isClickable to false when recycling views on Android to avoid accessibility tools finding views with incorrect state after recycling.',
|
||||
expectedReleaseValue: true,
|
||||
purpose: 'release',
|
||||
},
|
||||
ossReleaseStage: 'none',
|
||||
},
|
||||
shouldResetOnClickListenerWhenRecyclingView: {
|
||||
defaultValue: true,
|
||||
metadata: {
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<f0f6e99458ad95cb0dae170729fc77ca>>
|
||||
* @generated SignedSource<<2b443dd011edd5602a9ea5004f5f9a36>>
|
||||
* @flow strict
|
||||
* @noformat
|
||||
*/
|
||||
@@ -112,7 +112,6 @@ export type ReactNativeFeatureFlags = $ReadOnly<{
|
||||
preparedTextCacheSize: Getter<number>,
|
||||
preventShadowTreeCommitExhaustion: Getter<boolean>,
|
||||
shouldPressibilityUseW3CPointerEventsForHover: Getter<boolean>,
|
||||
shouldResetClickableWhenRecyclingView: Getter<boolean>,
|
||||
shouldResetOnClickListenerWhenRecyclingView: Getter<boolean>,
|
||||
shouldSetEnabledBasedOnAccessibilityState: Getter<boolean>,
|
||||
shouldTriggerResponderTransferOnScrollAndroid: Getter<boolean>,
|
||||
@@ -456,10 +455,6 @@ export const preventShadowTreeCommitExhaustion: Getter<boolean> = createNativeFl
|
||||
* Function used to enable / disable Pressibility from using W3C Pointer Events for its hover callbacks
|
||||
*/
|
||||
export const shouldPressibilityUseW3CPointerEventsForHover: Getter<boolean> = createNativeFlagGetter('shouldPressibilityUseW3CPointerEventsForHover', false);
|
||||
/**
|
||||
* Reset isClickable to false when recycling views on Android to avoid accessibility tools finding views with incorrect state after recycling.
|
||||
*/
|
||||
export const shouldResetClickableWhenRecyclingView: Getter<boolean> = createNativeFlagGetter('shouldResetClickableWhenRecyclingView', true);
|
||||
/**
|
||||
* Reset OnClickListener to null when recycling views on Android to avoid accessibility tools finding views with incorrect state after recycling.
|
||||
*/
|
||||
|
||||
+1
-2
@@ -4,7 +4,7 @@
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @generated SignedSource<<d380339fa9dc97085e92c4c5a9c8a1d4>>
|
||||
* @generated SignedSource<<b53ea82f948562fd0c5ee057665ce51a>>
|
||||
* @flow strict
|
||||
* @noformat
|
||||
*/
|
||||
@@ -89,7 +89,6 @@ export interface Spec extends TurboModule {
|
||||
+preparedTextCacheSize?: () => number;
|
||||
+preventShadowTreeCommitExhaustion?: () => boolean;
|
||||
+shouldPressibilityUseW3CPointerEventsForHover?: () => boolean;
|
||||
+shouldResetClickableWhenRecyclingView?: () => boolean;
|
||||
+shouldResetOnClickListenerWhenRecyclingView?: () => boolean;
|
||||
+shouldSetEnabledBasedOnAccessibilityState?: () => boolean;
|
||||
+shouldTriggerResponderTransferOnScrollAndroid?: () => boolean;
|
||||
|
||||
Reference in new issue
Block a user