mirror of
https://github.com/zhigang1992/react-navigation.git
synced 2026-02-12 22:30:36 +08:00
This change automates first responder restoring when screen is deactivated and the activated back (e.g. when we push new screen on top and then go back). In addition we disable pointerEvent setting for the Screen component as changes made to that prop would cause underlying views to resign responder before we can remember it. Because of that we add an automatic handling for pointer events for the Screen component that disables all touch interactions when screen is transitioning.
23 lines
525 B
Objective-C
23 lines
525 B
Objective-C
#import <React/RCTViewManager.h>
|
|
#import <React/RCTView.h>
|
|
#import "RNSScreenContainer.h"
|
|
|
|
@class RNSScreenContainerView;
|
|
|
|
@interface RNSScreenManager : RCTViewManager
|
|
@end
|
|
|
|
@interface RNSScreenView : RCTView <RCTInvalidating>
|
|
|
|
@property (weak, nonatomic) UIView<RNSScreenContainerDelegate> *reactSuperview;
|
|
@property (nonatomic, retain) UIViewController *controller;
|
|
@property (nonatomic) BOOL active;
|
|
|
|
- (void)notifyFinishTransitioning;
|
|
|
|
@end
|
|
|
|
@interface UIView (RNSScreen)
|
|
- (UIViewController *)parentViewController;
|
|
@end
|