mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Hook up CPP props parsing and Android ViewRecycling feature flags on Android
Summary: Hook up feature flags. Changelog: [Internal] Reviewed By: cortinico, ryancat Differential Revision: D37166366 fbshipit-source-id: 440acba9ee85a9ced64cd880d915044de7619584
This commit is contained in:
committed by
Facebook GitHub Bot
parent
63ddfa02ee
commit
577582e230
@@ -130,4 +130,9 @@ public class ReactFeatureFlags {
|
||||
* Feature Flag to enable View Recycling. When enabled, individual ViewManagers must still opt-in.
|
||||
*/
|
||||
public static boolean enableViewRecycling = false;
|
||||
|
||||
/**
|
||||
* Enable prop iterator setter-style construction of Props in C++ (this flag is not used in Java).
|
||||
*/
|
||||
public static boolean enableCppPropsIteratorSetter = false;
|
||||
}
|
||||
|
||||
@@ -32,6 +32,9 @@
|
||||
#include <react/renderer/uimanager/primitives.h>
|
||||
#include <react/utils/ContextContainer.h>
|
||||
|
||||
// Included to set BaseTextProps config; can be deleted later.
|
||||
#include <react/renderer/components/text/BaseTextProps.h>
|
||||
|
||||
#include <glog/logging.h>
|
||||
|
||||
using namespace facebook::jni;
|
||||
@@ -441,6 +444,13 @@ void Binding::installFabricUIManager(
|
||||
"EnableLargeTextMeasureCache",
|
||||
getFeatureFlagValue("enableLargeTextMeasureCache"));
|
||||
|
||||
// Props setter pattern feature
|
||||
Props::enablePropIteratorSetter =
|
||||
getFeatureFlagValue("enableCppPropsIteratorSetter");
|
||||
AccessibilityProps::enablePropIteratorSetter =
|
||||
Props::enablePropIteratorSetter;
|
||||
BaseTextProps::enablePropIteratorSetter = Props::enablePropIteratorSetter;
|
||||
|
||||
auto toolbox = SchedulerToolbox{};
|
||||
toolbox.contextContainer = contextContainer;
|
||||
toolbox.componentRegistryFactory = componentsRegistry->buildRegistryFunction;
|
||||
|
||||
Reference in New Issue
Block a user