Is there any way to cover an iOS 7 status bar with a UIView temporarily?

Vlad Bahtjak

I have a bit of a weird scenario here and have been trying to find some help but the solutions don't really solve my problem rather make it worse.

I have a container viewController that has three child controllers views inside a horizontal scroll view. My default child controller view is my custom camera page. Now this is what I want to achieve. I would like to keep the status bar hidden on my camera page but would like the other two views aka my other two child controllers to have the status bar showing.

When I drag from either my left child controller to my camera page or from my right child controller to my camera page, I would like my camera page view to overlap the status bar.

The only place I have seen this done is on Snapchat and I've been trying for a couple hours to figure it out but just can't seem to come up with a solution. Any help is appreciated.

David Gölzhäuser

You can do it wizh the real Statusbar. Just get the Statusbars UIView you then need to play with the UIWindowLevel like this

    //Getting the Statusbar

    UIView *statusbar;
    NSString *key = @"statusBar";
    id object = [UIApplication sharedApplication];
    if ([object respondsToSelector:NSSelectorFromString(key)]) {
        statusbar = [object valueForKey:key];
    }

    //Set your Overlapping UIViewController or UIView one Level higher then the Statusbar.
    self.navigationController.view.window.windowLevel = UIWindowLevelStatusBar+1; //This will set the Overlapping UIViewControllers WindowLevel over the StatusBar.

이 기사는 인터넷에서 수집됩니다. 재 인쇄 할 때 출처를 알려주십시오.

침해가 발생한 경우 연락 주시기 바랍니다[email protected] 삭제

에서 수정
0

몇 마디 만하겠습니다

0리뷰
로그인참여 후 검토

관련 기사

분류에서Dev

Customize iOS 7 status bar text Color

분류에서Dev

Is it any way to temporarily install make 3.81?

분류에서Dev

iOS 8 Orientation Landscape status bar issue

분류에서Dev

iOS 7 UINavigationBar - UIView layout issue

분류에서Dev

Removing Status Bar In IOS 8 When Using A UINavigationController

분류에서Dev

팝업 IOS7에서 UIview 닫기

분류에서Dev

ios7-bar 문제의 uislder 수직

분류에서Dev

Flutter: Is there any way of using a widget only on ios but not on android?

분류에서Dev

Flutter: How to change the status bar text color on Android and iOS when not using AppBar

분류에서Dev

iOS7의 큰 속도 저하 : CGContextDrawImage 또는 UIView setImage?

분류에서Dev

iOS 7-투명한 UIView 차단 제스처 인식기

분류에서Dev

UIView의 iOS CGAffineTransform

분류에서Dev

iOS : UIView 대 SKView

분류에서Dev

Best way to animate visiblity of UICollectionViewCell in iOS7+

분류에서Dev

Menu in system status bar is disabled

분류에서Dev

NSStatusItem reordering along Status Bar

분류에서Dev

UIView animation broken in iOS 8

분류에서Dev

iOS7에서는 UIView가 중단되지만 iOS8에서는 중단되지 않음

분류에서Dev

STATUS BAR의 높이 얻기

분류에서Dev

Detecting if user has in call status bar

분류에서Dev

Status bar and UI orientation didn't match

분류에서Dev

Overlay Status bar on android 4.2.2+

분류에서Dev

Android: Detect status bar notification click

분류에서Dev

How to change the status bar bgcolor for UITableView with hidden nav bar?

분류에서Dev

Tool_Bar with android CardView and Transparent status bar

분류에서Dev

Android Studio refused to show status bar nor Nav Bar

분류에서Dev

IOS-Firebase Dynamic Link 앱을 열지 만 STATUS BAR에 텍스트 버튼이 표시됩니다.

분류에서Dev

iOS7에서 self.view.window에 UIView 객체를 추가하려면 어떻게해야합니까?

분류에서Dev

스토리 보드 IOS7을 사용하여 UIview 컨트롤러를 하위보기로 표시

Related 관련 기사

  1. 1

    Customize iOS 7 status bar text Color

  2. 2

    Is it any way to temporarily install make 3.81?

  3. 3

    iOS 8 Orientation Landscape status bar issue

  4. 4

    iOS 7 UINavigationBar - UIView layout issue

  5. 5

    Removing Status Bar In IOS 8 When Using A UINavigationController

  6. 6

    팝업 IOS7에서 UIview 닫기

  7. 7

    ios7-bar 문제의 uislder 수직

  8. 8

    Flutter: Is there any way of using a widget only on ios but not on android?

  9. 9

    Flutter: How to change the status bar text color on Android and iOS when not using AppBar

  10. 10

    iOS7의 큰 속도 저하 : CGContextDrawImage 또는 UIView setImage?

  11. 11

    iOS 7-투명한 UIView 차단 제스처 인식기

  12. 12

    UIView의 iOS CGAffineTransform

  13. 13

    iOS : UIView 대 SKView

  14. 14

    Best way to animate visiblity of UICollectionViewCell in iOS7+

  15. 15

    Menu in system status bar is disabled

  16. 16

    NSStatusItem reordering along Status Bar

  17. 17

    UIView animation broken in iOS 8

  18. 18

    iOS7에서는 UIView가 중단되지만 iOS8에서는 중단되지 않음

  19. 19

    STATUS BAR의 높이 얻기

  20. 20

    Detecting if user has in call status bar

  21. 21

    Status bar and UI orientation didn't match

  22. 22

    Overlay Status bar on android 4.2.2+

  23. 23

    Android: Detect status bar notification click

  24. 24

    How to change the status bar bgcolor for UITableView with hidden nav bar?

  25. 25

    Tool_Bar with android CardView and Transparent status bar

  26. 26

    Android Studio refused to show status bar nor Nav Bar

  27. 27

    IOS-Firebase Dynamic Link 앱을 열지 만 STATUS BAR에 텍스트 버튼이 표시됩니다.

  28. 28

    iOS7에서 self.view.window에 UIView 객체를 추가하려면 어떻게해야합니까?

  29. 29

    스토리 보드 IOS7을 사용하여 UIview 컨트롤러를 하위보기로 표시

뜨겁다태그

보관