mirror of
https://github.com/status-im/react-native.git
synced 2025-01-26 01:10:34 +00:00
Fabric: New props treatment in core
module
Summary: Same as previous one. Adopting template-generated `convertRawProp` and `debugStringConvertibleItem` functions in `core` module. Note, to do so we have to change signatures of some conversions functions to make them more overloading-friendly. Reviewed By: fkgozali Differential Revision: D7958243 fbshipit-source-id: 500ee420d9aa562ee3c5810ef625e06541eda8fb
This commit is contained in:
parent
c19649cc16
commit
120dcec621
@ -8,6 +8,7 @@
|
||||
#include "ParagraphAttributes.h"
|
||||
|
||||
#include <fabric/attributedstring/conversions.h>
|
||||
#include <fabric/graphics/conversions.h>
|
||||
#include <fabric/debug/debugStringConvertibleUtils.h>
|
||||
|
||||
namespace facebook {
|
||||
|
@ -8,8 +8,10 @@
|
||||
#include "TextAttributes.h"
|
||||
|
||||
#include <fabric/attributedstring/conversions.h>
|
||||
#include <fabric/core/conversions.h>
|
||||
#include <fabric/graphics/conversions.h>
|
||||
#include <fabric/core/debugStringConvertibleUtils.h>
|
||||
|
||||
#include <fabric/debug/debugStringConvertibleUtils.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
|
@ -12,7 +12,7 @@
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
|
||||
inline std::string stringFromLayoutDirection(const LayoutDirection &layoutDirection) {
|
||||
inline std::string toString(const LayoutDirection &layoutDirection) {
|
||||
switch (layoutDirection) {
|
||||
case LayoutDirection::Undefined: return "undefined";
|
||||
case LayoutDirection::LeftToRight: return "ltr";
|
||||
@ -20,7 +20,7 @@ inline std::string stringFromLayoutDirection(const LayoutDirection &layoutDirect
|
||||
}
|
||||
}
|
||||
|
||||
inline std::string stringFromDisplayType(const DisplayType &displayType) {
|
||||
inline std::string toString(const DisplayType &displayType) {
|
||||
switch (displayType) {
|
||||
case DisplayType::None: return "none";
|
||||
case DisplayType::Flex: return "flex";
|
@ -1,20 +0,0 @@
|
||||
/**
|
||||
* Copyright (c) 2015-present, Facebook, Inc.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <fabric/debug/debugStringConvertibleUtils.h>
|
||||
#include <fabric/core/layoutValuesConversions.h>
|
||||
|
||||
namespace facebook {
|
||||
namespace react {
|
||||
|
||||
DEBUG_STRING_CONVERTIBLE_TEMPLATE(LayoutDirection, stringFromLayoutDirection)
|
||||
DEBUG_STRING_CONVERTIBLE_TEMPLATE(DisplayType, stringFromDisplayType)
|
||||
|
||||
} // namespace react
|
||||
} // namespace facebook
|
Loading…
x
Reference in New Issue
Block a user