Fabric: Optimizations in view flattening algorithm

Summary:
This diff changes the condition in `ViewShadowNode::isLayoutOnly()` removing checking for `onLayout` event listener.
We needed that before because the mechanism of emitting events was based on analyzing mutation instructures (we needed those to be generated for nodes with `onLayout`).
Recenly we changed that algorithm deeply integrating in layout infra, so we don't need this anymore.

Reviewed By: JoshuaGross, mdvacca

Differential Revision: D15273491

fbshipit-source-id: 2d43f00d1b87369d5993fe5ba70c2de36b8ce0c5
This commit is contained in:
Valentin Shergin
2019-05-09 10:46:03 -07:00
committed by Facebook Github Bot
parent c60d9f8c15
commit 335c81ec31

View File

@@ -16,8 +16,6 @@ bool ViewShadowNode::isLayoutOnly() const {
const auto &viewProps = *std::static_pointer_cast<const ViewProps>(props_);
return viewProps.collapsable &&
// Event listeners
!viewProps.onLayout &&
// Generic Props
viewProps.nativeId.empty() &&
// Accessibility Props