mirror of
https://github.com/status-im/react-native.git
synced 2025-02-26 16:10:58 +00:00
Litho UIImplementation
Reviewed By: marco-cova Differential Revision: D5880274 fbshipit-source-id: e6741579d3de6090dea8d26cd07241d57adba84d
This commit is contained in:
parent
d07279c978
commit
7677af1d10
@ -11,14 +11,13 @@ package com.facebook.react.uimanager;
|
||||
|
||||
import android.util.SparseArray;
|
||||
import android.util.SparseBooleanArray;
|
||||
|
||||
import com.facebook.react.common.SingleThreadAsserter;
|
||||
|
||||
/**
|
||||
* Simple container class to keep track of {@link ReactShadowNode}s associated with a particular
|
||||
* UIManagerModule instance.
|
||||
*/
|
||||
/*package*/ class ShadowNodeRegistry {
|
||||
public class ShadowNodeRegistry {
|
||||
|
||||
private final SparseArray<ReactShadowNode> mTagsToCSSNodes;
|
||||
private final SparseBooleanArray mRootTags;
|
||||
|
@ -44,14 +44,14 @@ import javax.annotation.Nullable;
|
||||
*/
|
||||
public class UIImplementation {
|
||||
|
||||
protected final EventDispatcher mEventDispatcher;
|
||||
protected final ReactApplicationContext mReactContext;
|
||||
protected final ShadowNodeRegistry mShadowNodeRegistry = new ShadowNodeRegistry();
|
||||
private final Set<Integer> mMeasuredRootNodes = new HashSet<>();
|
||||
private final ShadowNodeRegistry mShadowNodeRegistry = new ShadowNodeRegistry();
|
||||
private final ViewManagerRegistry mViewManagers;
|
||||
private final UIViewOperationQueue mOperationsQueue;
|
||||
private final NativeViewHierarchyOptimizer mNativeViewHierarchyOptimizer;
|
||||
private final int[] mMeasureBuffer = new int[4];
|
||||
private final ReactApplicationContext mReactContext;
|
||||
protected final EventDispatcher mEventDispatcher;
|
||||
|
||||
private long mLastCalculateLayoutTime = 0;
|
||||
|
||||
|
@ -330,8 +330,10 @@ import javax.annotation.Nullable;
|
||||
*/
|
||||
/*package*/ static Map<String, PropSetter> getNativePropSettersForShadowNodeClass(
|
||||
Class<? extends ReactShadowNode> cls) {
|
||||
if (cls == ReactShadowNodeImpl.class) {
|
||||
return EMPTY_PROPS_MAP;
|
||||
for (Class iface : cls.getInterfaces()) {
|
||||
if (iface == ReactShadowNode.class) {
|
||||
return EMPTY_PROPS_MAP;
|
||||
}
|
||||
}
|
||||
Map<String, PropSetter> props = CLASS_PROPS_CACHE.get(cls);
|
||||
if (props != null) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user