C++ style enums 14/N: Overflow (#1398)
Summary: X-link: https://github.com/facebook/react-native/pull/39537 Pull Request resolved: https://github.com/facebook/yoga/pull/1398 Moves internal usages of YGOverflow to Overflow bypass-github-export-checks Changelog: [Internal] Reviewed By: rshest Differential Revision: D49361843 fbshipit-source-id: 42161aa8a26f64f052587b861120cdad0290ae46
This commit is contained in:
committed by
Facebook GitHub Bot
parent
03d0523996
commit
75bbfb0b71
@@ -19,6 +19,7 @@
|
||||
#include <yoga/enums/Direction.h>
|
||||
#include <yoga/enums/FlexDirection.h>
|
||||
#include <yoga/enums/Justify.h>
|
||||
#include <yoga/enums/Overflow.h>
|
||||
#include <yoga/enums/PositionType.h>
|
||||
#include <yoga/enums/Wrap.h>
|
||||
#include <yoga/numeric/FloatOptional.h>
|
||||
@@ -122,7 +123,7 @@ class YG_EXPORT Style {
|
||||
static constexpr uint8_t overflowOffset =
|
||||
flexWrapOffset + minimumBitCount<Wrap>();
|
||||
static constexpr uint8_t displayOffset =
|
||||
overflowOffset + minimumBitCount<YGOverflow>();
|
||||
overflowOffset + minimumBitCount<Overflow>();
|
||||
|
||||
uint32_t flags = 0;
|
||||
|
||||
@@ -201,10 +202,10 @@ class YG_EXPORT Style {
|
||||
return {*this, flexWrapOffset};
|
||||
}
|
||||
|
||||
YGOverflow overflow() const {
|
||||
return getEnumData<YGOverflow>(flags, overflowOffset);
|
||||
Overflow overflow() const {
|
||||
return getEnumData<Overflow>(flags, overflowOffset);
|
||||
}
|
||||
BitfieldRef<YGOverflow> overflow() {
|
||||
BitfieldRef<Overflow> overflow() {
|
||||
return {*this, overflowOffset};
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user