Permalink
Browse files

Exposing layout cache check publicly

Reviewed By: emilsjolander

Differential Revision: D4124705

fbshipit-source-id: 23284967900585fa20dcb51c9cc1bee829b32975
  • Loading branch information...
1 parent 761e06b commit e7dc71ba84ee15777601c0d59d6202a5d002a1cb Georgiy Kassabli committed with Facebook Github Bot Nov 3, 2016
Showing with 15 additions and 1 deletion.
  1. +1 −1 React/CSSLayout/CSSLayout.c
  2. +14 −0 React/CSSLayout/CSSLayout.h
@@ -2090,7 +2090,7 @@ static inline bool newMeasureSizeIsStricterAndStillValid(CSSMeasureMode sizeMode
lastSize > size && lastComputedSize <= size;
}
-static bool CSSNodeCanUseCachedMeasurement(const bool isTextNode,
+bool CSSNodeCanUseCachedMeasurement(const bool isTextNode,
const CSSMeasureMode widthMode,
const float width,
const CSSMeasureMode heightMode,
@@ -161,6 +161,20 @@ WIN_EXPORT void CSSNodePrint(const CSSNodeRef node, const CSSPrintOptions option
WIN_EXPORT bool CSSValueIsUndefined(const float value);
+WIN_EXPORT bool CSSNodeCanUseCachedMeasurement(const bool isTextNode,
+ const CSSMeasureMode widthMode,
+ const float width,
+ const CSSMeasureMode heightMode,
+ const float height,
+ const CSSMeasureMode lastWidthMode,
+ const float lastWidth,
+ const CSSMeasureMode lastHeightMode,
+ const float lastHeight,
+ const float lastComputedWidth,
+ const float lastComputedHeight,
+ const float marginRow,
+ const float marginColumn);
+
#define CSS_NODE_PROPERTY(type, name, paramName) \
WIN_EXPORT void CSSNodeSet##name(const CSSNodeRef node, type paramName); \
WIN_EXPORT type CSSNodeGet##name(const CSSNodeRef node);

0 comments on commit e7dc71b

Please sign in to comment.