方法1:
[[UIApplication sharedApplication] setStatusBarHidden:NO withAnimation:UIStatusBarAnimationNone];
方法2:
UIView *proxyView = [[UIView alloc] initWithFrame:self.view.frame];
proxyView.hidden=YES;
proxyView.autoresizingMask= self.view.autoresizingMask;
[self.view.superview addSubview:proxyView];
[self.view.window addSubview:self.view];
self.view.frame = [self.view.window convertRect:self.view.frame fromView:proxyView.superview];
[UIView animateWithDuration:0.2
animations:^{
self.view.frame=self.view.window.bounds;
}];
[[UIApplication sharedApplication] setStatusBarHidden:YES withAnimation:UIStatusBarAnimationFade];
statusbar 隐藏
最新推荐文章于 2021-05-27 18:17:59 发布