mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-29 21:46:07 +08:00
Reimagining of RCTShadowView layout API
Summary: This is reimagining of interoperability layer between Yoga and ShadowViews (at least in Yoga -> RN part). Goals: * Make it clear and easy. * Make clear separation between "what layout what", now parent always layout children, noone layout itself. * Make possible to interleave Yoga layout with custom imperative layout (may be used in SafeAreaView, Text, Modal, InputAccessoryView and so on). Reviewed By: mmmulani Differential Revision: D6863654 fbshipit-source-id: 5a6a933874f121d46f744aab99a31ae42ddd4a1b
This commit is contained in:
committed by
Facebook Github Bot
parent
47b36d3ff0
commit
f91f7d91a1
@@ -11,13 +11,6 @@
|
||||
|
||||
#import <React/RCTShadowView.h>
|
||||
|
||||
/**
|
||||
* Converts float values between Yoga and CoreGraphics representations,
|
||||
* especially in terms of edge cases.
|
||||
*/
|
||||
RCT_EXTERN float RCTYogaFloatFromCoreGraphicsFloat(CGFloat value);
|
||||
RCT_EXTERN CGFloat RCTCoreGraphicsFloatFromYogaFloat(float value);
|
||||
|
||||
@interface RCTShadowView (Layout)
|
||||
|
||||
#pragma mark - Computed Layout-Inferred Metrics
|
||||
@@ -28,13 +21,6 @@ RCT_EXTERN CGFloat RCTCoreGraphicsFloatFromYogaFloat(float value);
|
||||
@property (nonatomic, readonly) CGSize availableSize;
|
||||
@property (nonatomic, readonly) CGRect contentFrame;
|
||||
|
||||
#pragma mark - Measuring
|
||||
|
||||
/**
|
||||
* Measures shadow view without side-effects.
|
||||
*/
|
||||
- (CGSize)sizeThatFitsMinimumSize:(CGSize)minimumSize maximumSize:(CGSize)maximumSize;
|
||||
|
||||
#pragma mark - Dirty Propagation Control
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user