mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-03-06 22:37:14 +08:00
Introduce "updateProps" field InsertMutation
Summary: This diff introduces the concept of "updateProps" as part of InsertMutation and it changes the diffing algorithm to populate this field. Reviewed By: shergin Differential Revision: D14289608 fbshipit-source-id: 642f00d03d294a12ea7fa7482c72e701b756f3d4
This commit is contained in:
committed by
Facebook Github Bot
parent
f6ba52bf1e
commit
95c414cfbf
@@ -402,8 +402,10 @@ void Binding::schedulerDidFinishTransaction(
|
||||
mountItems[position++] =
|
||||
createInsertMountItem(javaUIManager_, mutation);
|
||||
|
||||
mountItems[position++] =
|
||||
createUpdatePropsMountItem(javaUIManager_, mutation);
|
||||
if (mutation.newChildShadowView.props->revision != 0) {
|
||||
mountItems[position++] =
|
||||
createUpdatePropsMountItem(javaUIManager_, mutation);
|
||||
}
|
||||
|
||||
auto updateLayoutMountItem =
|
||||
createUpdateLayoutMountItem(javaUIManager_, mutation);
|
||||
|
||||
@@ -116,7 +116,7 @@ static void calculateShadowViewMutations(
|
||||
const auto &newChildPair = newChildPairs[index];
|
||||
|
||||
insertMutations.push_back(ShadowViewMutation::InsertMutation(
|
||||
parentShadowView, newChildPair.shadowView, index));
|
||||
parentShadowView, newChildPair.shadowView, index));
|
||||
|
||||
insertedPairs.insert({newChildPair.shadowView.tag, newChildPair});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user