Use cached react tag versus id on view

Summary: Due to the way (initial) surface implementation plays with ReactRootView (RRV), the react tag from the UIManagerModule is now set on the surface container view rather than on RRV as it was historically done. RRV still caches the react tag but just doesn't use it as an id on the view so `RRV.getViewId()` no longer equals `RRV.getReactTag()`.

Reviewed By: mdvacca

Differential Revision: D14110104

fbshipit-source-id: 6dbcc41c85fd7a6c32c7250f68f4a84bed4e075a
This commit is contained in:
Luna Wei 2019-02-25 17:20:41 -08:00 коммит произвёл Facebook Github Bot
Родитель 19765c9b8c
Коммит 4cf70306b9
1 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -1075,10 +1075,10 @@ public class ReactInstanceManager {
UiThreadUtil.assertOnUiThread();
if (rootView.getUIManagerType() == FABRIC) {
catalystInstance.getJSModule(ReactFabric.class)
.unmountComponentAtNode(rootView.getId());
.unmountComponentAtNode(rootView.getRootViewTag());
} else {
catalystInstance.getJSModule(AppRegistry.class)
.unmountApplicationComponentAtRootTag(rootView.getId());
.unmountApplicationComponentAtRootTag(rootView.getRootViewTag());
}
}