IOS 7 hide the status bar (battery bar)

Source: Internet
Author: User

Battery status bar. // Method 1 (Code setting): ios7 is now transparent and does not occupy the screen height. The hiding and display methods are as follows: Under the subclass of uiviewcontroller, call: if ([self respondsToSelector: @ selector (setNeedsStatusBarAppearanceUpdate)]) {// iOS 7 [self prefersstatushidbarden]; [self defined mselector: @ selector (setNeedsStatusBarAppearanceUpdate)];}-(BOOL) prefersStatusBarHidden {return YES; // hide as YES and show as NO} during view switching, such as addsubview, present, pushin and so on, you also need to pay attention to and modify the status bar. // Method 2 (set in plist): first, set key: Status bar is initially hidden to YES and then set key: View controller-based status bar appearance to NO to hide the Status bar globally.
Now
Address: http://www.bkjia.com/kf/201309/245925.html

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.