From 10ab64888fe8348dda490d82ee709acbee83f27c Mon Sep 17 00:00:00 2001 From: Samuel Susla Date: Sat, 11 Sep 2021 01:40:55 -0700 Subject: [PATCH] Annotate arguments when constructing ShadowViewMutation Summary: changelog: [internal] Reviewed By: philIip Differential Revision: D30766786 fbshipit-source-id: f7fac3371d9f018c15c366b0e8a5be1de021a0e7 --- .../LayoutAnimationKeyFrameManager.cpp | 30 +++++++++---------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/ReactCommon/react/renderer/animations/LayoutAnimationKeyFrameManager.cpp b/ReactCommon/react/renderer/animations/LayoutAnimationKeyFrameManager.cpp index 0bf95be0c91..94655c46009 100644 --- a/ReactCommon/react/renderer/animations/LayoutAnimationKeyFrameManager.cpp +++ b/ReactCommon/react/renderer/animations/LayoutAnimationKeyFrameManager.cpp @@ -442,11 +442,11 @@ LayoutAnimationKeyFrameManager::pullTransaction( if (keyframe.type == AnimationConfigurationType::Update && mutation.oldChildShadowView.tag > 0) { executeMutationImmediately = ShadowViewMutation{ - mutation.type, - mutation.parentShadowView, - keyframe.viewPrev, - {}, - mutation.index}; + /* .type = */ mutation.type, + /* .parentShadowView = */ mutation.parentShadowView, + /* .oldChildShadowView = */ keyframe.viewPrev, + /* .newChildShadowView = */ {}, + /* .index = */ mutation.index}; } } } @@ -1278,11 +1278,11 @@ void LayoutAnimationKeyFrameManager::queueFinalMutationsForCompletedKeyFrame( // Copy so that if something else mutates the inflight animations, // it won't change this mutation after this point. auto mutation = ShadowViewMutation{ - finalMutation.type, - finalMutation.parentShadowView, - prev, - finalMutation.newChildShadowView, - finalMutation.index}; + /* .type = */ finalMutation.type, + /* .parentShadowView = */ finalMutation.parentShadowView, + /* .oldChildShadowView = */ prev, + /* .newChildShadowView = */ finalMutation.newChildShadowView, + /* .index = */ finalMutation.index}; react_native_assert(mutation.oldChildShadowView.tag > 0); react_native_assert( mutation.newChildShadowView.tag > 0 || @@ -1331,11 +1331,11 @@ void LayoutAnimationKeyFrameManager::queueFinalMutationsForCompletedKeyFrame( mutationsList.push_back(generatedMutation); } else { auto mutation = ShadowViewMutation{ - ShadowViewMutation::Type::Update, - keyframe.parentView, - keyframe.viewPrev, - keyframe.viewEnd, - -1}; + /* .type = */ ShadowViewMutation::Type::Update, + /* .parentShadowView = */ keyframe.parentView, + /* .oldChildShadowView = */ keyframe.viewPrev, + /* .newChildShadowView = */ keyframe.viewEnd, + /* .index = */ -1}; PrintMutationInstruction( logPrefix + "Animation Complete: Queuing up Final Synthetic Mutation:",