mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-08 22:42:05 +08:00
Turn FlatViewManager into ViewGroupManager
Summary: Views that can contain other Views need to have their ViewManager to extend ViewGroupManager. Otherwise, it may not remove child Views correctly when a parent View is being detached. This diff is changing FlatViewManager that create FlatViewGroups (that can have child Views) to extend from ViewGroupManager. Reviewed By: ahmedre Differential Revision: D2768667
This commit is contained in:
committed by
Ahmed El-Helw
parent
94052261d1
commit
85cdfcd1f7
@@ -10,9 +10,9 @@
|
||||
package com.facebook.react.flat;
|
||||
|
||||
import com.facebook.react.uimanager.ThemedReactContext;
|
||||
import com.facebook.react.uimanager.BaseViewManager;
|
||||
import com.facebook.react.uimanager.ViewGroupManager;
|
||||
|
||||
abstract class FlatViewManager<C extends FlatShadowNode> extends BaseViewManager<FlatViewGroup, C> {
|
||||
abstract class FlatViewManager extends ViewGroupManager<FlatViewGroup> {
|
||||
|
||||
@Override
|
||||
protected FlatViewGroup createViewInstance(ThemedReactContext reactContext) {
|
||||
@@ -23,8 +23,4 @@ abstract class FlatViewManager<C extends FlatShadowNode> extends BaseViewManager
|
||||
public void setBackgroundColor(FlatViewGroup view, int backgroundColor) {
|
||||
// suppress
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateExtraData(FlatViewGroup root, Object extraData) {
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user