Type alias for dimensions
Summary: Aliases `std::array<YGValue, 2>` as `YGStyle::Dimensions` for increased readability. This prepares a follow up, where the alias is used in `Yoga.cpp`. Reviewed By: astreet Differential Revision: D8874566 fbshipit-source-id: a7a7a1b02bff547d7d6b800c522c4785a62ad611
This commit is contained in:
committed by
Facebook Github Bot
parent
8309cfc976
commit
6132a59772
@@ -11,6 +11,8 @@
|
||||
#include "Yoga.h"
|
||||
|
||||
struct YGStyle {
|
||||
using Dimensions = std::array<YGValue, 2>;
|
||||
|
||||
YGDirection direction;
|
||||
YGFlexDirection flexDirection;
|
||||
YGJustify justifyContent;
|
||||
@@ -29,9 +31,9 @@ struct YGStyle {
|
||||
std::array<YGValue, YGEdgeCount> position;
|
||||
std::array<YGValue, YGEdgeCount> padding;
|
||||
std::array<YGValue, YGEdgeCount> border;
|
||||
std::array<YGValue, 2> dimensions;
|
||||
std::array<YGValue, 2> minDimensions;
|
||||
std::array<YGValue, 2> maxDimensions;
|
||||
Dimensions dimensions;
|
||||
Dimensions minDimensions;
|
||||
Dimensions maxDimensions;
|
||||
// Yoga specific properties, not compatible with flexbox specification
|
||||
YGFloatOptional aspectRatio;
|
||||
|
||||
|
Reference in New Issue
Block a user