Change the type of flexShrink to YGFloatOptional

Summary: Change the type of flexShrink to YGFloatOptional

Reviewed By: emilsjolander

Differential Revision: D7232171

fbshipit-source-id: 3111119d3d74a7035c01132bff61b30cf44e120a
This commit is contained in:
Pritesh Nandgaonkar
2018-03-14 04:17:16 -07:00
committed by Facebook Github Bot
parent 8aadae8ce4
commit 877c275a13
5 changed files with 26 additions and 20 deletions

View File

@@ -605,8 +605,8 @@ float YGNode::resolveFlexShrink() {
if (parent_ == nullptr) {
return 0.0;
}
if (!YGFloatIsUndefined(style_.flexShrink)) {
return style_.flexShrink;
if (!style_.flexShrink.isUndefined) {
return style_.flexShrink.value;
}
if (!config_->useWebDefaults && !style_.flex.isUndefined &&
style_.flex.value < 0.0f) {