iOS隐藏状态栏

  1. 隐藏当前页面的状态栏
    [[UIApplication sharedApplication] setStatusBarHidden:TRUE];
  2. 隐藏整个程序的状态栏
    在info.plist上添加一项:Status bar is initially hidden,value为YES;
    然后在APP.m中写:
    [[UIApplication sharedApplication]setStatusBarHidden:YES withAnimation:UIStatusBarAnimationFade];

你可能感兴趣的:(iOS隐藏状态栏)