-
-
Notifications
You must be signed in to change notification settings - Fork 191
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
65c5a99
commit e808572
Showing
9 changed files
with
168 additions
and
55 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,36 @@ | ||
#import <React/RCTConvert.h> | ||
#import "RNCSafeAreaViewEdges.h" | ||
#import <React/RCTConvert.h> | ||
#import "RNCSafeAreaViewEdgeMode.h" | ||
|
||
RNCSafeAreaViewEdges RNCSafeAreaViewEdgesMake(RNCSafeAreaViewEdgeMode top, RNCSafeAreaViewEdgeMode right, RNCSafeAreaViewEdgeMode bottom, RNCSafeAreaViewEdgeMode left) | ||
RNCSafeAreaViewEdges RNCSafeAreaViewEdgesMake( | ||
RNCSafeAreaViewEdgeMode top, | ||
RNCSafeAreaViewEdgeMode right, | ||
RNCSafeAreaViewEdgeMode bottom, | ||
RNCSafeAreaViewEdgeMode left) | ||
{ | ||
RNCSafeAreaViewEdges edges; | ||
edges.top = top; | ||
edges.left = left; | ||
edges.bottom = bottom; | ||
edges.right = right; | ||
return edges; | ||
RNCSafeAreaViewEdges edges; | ||
edges.top = top; | ||
edges.left = left; | ||
edges.bottom = bottom; | ||
edges.right = right; | ||
return edges; | ||
} | ||
|
||
RNCSafeAreaViewEdges RNCSafeAreaViewEdgesMakeString(NSString *top, NSString *right, NSString *bottom, NSString *left) | ||
{ | ||
RNCSafeAreaViewEdges edges; | ||
edges.top = [RCTConvert RNCSafeAreaViewEdgeMode:top]; | ||
edges.right = [RCTConvert RNCSafeAreaViewEdgeMode:right]; | ||
edges.bottom = [RCTConvert RNCSafeAreaViewEdgeMode:bottom]; | ||
edges.left = [RCTConvert RNCSafeAreaViewEdgeMode:left]; | ||
return edges; | ||
RNCSafeAreaViewEdges edges; | ||
edges.top = [RCTConvert RNCSafeAreaViewEdgeMode:top]; | ||
edges.right = [RCTConvert RNCSafeAreaViewEdgeMode:right]; | ||
edges.bottom = [RCTConvert RNCSafeAreaViewEdgeMode:bottom]; | ||
edges.left = [RCTConvert RNCSafeAreaViewEdgeMode:left]; | ||
return edges; | ||
} | ||
|
||
@implementation RCTConvert (RNCSafeAreaViewEdges) | ||
|
||
RCT_CUSTOM_CONVERTER(RNCSafeAreaViewEdges, RNCSafeAreaViewEdges, RNCSafeAreaViewEdgesMakeString(json[@"top"], json[@"right"], json[@"bottom"], json[@"left"])) | ||
RCT_CUSTOM_CONVERTER( | ||
RNCSafeAreaViewEdges, | ||
RNCSafeAreaViewEdges, | ||
RNCSafeAreaViewEdgesMakeString(json[@"top"], json[@"right"], json[@"bottom"], json[@"left"])) | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters