Commit be9ebbfa6f02c411a25f9af390711705e3161ff5
1 parent
5b1e6559
去认证主播页面禁止手势侧滑退出
Showing
1 changed file
with
18 additions
and
0 deletions
LiveVideoCloud/Classes/Sections/LiveSections/Controller/LVCVerifyViewController.m
| ... | ... | @@ -16,6 +16,24 @@ |
| 16 | 16 | |
| 17 | 17 | @implementation LVCVerifyViewController |
| 18 | 18 | |
| 19 | +- (void)viewDidAppear:(BOOL)animated | |
| 20 | +{ | |
| 21 | + [super viewDidAppear:animated]; | |
| 22 | + // 禁用返回手势 | |
| 23 | + if ([self.navigationController respondsToSelector:@selector(interactivePopGestureRecognizer)]) { | |
| 24 | + self.navigationController.interactivePopGestureRecognizer.enabled = NO; | |
| 25 | + } | |
| 26 | +} | |
| 27 | + | |
| 28 | +- (void)viewWillDisappear:(BOOL)animated | |
| 29 | +{ | |
| 30 | + [super viewWillDisappear:animated]; | |
| 31 | + // 开启返回手势 | |
| 32 | + if ([self.navigationController respondsToSelector:@selector(interactivePopGestureRecognizer)]) { | |
| 33 | + self.navigationController.interactivePopGestureRecognizer.enabled = YES; | |
| 34 | + } | |
| 35 | +} | |
| 36 | + | |
| 19 | 37 | - (void)viewDidLoad { |
| 20 | 38 | [super viewDidLoad]; |
| 21 | 39 | ... | ... |