MCPcopy Create free account
hub / github.com/Snapchat/Valdi / needsYogaMeasureFunc

Method needsYogaMeasureFunc

valdi/src/valdi/runtime/Context/ViewNode.cpp:1680–1694  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1678 measuredSize = _attributesApplier.getBoundAttributes()->getMeasureDelegate()->measure(
1679 *this, width, widthMode, height, heightMode);
1680 } else if (_lazyLayoutData != nullptr) {
1681 measuredSize = Size(_lazyLayoutData->estimatedWidth, _lazyLayoutData->estimatedHeight);
1682 } else {
1683 measuredSize = Size();
1684 }
1685
1686 _flags[kIsMeasuring] = false;
1687 return measuredSize;
1688}
1689
1690Ref<ViewNode> ViewNode::makePlaceholderViewNode(ViewTransactionScope& viewTransactionScope,
1691 const Ref<View>& placeholderView) {
1692 auto viewNode = Valdi::makeShared<ViewNode>(nullptr, _attributeIds, _logger);
1693 viewNode->setViewNodeTree(_viewNodeTree);
1694 viewNode->setViewFactory(viewTransactionScope, _viewFactory);
1695 viewNode->_emittingViewNode = strongSmallRef(this);
1696 viewNode->_cssAttributesManager.copyCSSDocument(_cssAttributesManager);
1697 placeholderView->setCanBeReused(false);

Callers

nothing calls this directly

Calls 2

resolveYogaNodeFunction · 0.85
getChildCountMethod · 0.45

Tested by

no test coverage detected