Moved out main axis justification logic to seperate function

Summary: Moved out main axis justification logic to seperate function

Reviewed By: emilsjolander

Differential Revision: D6845997

fbshipit-source-id: fdb64e00de39427ce1d66d4fbfd06c23c0d32bcf
This commit is contained in:
Pritesh Nandgaonkar
2018-02-06 08:39:49 -08:00
committed by Facebook Github Bot
parent bd46344a4e
commit dc0609d153
2 changed files with 216 additions and 163 deletions

View File

@@ -45,6 +45,13 @@ struct YGCollectFlexItemsRowValues {
float endOfLineIndex;
std::vector<YGNodeRef> relativeChildren;
float remainingFreeSpace;
// The size of the mainDim for the row after considering size, padding, margin
// and border of flex items. This is used to calculate maxLineDim after going
// through all the rows to decide on the main axis size of parent.
float mainDim;
// The size of the crossDim for the row after considering size, padding,
// margin and border of flex items. Used for calculating containers crossSize.
float crossDim;
};
bool YGValueEqual(const YGValue a, const YGValue b);