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:
David Aurelio 2018-08-17 03:56:35 -07:00 коммит произвёл Facebook Github Bot
Родитель bfa62d4bfb
Коммит b7c079f96f
1 изменённых файлов: 5 добавлений и 3 удалений

Просмотреть файл

@ -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;