Bridged FBPullToRefresh to JS
Reviewed By: shergin Differential Revision: D6875099 fbshipit-source-id: 00bbad7569ff047a77f198ad2bf4d77fccbaa2e9
This commit is contained in:
parent
979c01ed2d
commit
f96d7ae648
|
@ -443,6 +443,11 @@ static inline void RCTApplyTransformationAccordingLayoutDirection(UIView *view,
|
|||
#if !TARGET_OS_TV
|
||||
if ([view isKindOfClass:[RCTRefreshControl class]]) {
|
||||
[_scrollView setRctRefreshControl:(RCTRefreshControl *)view];
|
||||
}
|
||||
else if ([view conformsToProtocol:@protocol(UIScrollViewDelegate)]) {
|
||||
[self addScrollListener:(UIView<UIScrollViewDelegate> *)view];
|
||||
[_scrollView addSubview:view];
|
||||
[_scrollView sendSubviewToBack:view];
|
||||
} else
|
||||
#endif
|
||||
{
|
||||
|
@ -459,6 +464,9 @@ static inline void RCTApplyTransformationAccordingLayoutDirection(UIView *view,
|
|||
#if !TARGET_OS_TV
|
||||
if ([subview isKindOfClass:[RCTRefreshControl class]]) {
|
||||
[_scrollView setRctRefreshControl:nil];
|
||||
} else if ([subview conformsToProtocol:@protocol(UIScrollViewDelegate)]) {
|
||||
[self removeScrollListener:(UIView<UIScrollViewDelegate> *)subview];
|
||||
[subview removeFromSuperview];
|
||||
} else
|
||||
#endif
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue